query stringlengths 7 33.1k | document stringlengths 7 335k | metadata dict | negatives listlengths 3 101 | negative_scores listlengths 3 101 | document_score stringlengths 3 10 | document_rank stringclasses 102
values |
|---|---|---|---|---|---|---|
Return item description text of the element if any | String getDescription(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String getItemDescription(String itemName) {\n return driver.findElement(By.xpath(\"//div[text()='\" + itemName + \"']/../../div\")).getText();\n }",
"public String getItemDescription() {\r\n\t\treturn itemDescription;\r\n\t}",
"public abstract Element getDescription();",
"public String get... | [
"0.7386816",
"0.7244554",
"0.72169733",
"0.7191919",
"0.7191919",
"0.71712273",
"0.71390307",
"0.7058608",
"0.7020328",
"0.6963995",
"0.6953262",
"0.69488454",
"0.6938147",
"0.6938147",
"0.6938147",
"0.6938147",
"0.6938147",
"0.6938147",
"0.6938147",
"0.6938147",
"0.6938147",... | 0.6589497 | 97 |
Returns corresponding ICpPack if installed | ICpPack getPack(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"ICpPackInfo getPackInfo();",
"IPharPackager getPharPackager() throws PlexusConfigurationException, ComponentLookupException;",
"String getPackager();",
"public String getPackaging();",
"boolean hasPackageName();",
"public String getProductPack() {\n return (String)getAttributeInternal(PRODUCTPACK... | [
"0.76166147",
"0.6654205",
"0.6546454",
"0.65455145",
"0.6263873",
"0.6231316",
"0.6050291",
"0.6040515",
"0.5993248",
"0.59325767",
"0.58972627",
"0.5887436",
"0.5886382",
"0.5873298",
"0.5856589",
"0.58482814",
"0.58000886",
"0.57965744",
"0.5782056",
"0.575938",
"0.5753701... | 0.74818736 | 1 |
Returns corresponding ICpPackInfo if assigned | ICpPackInfo getPackInfo(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"ICpPack getPack();",
"public int getPack() {\r\n\t\treturn pack;\r\n\t}",
"public PACKINGLIST getPack() {\n\t\treturn pack;\n\t}",
"public interface ILitePackItem extends ITreeObject {\n\t\n\t/**\n\t * Returns item ID \n\t * @return item ID \n\t */\n\tString getId();\n\n\t/** \n\t * Returns version string, ... | [
"0.75919694",
"0.6314119",
"0.6081692",
"0.6067218",
"0.5990662",
"0.58441347",
"0.5772182",
"0.5730981",
"0.5709415",
"0.55913085",
"0.55528444",
"0.5450747",
"0.53886116",
"0.53800684",
"0.5262186",
"0.52492577",
"0.5243558",
"0.5238653",
"0.5224321",
"0.52143586",
"0.52138... | 0.8393517 | 0 |
Returns pack attributes taken either from underlying pack or ICPackItem | IAttributes getAttributes(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"ICpPackInfo getPackInfo();",
"ICpPack getPack();",
"public int getPack() {\r\n\t\treturn pack;\r\n\t}",
"public String getProductPackDesc() {\n return (String)getAttributeInternal(PRODUCTPACKDESC);\n }",
"Map<String, Object> getAttributes();",
"Map<String, Object> getAttributes();",
"Map<Stri... | [
"0.68300414",
"0.6221557",
"0.6136509",
"0.5892413",
"0.57777953",
"0.57777953",
"0.57777953",
"0.57676595",
"0.57348484",
"0.5727997",
"0.5693614",
"0.56879705",
"0.5682435",
"0.567529",
"0.56626713",
"0.5640621",
"0.5636264",
"0.5636264",
"0.5623541",
"0.5588557",
"0.558562... | 0.5884251 | 4 |
Returns the first child item | ILitePackItem getFirstChild(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Item getFirst();",
"public Jode first() {\n return children().first();\n }",
"public E first() {\n if (isEmpty()) return null;\n return first.item;\n }",
"public SaveGameNode getFirstChild() {\r\n SaveGameNode node;\r\n node = this.children.get(0);\r\n retu... | [
"0.7491805",
"0.74176556",
"0.72616833",
"0.7107841",
"0.696847",
"0.69451135",
"0.6908877",
"0.69045144",
"0.6896514",
"0.68954337",
"0.68948317",
"0.6883151",
"0.67819977",
"0.6748499",
"0.6726386",
"0.66971076",
"0.66678643",
"0.6649054",
"0.66385704",
"0.66152835",
"0.660... | 0.7318422 | 2 |
Returns root pack collection | ILitePackCollection getRoot(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public SVGElementModel getRoot() {\n \t\treturn store.getRootItems().get(0);\n \t}",
"public Object getRoot(){\r\n\t\treturn _root;\r\n\t}",
"@Override\n\tpublic T getRootElements() {\n\t\treturn null;\n\t}",
"@Override\r\n\tpublic Collection<CacheTreeNode> getRootList() {\n\t\tCacheTreeNode node = (CacheTre... | [
"0.6224128",
"0.6222973",
"0.6041591",
"0.6024045",
"0.6014247",
"0.60106975",
"0.59860116",
"0.5983852",
"0.59677213",
"0.59677213",
"0.5913573",
"0.58632255",
"0.5862513",
"0.58179975",
"0.58136743",
"0.5773796",
"0.57485795",
"0.5731392",
"0.5704596",
"0.56372285",
"0.5591... | 0.8166939 | 0 |
Returns parent pack family if any | ILitePackFamily getFamily(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"ILitePackItem getParent();",
"Object getParent();",
"public abstract Optional<TypeName> parent();",
"public ProductContainer getParent();",
"IClassBuilder getParent();",
"public int getParent();",
"com.google.protobuf.ByteString getParentBytes();",
"public <T extends RMShape> T getParent(Class<T> aCl... | [
"0.65730155",
"0.63878065",
"0.62833005",
"0.62636495",
"0.6015146",
"0.60135764",
"0.5967599",
"0.5964404",
"0.5958188",
"0.5952188",
"0.59079057",
"0.5894571",
"0.5894571",
"0.5884824",
"0.5855191",
"0.58391815",
"0.58192474",
"0.58192474",
"0.58192474",
"0.58192474",
"0.58... | 0.62584764 | 4 |
retrieve the question array from the Repository class IMPORTANT: binding doesnt take the exact name we write | @Override
public void processFinished(ArrayList<Question> questionArrayList) {
binding.questionTextview.setText(questionArrayList.get(currentQuestionIndex).getAnswer());
updateCounter(questionArrayList);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public IAnswer[] getAnswers();",
"List<Question> getQuestions();",
"public Collection<Question> getQuestions();",
"public List<DataQuestion> getAllAnswer(){\n return items;\n }",
"List<Question> getQuestions(String surveyId);",
"public List<Answer> getAnswers(Question question) throws Exception... | [
"0.6410246",
"0.64086056",
"0.6310502",
"0.6175024",
"0.6084262",
"0.592277",
"0.579976",
"0.5792822",
"0.57516277",
"0.57251",
"0.5687473",
"0.56790847",
"0.5676842",
"0.5658782",
"0.5655579",
"0.56334645",
"0.56235254",
"0.5619833",
"0.5616915",
"0.55969757",
"0.5589852",
... | 0.0 | -1 |
right after we pause the application, we save the highest score. | @Override
protected void onPause() {
prefs.saveHighestScore(score.getScore());
prefs.seState(currentQuestionIndex);
super.onPause();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void saveScore() {\n if (this.currentScore > this.highScore) {\n this.highScore = this.currentScore;\n SharedPreferences sharedPref = this.getPreferences(Context.MODE_PRIVATE);\n SharedPreferences.Editor editor = sharedPref.edit();\n editor.putInt(\"High Sc... | [
"0.7593556",
"0.71678966",
"0.6823106",
"0.6751739",
"0.6737222",
"0.6708661",
"0.6681247",
"0.66185534",
"0.6608942",
"0.65947044",
"0.6588245",
"0.6577689",
"0.65574676",
"0.65321624",
"0.653089",
"0.6481265",
"0.6480042",
"0.6478495",
"0.6473191",
"0.64499867",
"0.6443155"... | 0.75607556 | 1 |
Scrapes publications from nature.com | protected boolean scrapeInternal(ScrapingContext sc) throws ScrapingException {
sc.setScraper(this);
try {
// get publication page
final String publicationPage = sc.getPageContent();
// extract download citation link
final Matcher linkMatcher = linkPattern.matcher(publicationPage);
while(linkMatche... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void extractFirstFivePubsCites() {\r\n try {\r\n List<String> citeMatches = new ArrayList<String>();\r\n // gets all matched objects for extracting publication citations.\r\n Matcher matcherObject = matcher.patternMatcher(\"FivePubsCites\");\r\n\r\n\r\n while (matcherObject.find()) {... | [
"0.59450066",
"0.5791067",
"0.56630474",
"0.5616542",
"0.5614542",
"0.5544651",
"0.5481223",
"0.5478426",
"0.54695404",
"0.54643005",
"0.54262114",
"0.5419928",
"0.5410934",
"0.5367428",
"0.53620213",
"0.5354705",
"0.5351483",
"0.5311623",
"0.5275059",
"0.5262924",
"0.5211549... | 0.0 | -1 |
default constructor which will use default values for any configuration settings | public AbstractCommand()
{
this.logger = new ConsoleLogger();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private Config() {\n }",
"protected Configuration() {\r\n }",
"public E4KTunerConfiguration()\n\t{\n\t\tthis( \"Default\" );\n\t}",
"public Config() {\n this(System.getProperties());\n\n }",
"public SimulationConfig() {\r\n\t}",
"public Config() {\n\t\t// TODO Auto-generated constructor stu... | [
"0.75264424",
"0.74461144",
"0.7439755",
"0.7293173",
"0.7133155",
"0.7113178",
"0.7111744",
"0.70908564",
"0.7086424",
"0.70602244",
"0.70243365",
"0.70022094",
"0.69980234",
"0.6992808",
"0.6981166",
"0.6928856",
"0.6928439",
"0.6905573",
"0.688188",
"0.68782586",
"0.687628... | 0.0 | -1 |
get the command line for this instance | protected abstract String getCommandLine() throws ConfigException; | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public CommandlineJava getCommandLine() {\r\n return cmdl;\r\n }",
"public Properties getCommandLineArgs()\n {\n return this.commandLineArgs;\n }",
"public String commandLine() {\n String command = \"\";\n for (String arg : builder.command()) {\n command += arg +... | [
"0.72114503",
"0.69395053",
"0.69160527",
"0.6842229",
"0.67301285",
"0.6540135",
"0.6487619",
"0.6395084",
"0.62123704",
"0.62087256",
"0.618756",
"0.6175581",
"0.6061454",
"0.6010893",
"0.590361",
"0.5874911",
"0.5803473",
"0.57921726",
"0.57793164",
"0.57615906",
"0.573366... | 0.6420452 | 7 |
set the logger used by this instance | public void setLogger(Logger logger)
{
this.logger = logger;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setLogger(Logger logger) {\n this.logger = logger;\n }",
"public final void setLogger(final Logger logger) {\r\n this.logger = logger;\r\n }",
"public void setLog (Logger log) {\n this.log = log;\n }",
"public void setLogger(PersonalLogger logger) {\r\n this.logger ... | [
"0.79653335",
"0.7767583",
"0.76491135",
"0.725497",
"0.71799505",
"0.7178456",
"0.7160589",
"0.7065404",
"0.7005175",
"0.6804244",
"0.67191494",
"0.6712135",
"0.66323996",
"0.65594596",
"0.6458524",
"0.6439705",
"0.6376837",
"0.63705486",
"0.6366203",
"0.6329178",
"0.6324975... | 0.80254203 | 0 |
get the logger for this instance | public Logger getLogger()
{
return this.logger;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static Logger logger() {\n return logger;\n }",
"public static Logger get() {\n\t\treturn LoggerFactory.getLogger(WALKER.getCallerClass());\n\t}",
"public static Logger getLogger() {\r\n\t\tif (log == null) {\r\n\t\t\tinitLogs();\r\n\t\t}\r\n\t\treturn log;\r\n\t}",
"public Logger getLogger(... | [
"0.82042366",
"0.80896807",
"0.7993817",
"0.79932284",
"0.7971939",
"0.79349804",
"0.7925272",
"0.7919213",
"0.78973204",
"0.7866284",
"0.786556",
"0.77956235",
"0.7792976",
"0.77874076",
"0.77409345",
"0.76699495",
"0.7645026",
"0.763268",
"0.7618338",
"0.7555422",
"0.755438... | 0.7939006 | 5 |
The header text, a hashtag will be appended before | public void setHeaderText(String headerText) {
this.headerText = headerText;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private static Text createHeader() {\n StringBuilder stringBuilder = new StringBuilder();\n //noinspection HardCodedStringLiteral\n stringBuilder.append(\"Offset \");\n for (int i = 0; i < 16; i++) {\n stringBuilder.append(\" 0\");\n stringBuilder.append(Integer.... | [
"0.68609434",
"0.6801218",
"0.66337085",
"0.6627514",
"0.6614052",
"0.6517315",
"0.65055346",
"0.64642495",
"0.64231724",
"0.6416613",
"0.6415431",
"0.6413563",
"0.6382098",
"0.6382098",
"0.6328489",
"0.6305294",
"0.6286511",
"0.62855375",
"0.6255654",
"0.62396705",
"0.623676... | 0.63339394 | 14 |
Set if this writer should write a header at the top | public void setWriteHeader(boolean writeHeader) {
this.writeHeader = writeHeader;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setHeader(boolean isHeader) {\n this.isHeader = isHeader;\n }",
"public void setHeaderFlag(boolean flag) {\n configuration.put(ConfigTag.HEADER, flag);\n }",
"public void forceNotInsideHeader() {\n insideHeader = false;\n }",
"@attribute(value = \"\", required = false, def... | [
"0.69222736",
"0.677402",
"0.6633039",
"0.6417898",
"0.6213993",
"0.61954105",
"0.61669123",
"0.6122297",
"0.60931045",
"0.60824656",
"0.60441",
"0.60320187",
"0.60234517",
"0.59857917",
"0.59701645",
"0.5937347",
"0.58679575",
"0.58556324",
"0.5839109",
"0.5834736",
"0.58235... | 0.6358842 | 4 |
Set the begin document marker | public void setBeginMarker(String beginMarker) {
this.beginMarker = beginMarker;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setBeginOffset(Integer beginOffset) {\n this.beginOffset = beginOffset;\n }",
"public void setBegin(int begin)\n {\n this.begin = begin;\n this.beginSpecified = true;\n }",
"public String getBeginMarker() {\n return beginMarker;\n }",
"public void startDocument ()\... | [
"0.7052337",
"0.6955726",
"0.68906724",
"0.68553907",
"0.6848539",
"0.6819608",
"0.6798402",
"0.67700696",
"0.6762016",
"0.65177643",
"0.64363825",
"0.6370729",
"0.6361456",
"0.63085276",
"0.6268168",
"0.6265324",
"0.62620336",
"0.61888105",
"0.6176866",
"0.61162984",
"0.6114... | 0.7676137 | 0 |
Set the end document marker | public void setEndMarker(String endMarker) {
this.endMarker = endMarker;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void endDocument() { }",
"public void endDocument() {\n }",
"public void endDocument ()\n\t\t{\n\t\t\t//System.out.println(\"End document\");\n\t\t}",
"@Override\n\tpublic void endDocument() {\n\t\t\n\t}",
"public void setEndMark(Integer endMark) {\n this.endMark = endMark;\n }",
"pub... | [
"0.73736703",
"0.73246914",
"0.7103452",
"0.7065216",
"0.68697155",
"0.67887914",
"0.6618963",
"0.6515892",
"0.65046895",
"0.6503985",
"0.64014477",
"0.6389962",
"0.63574505",
"0.6346271",
"0.6337543",
"0.6332824",
"0.62901914",
"0.6280036",
"0.6229684",
"0.61994",
"0.6189483... | 0.7244331 | 2 |
Get the begin marker used | public String getBeginMarker() {
return beginMarker;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"String getBegin();",
"public Integer getBeginOffset() {\n return this.beginOffset;\n }",
"public int getBegin() {\n\t\treturn begin;\n\t}",
"public int getStart() {\r\n\t\treturn this.offset;\r\n\t}",
"public int getStartOffset() {\n return startOffset;\n }",
"public int startOffset();",
... | [
"0.80945385",
"0.7877317",
"0.77983737",
"0.773635",
"0.7577365",
"0.754792",
"0.75377303",
"0.74059725",
"0.7399809",
"0.7393322",
"0.73158747",
"0.72977006",
"0.7237189",
"0.7231361",
"0.7216628",
"0.71159256",
"0.7089335",
"0.7086526",
"0.7059909",
"0.7059474",
"0.70577157... | 0.87904876 | 0 |
Get the end marker used | public String getEndMarker() {
return endMarker;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Integer getEndMark() {\n return endMark;\n }",
"String getEnd();",
"org.mojolang.mojo.lang.Position getEndPosition();",
"public Vector2 getEndLoc( ) { return endLoc; }",
"public int getEndOffset() {\n return endPosition.getOffset();\n }",
"int getEndPosition();",
"pub... | [
"0.8151017",
"0.79016125",
"0.7620242",
"0.75690246",
"0.74841726",
"0.74536276",
"0.7434025",
"0.74247515",
"0.7419224",
"0.7415032",
"0.7414357",
"0.74136907",
"0.73916",
"0.7377389",
"0.7358498",
"0.7354982",
"0.73392004",
"0.7328276",
"0.73101777",
"0.72837096",
"0.727342... | 0.8613414 | 0 |
get value from edittext | @Override
public void onClick(View view) {
String sSouce = etsource.getText().toString().trim();
String dDestiny = etdestination.getText().toString().trim();
// Check condition
if(sSouce.equals("") && dDestiny.equals(""))
{
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private String getFormValue(EditText edit){\n if(edit!=null) return edit.getText().toString();\n else return \"\";\n }",
"public String getText(){\n return input.getText().toString();\n }",
"String getTextValue();",
"private void obtener(){\n Bundle bundle = getIntent().getE... | [
"0.7217696",
"0.7075844",
"0.6593751",
"0.6474581",
"0.64034325",
"0.63260037",
"0.62284726",
"0.6158702",
"0.61466944",
"0.61239445",
"0.610417",
"0.6081316",
"0.6077662",
"0.60759884",
"0.6046566",
"0.5998179",
"0.5986946",
"0.589765",
"0.5842325",
"0.5839633",
"0.58364123"... | 0.0 | -1 |
if the device is not having google map redirect it to playstore | private void DisplayTrack(String sSouce, String dDestiny)
{
try {
//when google map installed
// intialize url
Uri uri = Uri.parse("https://www.google.co.in/maps/dir/" +sSouce + "/" +dDestiny);
//Intialize intent with action view
Intent intent =... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void onMapReady(GoogleMap googleMap) {\n mMap = googleMap;\n mMap.setMapType(GoogleMap.MAP_TYPE_NORMAL);\n\n ////run with it to check what is happening and remove it to see\n\n\n //Initialize Google Play Services\n if (Build.VERSION.SDK_INT >= Build.VERSION_... | [
"0.68485206",
"0.6675917",
"0.66148466",
"0.65956426",
"0.6551386",
"0.653804",
"0.64894307",
"0.6475381",
"0.6460768",
"0.6458335",
"0.6456626",
"0.6446565",
"0.64378834",
"0.6437841",
"0.63952315",
"0.63746613",
"0.63614297",
"0.6350148",
"0.63292277",
"0.63286257",
"0.6290... | 0.5888633 | 91 |
true if resetting through one of the created dialogs. | public SinglePlayerGameController() {
player1 = new Player("Player 1");
computer = new Player("Computer");
game = new Game(new Dice(), player1, computer);
player1.setColor("blue");
computer.setColor("red");
diceImage = new DiceImage();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void reset(){\r\n\t\tdialogToDisplay=0;\r\n\t\tqueuedDialog=0;\r\n\t\toptionSelection=null;\r\n\t\tdone=false;\r\n\t}",
"public void onReset() {\n\n if (dialogFlag) {\n // enter here if resetting through the dialog that pops up at the end of the game.\n resetGame();\n }... | [
"0.68674535",
"0.681002",
"0.6444533",
"0.6380058",
"0.6332798",
"0.6284825",
"0.61956936",
"0.61852473",
"0.61478084",
"0.61450297",
"0.59312874",
"0.592085",
"0.5849568",
"0.5837419",
"0.5827104",
"0.5811388",
"0.5796773",
"0.57736826",
"0.57634544",
"0.5744456",
"0.5695466... | 0.0 | -1 |
Called after constructor, and FXML fields are populated. | @Override
public void initialize(URL location, ResourceBundle resources) {
undoButton.setDisable(true);
resetButton.setDisable(true);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@FXML\n private void initialize() {\n \n }",
"@FXML\n private void initialize() {\n }",
"@FXML\n private void initialize() {\n }",
"@FXML\r\n private void initialize() {\r\n \t\r\n \t\r\n \t\r\n \t\r\n \t\r\n }",
"@FXML\n\tprivate void initialize() {\n\t\t\n\t}... | [
"0.80297476",
"0.7955124",
"0.7955124",
"0.79108983",
"0.7883335",
"0.7883335",
"0.77480257",
"0.7680876",
"0.76068455",
"0.75569844",
"0.7107277",
"0.7103113",
"0.7061463",
"0.70344114",
"0.70314395",
"0.7019747",
"0.7003647",
"0.7002854",
"0.69979525",
"0.6917507",
"0.69174... | 0.0 | -1 |
Sets the player Name to the given param if it is not empty. | void setPlayer1Name(String name) {
if (!name.isEmpty()) {
this.player1.setName(name);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setName(String name)\r\n\t{\r\n\t\tthis.playerName = name;\r\n\t}",
"private void setName(String nameIn){\r\n\t\tplayerName = nameIn;\r\n\t}",
"public Builder setPlayerName(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n playerN... | [
"0.7964506",
"0.7847723",
"0.7804257",
"0.77708066",
"0.76717925",
"0.75244486",
"0.7511081",
"0.7441458",
"0.7362158",
"0.73544526",
"0.7260263",
"0.72353065",
"0.71745306",
"0.7141946",
"0.7131804",
"0.71116835",
"0.70656914",
"0.69534016",
"0.6934146",
"0.687811",
"0.68679... | 0.72997403 | 10 |
Sets the playerName and computerName fields in the SinglePlayerGameScreen.fxml | void setUpPlayerNames() {
playerName.setText(this.player1.getName());
computerName.setText(this.computer.getName());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setNames() {\n\t\tPlayer1 = \"COMPUTER\";\n\t\tPlayer2 = JOptionPane.showInputDialog(null, \"Enter your Name:\");\n\t\tnames_set = true;\n\t}",
"public void displayName(){\n player1.setText(p1.getName());\n player2.setText(p2.getName());\n }",
"public void setPlayer1Name(String nam... | [
"0.7115526",
"0.6755705",
"0.6701899",
"0.6626217",
"0.66189927",
"0.6526753",
"0.6500758",
"0.64801943",
"0.6405188",
"0.64047366",
"0.6387604",
"0.6337563",
"0.63068926",
"0.6294762",
"0.62487197",
"0.6229758",
"0.6202989",
"0.6188633",
"0.6186791",
"0.61852276",
"0.6104666... | 0.7652279 | 0 |
Plays the turn for the player and the computer. | public void onRollClick() {
game.TakeTurn(player1);
game.TakeTurn(computer);
undoButton.setDisable(false);
resetButton.setDisable(false);
updateFields("player");
updateFields("computer");
setLeadPlayerImage();
checkGame();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void play() {\n\n init();\n while (isGameNotFinished()) {\n log.info(\"*** Starting next turn\");\n for (Player player : getPlayers()) {\n executeTurn(player);\n }\n }\n log.info(\"*** Game Finished\");\n }",
"public void play() {\n field.draw();\n userTurn... | [
"0.7909019",
"0.78841174",
"0.7585412",
"0.7495602",
"0.74898064",
"0.74456203",
"0.7335471",
"0.7194963",
"0.71299326",
"0.70660263",
"0.7020319",
"0.6976039",
"0.6883724",
"0.6873873",
"0.6858406",
"0.68507665",
"0.682826",
"0.68190914",
"0.6767922",
"0.676536",
"0.6755271"... | 0.0 | -1 |
Checks on the status of the game, and calls dialog methods depending on whether a Win,Loss, or a draw. | private void checkGame() {
if (game.checkWin()) {
rollButton.setDisable(true);
undoButton.setDisable(true);
this.dialogFlag = true;
if (game.isDraw()) {
showDrawDialog();
return;
}
if (game.getWinner().getNam... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private boolean checkGameStatus() {\n int res = model.getWinner();\n if (res == Model.DRAW) {\n draw();\n return false;\n } else if (res == Model.WHITE) {\n whiteScore++;\n view.getPrompt().setText(whiteName + \" win!\");\n prepareRestart(... | [
"0.7592434",
"0.75574213",
"0.7407398",
"0.6825121",
"0.68148994",
"0.67354244",
"0.6627974",
"0.65658283",
"0.65327287",
"0.65207565",
"0.6459821",
"0.6448335",
"0.6425862",
"0.6380942",
"0.6372804",
"0.6372185",
"0.63318354",
"0.63269186",
"0.63171864",
"0.6266127",
"0.6261... | 0.7986839 | 0 |
Removes last players rolls. | public void onUndo() {
game.undoLastTurn(player1);
game.undoLastTurn(computer);
if (player1.getRollCount() == 0 && computer.getRollCount() == 0) {
setDefault("player");
setDefault("computer");
undoButton.setDisable(true);
resetButton.setDisable(tru... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void removeLastEntry(){\r\n\t\tboards.remove(boards.size() -1 );\r\n\t}",
"private void eliminatePlayer(Player loser){\n players.remove(loser);\n }",
"public void resetPlayers() {\n Player curPlayer;\n for(int i = 0; i < players.size(); i++){\n curPlayer = players.peek... | [
"0.5939011",
"0.5851892",
"0.5787381",
"0.5695608",
"0.55800164",
"0.55717385",
"0.5549574",
"0.55259717",
"0.54857874",
"0.54477835",
"0.54362446",
"0.5429963",
"0.54229146",
"0.53720117",
"0.5327298",
"0.5326513",
"0.532207",
"0.53144723",
"0.52922446",
"0.52830887",
"0.528... | 0.5131055 | 31 |
Resets the game and shows a dialog if reset button is clicked. | public void onReset() {
if (dialogFlag) {
// enter here if resetting through the dialog that pops up at the end of the game.
resetGame();
} else {
// enter here if resetButton is clicked through the fxml.
Alert alert = createWarningAlert();
al... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void resetGame() {\n game.resetScores();\n this.dialogFlag = false;\n rollButton.setDisable(false);\n undoButton.setDisable(true);\n resetButton.setDisable(true);\n setDefault(\"player\");\n setDefault(\"computer\");\n }",
"public void resetGame() {\r\n... | [
"0.8244319",
"0.76912886",
"0.7598339",
"0.7529847",
"0.75161296",
"0.7481589",
"0.7458882",
"0.7417214",
"0.7411165",
"0.7380772",
"0.7288202",
"0.72257364",
"0.7197453",
"0.718854",
"0.7182232",
"0.7136809",
"0.71010983",
"0.70933634",
"0.70816857",
"0.7079963",
"0.7070887"... | 0.8074725 | 1 |
Creates a Warning alert. | private Alert createWarningAlert() {
Alert alert = new Alert(Alert.AlertType.WARNING, "Are you sure, you wan't to Restart The Game?", new ButtonType("Confirm", ButtonBar.ButtonData.YES), new ButtonType("Cancel", ButtonBar.ButtonData.NO));
alert.setTitle("Confirm Deletion");
alert.setHeaderText(n... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void crearAlerta(String titulo,String mensaje){\n Alert alert=new Alert(Alert.AlertType.WARNING);\n alert.setHeaderText(null);\n alert.setTitle(titulo);\n alert.setContentText(mensaje);\n alert.showAndWait();\n }",
"public void alertInvalid(){\n Alert al... | [
"0.6784881",
"0.6590301",
"0.6454649",
"0.6399204",
"0.6315215",
"0.6309044",
"0.6218775",
"0.61726004",
"0.61373967",
"0.60003763",
"0.60003763",
"0.5994116",
"0.5905011",
"0.58904463",
"0.5852999",
"0.58476293",
"0.58193606",
"0.57990324",
"0.5750292",
"0.57497233",
"0.5725... | 0.7853612 | 0 |
Resets game scores and rolls. | private void resetGame() {
game.resetScores();
this.dialogFlag = false;
rollButton.setDisable(false);
undoButton.setDisable(true);
resetButton.setDisable(true);
setDefault("player");
setDefault("computer");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void reset() {\n updateDice(1, 1);\n playerCurrentScore = 0;\n playerScore = 0;\n updateScore();\n notifyPlayer(\"\");\n game.init();\n }",
"void reset() {\n myManager.reset();\n myScore = 0;\n myGameOver = false;\n myGameTicks = myIn... | [
"0.8164592",
"0.79873043",
"0.79204017",
"0.78806806",
"0.77756643",
"0.7768857",
"0.7744503",
"0.7733562",
"0.76985306",
"0.7664222",
"0.7580762",
"0.7558333",
"0.75567317",
"0.74877423",
"0.7475398",
"0.7469204",
"0.7463363",
"0.74106866",
"0.740678",
"0.7404917",
"0.739141... | 0.78624 | 4 |
Loads and shows the previous Screen (playerScreen.fxml). | public void onBack(ActionEvent event) {
try {
Parent root = FXMLLoader.load(getClass().getResource("/Screens/playerScreen.fxml"));
Stage sourceStage = (Stage) ((Node) event.getSource()).getScene().getWindow();
Scene scene = new Scene(root);
sourceStage.setScene(sc... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void showQuestsToPickScreen(){\n try{\n FXMLLoader loader = new FXMLLoader();\n loader.setLocation(Game.class.getResource(\"view/QuestsToPickScreen.fxml\"));\n mainScreenController.getSecondaryScreen().getChildren().clear();\n mainScreenController.getSecond... | [
"0.7095458",
"0.6902767",
"0.6754197",
"0.66317743",
"0.6465853",
"0.64633703",
"0.64578605",
"0.64216495",
"0.6401679",
"0.6350259",
"0.6336173",
"0.6331564",
"0.63232654",
"0.6318088",
"0.63090914",
"0.62933517",
"0.62871325",
"0.6272785",
"0.62381",
"0.6179452",
"0.6153462... | 0.7443163 | 0 |
Sets all fields related to the given playerName to null. | void setDefault(String playerName) {
if (playerName.equals("player")) {
playerLeadImage.setImage(null);
playerDice1.setImage(null);
playerDice2.setImage(null);
playerDice3.setImage(null);
playerRoll.setText(null);
playerScore.setText(null);... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setPlayerPkmnNull()\r\n {\r\n playerPokemon = null;\r\n }",
"public Builder clearPlayerName() {\n \n playerName_ = getDefaultInstance().getPlayerName();\n onChanged();\n return this;\n }",
"@Override\n public final void disqualify(final int playerId) {\n ... | [
"0.66718",
"0.6562732",
"0.5877286",
"0.58399",
"0.5834714",
"0.57837373",
"0.57582915",
"0.57576954",
"0.5756386",
"0.5727441",
"0.57255036",
"0.5674371",
"0.56583655",
"0.56583655",
"0.56583655",
"0.56489474",
"0.564249",
"0.5609395",
"0.56067145",
"0.55941767",
"0.5578861"... | 0.60417587 | 2 |
Updates playerFields based on the given playerName. | private void updateFields(String playerName) {
if (playerName.equals("player")) {
playerRoll.setText(player1.getLastRollAsString() + " (+" + game.getScoreFromRolls(player1.getLastRoll()) + ")");
playerScore.setText(String.valueOf(player1.getScore()));
setPlayerImages("player... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setPlayerName(String playerName) {\n this.playerName = playerName;\n }",
"public void setPlayerName(String playerName) {\n\t\tthis.playerName = playerName;\n\t}",
"public void setPlayerName(String name) {\n \tplayername = name;\n }",
"public void setName(String name)\n {\n pla... | [
"0.6749173",
"0.66681546",
"0.63741285",
"0.61404836",
"0.6114418",
"0.60978407",
"0.60460925",
"0.5934505",
"0.5893155",
"0.589306",
"0.5879374",
"0.5837984",
"0.57102334",
"0.5706747",
"0.5698696",
"0.5692018",
"0.5679651",
"0.5664162",
"0.5641844",
"0.5635672",
"0.5569993"... | 0.7642843 | 0 |
Sets dice images, based on player Rolls and color. | void setPlayerImages(String playerName) {
if (playerName.equals("player")) {
List<Image> images = diceImage.getImageList(player1.getColor(), player1.getLastRoll()); // dice face images corresponding to the player rolls.
playerDice1.setImage(images.get(0));
playerDice2.setImag... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void rollDice(){\n int rollNumber=rng.nextInt(6)+1;\n //int rollNumber=5;\n switch(rollNumber) {\n case 1:\n dice_picture.setImageResource(R.drawable.one);\n break;\n case 2:\n dice_picture.setImageResource(R.drawable.t... | [
"0.6874044",
"0.6469432",
"0.63841134",
"0.6283605",
"0.6123816",
"0.6080649",
"0.6050689",
"0.5987439",
"0.5974315",
"0.5940057",
"0.59291804",
"0.5805876",
"0.57646966",
"0.57553124",
"0.5729866",
"0.57044697",
"0.5688899",
"0.5649121",
"0.56448567",
"0.56390035",
"0.562640... | 0.71364504 | 0 |
Sets the current game target to the given target. | void setTarget(String target) {
try {
int value = Integer.valueOf(target);
game.setTarget(value);
} catch (NumberFormatException e) {
// caused by inputting strings
} catch (IllegalArgumentException e) {
// caused by number < 6.
game.s... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setTarget(Target target) {\n\t\tthis.target = target;\n\t}",
"void setTarget(Node target) {\n\t\tthis.target = target;\n\t}",
"@Override\n\tpublic void setTarget(Object arg0) {\n\t\tdefaultEdgle.setTarget(arg0);\n\t}",
"void setTarget(java.lang.String target);",
"protected void setTarget(Comman... | [
"0.7725266",
"0.7519929",
"0.74635965",
"0.73530364",
"0.73153186",
"0.7301943",
"0.71829826",
"0.7170771",
"0.71252894",
"0.70627904",
"0.70519924",
"0.70365196",
"0.7031604",
"0.70048326",
"0.6944894",
"0.6846337",
"0.6842911",
"0.6766262",
"0.6632043",
"0.6585551",
"0.6584... | 0.7735637 | 0 |
Sets a Trophy image beside the highest score or null if they have the same score. | private void setLeadPlayerImage() {
Player leadPlayer = game.getLeadingPlayer();
if (leadPlayer == null) {
// no lead so set images to default
playerLeadImage.setImage(null);
computerLeadImage.setImage(null);
return;
}
if (leadPlayer.getNam... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setBestScore(double bestScore);",
"public void countHighest (int score){\r\n\t\tif (score > highest){\r\n\t\t\thighest = score;\r\n\t\t}\r\n\t}",
"public HerbierPic getBestPic() {\n\t\tHerbierPic result = null;\n\t\t\n\t\tif (!pics.isEmpty()) {\n\t\t\tVector<HerbierPic> vPics = new Vector<>();\n\t\t\tvPi... | [
"0.54424715",
"0.5396539",
"0.53418505",
"0.53310144",
"0.5321428",
"0.52783394",
"0.5274799",
"0.52478755",
"0.52375066",
"0.51953703",
"0.51843274",
"0.51791006",
"0.5161661",
"0.5161661",
"0.5154261",
"0.5148067",
"0.5143989",
"0.51298606",
"0.51257807",
"0.51257807",
"0.5... | 0.49481097 | 35 |
Displays a confirmation alert, showing both player names and an option to reset. | private void showDrawDialog() {
Alert alert = new Alert(Alert.AlertType.CONFIRMATION, " Game Has Ended in a Draw!! \n\n\n Thanks For Playing " + player1.getName(), new ButtonType("Close", ButtonBar.ButtonData.NO), new ButtonType("Play Again", ButtonBar.ButtonData.YES));
alert.setGraphic(new ImageView(ne... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void confirmationAlert() {\n\t\tAlert confirm = new Alert( AlertType.CONFIRMATION, \"You Will Not Be Able To Change Your Name\\nAfter You Press 'OK'.\");\n\t\tconfirm.setHeaderText(\"Are You Sure?\");\n confirm.setTitle(\"Confirm Name\");\n confirm.showAndWait().ifPresent(response -> {\n ... | [
"0.77949405",
"0.71100837",
"0.6786482",
"0.6721051",
"0.6387067",
"0.6373026",
"0.6333587",
"0.62855774",
"0.6266911",
"0.6241586",
"0.62181985",
"0.61863005",
"0.618188",
"0.6167604",
"0.61633277",
"0.61606777",
"0.6140796",
"0.61083335",
"0.6073075",
"0.6072018",
"0.607149... | 0.0 | -1 |
Displays a confirmation alert, showing the given player's name and an option to reset. | private void showWinnerDialog(Player player) {
Alert alert = new Alert(Alert.AlertType.CONFIRMATION, "Congratulations " + player.getName() + ", You are Victorious!!", new ButtonType("Close", ButtonBar.ButtonData.NO), new ButtonType("Play Again", ButtonBar.ButtonData.YES));
alert.setGraphic(new ImageView... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void promptPlayerTurn(Player player) {\r\n JOptionPane.showMessageDialog(\r\n null,\r\n player.getName() + \", it's your turn!\",\r\n \"Player Confirmation\",\r\n JOptionPane.INFORMATION_MESSAGE);\r\n }",
"private void confirmationAlert() {\n\t\tAlert... | [
"0.75071424",
"0.7248433",
"0.67218846",
"0.6554597",
"0.6313087",
"0.6277797",
"0.6255641",
"0.61849123",
"0.61198205",
"0.610762",
"0.6101068",
"0.60657954",
"0.6054194",
"0.5951015",
"0.59501",
"0.5932872",
"0.59324306",
"0.58962053",
"0.585426",
"0.58513445",
"0.5842965",... | 0.71361816 | 2 |
Displays a confirmations alert, with a defeat text. | private void showLoserDialog() {
Alert alert = new Alert(Alert.AlertType.CONFIRMATION, "You Have Been Defeated " + player1.getName() + ",Computer Wins!!", new ButtonType("Close", ButtonBar.ButtonData.NO), new ButtonType("Try Again?", ButtonBar.ButtonData.YES));
alert.setGraphic(new ImageView(new Image(t... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void confirmationAlert() {\n\t\tAlert confirm = new Alert( AlertType.CONFIRMATION, \"You Will Not Be Able To Change Your Name\\nAfter You Press 'OK'.\");\n\t\tconfirm.setHeaderText(\"Are You Sure?\");\n confirm.setTitle(\"Confirm Name\");\n confirm.showAndWait().ifPresent(response -> {\n ... | [
"0.72818",
"0.67679745",
"0.67238516",
"0.6638484",
"0.6540484",
"0.6500413",
"0.6480908",
"0.6475597",
"0.6454565",
"0.6440377",
"0.6353702",
"0.6338773",
"0.63150805",
"0.6289787",
"0.6245067",
"0.62402385",
"0.62238777",
"0.6215563",
"0.61983",
"0.6191466",
"0.61912465",
... | 0.6027367 | 42 |
metodo che viene chiamato quando l'utente vuole visualizzare il ranking degli utenti | public void load_ranking() throws IOException {
ListOfRows all_users = users_rep.getAllUsersByAverage();
String[] names = {"position", "nickname","num_games", "average"};
String ranking = "[";
// dopo aver preso il riferimento a tutti gli utenti che hanno giocato almeno una partita,
// per ogni utente prelevo... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void refreshRank() {\n rank = getRank();\n lblUserTitle.setText(username + \" - \" + rank);\n }",
"@Override\n\tpublic VisualizarR listarRanking() throws RemoteException {\n\t\treturn null;\n\t}",
"void showRanking(String winner, String rank);",
"public void rank(){\n\n\t}",
"privat... | [
"0.7069418",
"0.70448357",
"0.6944688",
"0.68302435",
"0.6798301",
"0.65196335",
"0.6517822",
"0.65061265",
"0.6485782",
"0.6438292",
"0.6403553",
"0.6400655",
"0.6363024",
"0.63169605",
"0.63094354",
"0.62946063",
"0.6274134",
"0.62677467",
"0.6263655",
"0.6232265",
"0.61930... | 0.5855474 | 66 |
metodo che viene chiamato quando l'utente vuole visualizzare lo storico partite di un utente | public void user_games() throws IOException {
String nickname = request.getParameter("nickname");
games_rep.deleteGamesNotFinished(nickname);
ListOfRows all_games = games_rep.getAllUserGames(nickname);
String[] names = {"number", "game_id","start_date", "finish_date", "score"};
String games = "[";
// dopo a... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void sceltapannelli(String utilizzatore){\n\n if(utilizzatore.equals(\"Registrazione\")){\n\n sez_managerview.setSezA(new Sez_AView().getIntermedio0());\n sez_managerview.setSezB(new Sez_BView().getIntermedio0());\n sez_managerview.setSezC(new Sez_CView().getIntermed... | [
"0.6321759",
"0.6102822",
"0.6069581",
"0.6038684",
"0.6022423",
"0.5944896",
"0.58830667",
"0.5776224",
"0.5770997",
"0.57341146",
"0.5729398",
"0.5693204",
"0.56824243",
"0.5646044",
"0.5645998",
"0.56280875",
"0.55843824",
"0.55837315",
"0.555281",
"0.5551352",
"0.5547365"... | 0.0 | -1 |
metodo che viene chiamato quando l'utente vuole visualizzare lo storico tentativi relativo ad una partita | public void game_attempts() throws IOException {
String game_id = request.getParameter("game_id");
ListOfRows all_attempts = attempts_rep.getAllGameAttempts(game_id);
String[] names = {"num", "attempt", "result"};
String attempts = "[";
// dopo aver preso il riferimento a tutti i tentativi fatti durante una p... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void esegui() {\n /* variabili e costanti locali di lavoro */\n OperazioneMonitorabile operazione;\n\n try { // prova ad eseguire il codice\n\n /**\n * Lancia l'operazione di analisi dei dati in un thread asincrono\n * al termine il thread aggiorna... | [
"0.5816751",
"0.58026206",
"0.5610817",
"0.56010664",
"0.5586046",
"0.557937",
"0.55769616",
"0.5562014",
"0.55439055",
"0.5536032",
"0.5503109",
"0.5500794",
"0.5500712",
"0.54923403",
"0.54846025",
"0.54662895",
"0.5462181",
"0.5452979",
"0.54153067",
"0.5411447",
"0.540823... | 0.0 | -1 |
Set the frame to visible | public void setVisible(){
frame.setVisible(true);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setVisible()\r\n\t{\r\n\t\tthis.setVisible(true);\r\n\t}",
"public void setVisible(boolean visible)\n {\n frame.setVisible(visible);\n }",
"public void setVisible(boolean visible) {\n\t\tframe.setVisible(visible);\n\t}",
"public void setVisible(JFrame frame, boolean visible) {\r\n ... | [
"0.8352362",
"0.8334872",
"0.818507",
"0.8061802",
"0.8043465",
"0.7825553",
"0.78230375",
"0.76350963",
"0.76108646",
"0.75787747",
"0.7438325",
"0.73522985",
"0.7344217",
"0.732209",
"0.7316874",
"0.7315188",
"0.7229466",
"0.72246766",
"0.72246766",
"0.7213738",
"0.7205642"... | 0.8399893 | 0 |
Handle buttons presses from the user for particular questions | @Override
public void actionPerformed(ActionEvent e) {
JButton b = (JButton)e.getSource();
String output = "";
//For each type of question, append to output
try{
if(b.getText().equals("Question 1")){
String prodCompany = q1Field.getText();
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void acceptQueAnswersClicked();",
"public void takeAction() {\n mRelativeLayout.setVisibility(View.INVISIBLE);\n currentQuestion = questionList.get(questionID);\n textView = findViewById(R.id.questionText);\n buttonA = findViewById(R.id.radioA);\n buttonB = findViewById(R.id.ra... | [
"0.7524493",
"0.6897678",
"0.6763619",
"0.6737939",
"0.67375904",
"0.6734036",
"0.67003554",
"0.66901326",
"0.66883284",
"0.668372",
"0.6616766",
"0.66122586",
"0.66077286",
"0.65925866",
"0.6583998",
"0.65806496",
"0.6570884",
"0.6545961",
"0.65458685",
"0.65250224",
"0.6514... | 0.0 | -1 |
1. 1 <= s.length <= 3 10^5 2. s consists of integers and operators ('+', '', '', '/') separated by some number of spaces. 3. s represents a valid expression. 4. All the integers in the expression are nonnegative integers in the range [0, 2^31 1]. 5. The answer is guaranteed to fit in a 32bit integer. 1. parse s to nota... | public int calculate(String s) {
final int len = s.length();
final List<Object> notations = new ArrayList<>();
final Stack<Operator> operatorStack = new Stack<>();
for (int i = 0; i < len; i++) {
final char ch = s.charAt(i);
// case1: AS Space
if (ch ... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public int calculate_2(String s) {\n if ((s == null) || (s.length() == 0)) return 0;\n int i = 0;\n int j = 0;\n s = s.replace(\" \", \"\");\n String val = \"\";\n boolean ifStop = true;\n while (i < s.length()) {\n if ((s.charAt(i) == '+') || (s.charAt(i... | [
"0.6952413",
"0.67760533",
"0.6731745",
"0.65442204",
"0.64959925",
"0.64714015",
"0.6354743",
"0.6335068",
"0.6322278",
"0.631905",
"0.6229413",
"0.61689335",
"0.6162717",
"0.61218953",
"0.6070516",
"0.60448265",
"0.5956832",
"0.59538287",
"0.59313995",
"0.5912608",
"0.59048... | 0.6638312 | 3 |
Default constructor for board. Initiates an empty board of Pieces. | public Board() {
this.board = new Piece[16];
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Board()\n\t{\n\t\tcols = DEFAULT_WIDTH;\n\t\trows = DEFAULT_HEIGHT;\n\t\t\n\t\tpieces = new int[rows][cols];\n\t\tif (pieces.length > 0)\n\t\t{\n\t\t\tfor (int i = 0; i < pieces.length; i++)\n\t\t\t\tfor (int j = 0; j < pieces[0].length; j++)\n\t\t\t\t\tpieces[i][j] = -1;\n\t\t}\n\t}",
"public Board()\r\n... | [
"0.79481655",
"0.7787689",
"0.77611226",
"0.77407503",
"0.7580975",
"0.75750786",
"0.7492513",
"0.74497813",
"0.74107236",
"0.7339326",
"0.7312027",
"0.72959024",
"0.72580683",
"0.7218283",
"0.7200084",
"0.7168082",
"0.7153338",
"0.71465766",
"0.7143841",
"0.7104639",
"0.7077... | 0.7679569 | 4 |
Constructor for Board. Creates a shallowcopy of the input board. | public Board(Piece[] board) {
this.board = copyOf(board);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Board(Board board) {\n copyFrom(board);\n }",
"@Override\n public Board clone() {\n return new Board(copyOf(this.board));\n }",
"Board(Board b) {\n internalCopy(b);\n }",
"Board(Board model) {\r\n copy(model);\r\n }",
"public Board deepCopy() {\n Board copy... | [
"0.7878634",
"0.77877",
"0.7550276",
"0.75335073",
"0.74297297",
"0.73112905",
"0.7244389",
"0.7235811",
"0.7037651",
"0.7023646",
"0.7014974",
"0.70071965",
"0.69945836",
"0.6930397",
"0.68923885",
"0.6879564",
"0.68467313",
"0.6802179",
"0.6760651",
"0.6750035",
"0.6746966"... | 0.73178875 | 5 |
Copies all the pieces of a board. | public final Piece[] copyOf(Piece[] b) {
Piece[] c = new Piece[16];
// for (int i = 0; i < c.length; i++) {
// System.arraycopy(b[i], 0, c[i], 0, b[i].length);
// }
System.arraycopy(b, 0, c, 0, b.length);
return c;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public BoardFramework copyBoard() {\n List<List<GamePiece>> pieceCopies= new ArrayList<>();\n for(List<GamePiece> row: myGamePieces){\n List<GamePiece> rowOfPieceCopies = new ArrayList<>();\n for(GamePiece piece: row){\n rowOfPieceCopies.add(piece.c... | [
"0.809433",
"0.7940311",
"0.71510535",
"0.7095861",
"0.686109",
"0.68607754",
"0.68033004",
"0.67978233",
"0.67870593",
"0.67387295",
"0.6729053",
"0.6723951",
"0.66969824",
"0.66925144",
"0.6678313",
"0.66737556",
"0.6665641",
"0.6657269",
"0.66257083",
"0.66018116",
"0.6589... | 0.0 | -1 |
Checks if you have a streak in some way. A streak is two or three in a row. | public Streak[] findStreaks() {
List<Streak> streaks = new LinkedList<>();
Streak s;
Piece[][] arrs = new Piece[4][4];
Piece[][] diagArr = new Piece[2][4];
int f;
for (int row = 0; row < 4; row++) {
f = 4 * row;
s = Streak.gotStreak(Arrays.copyOfRa... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void checkLongestStreak(){\n int max = _maxStreak;\n int streak = 1;\n if (_savedDates.size() > 1) {\n for (int i = 0; i < _savedDates.size() - 1; i++) {\n LocalDate prevDay = _savedDates.get(i).minusDays(1);\n LocalDate nextDay = _savedDates.get... | [
"0.61925787",
"0.5932354",
"0.5812917",
"0.5738518",
"0.5695375",
"0.5636561",
"0.56187284",
"0.5599138",
"0.55674165",
"0.5560861",
"0.55061775",
"0.5505573",
"0.5502042",
"0.54974556",
"0.54604965",
"0.54533476",
"0.54487246",
"0.54441744",
"0.54212946",
"0.5400125",
"0.539... | 0.6120821 | 1 |
Overridden clone method for Board. | @Override
public Board clone() {
return new Board(copyOf(this.board));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public GameBoard clone(){\r\n\t\tGameBoard result = new GameBoard();\r\n\t\ttry{\r\n\t\t\tresult = (GameBoard) super.clone();\r\n\t\t}catch(CloneNotSupportedException e){\r\n\t\t\tthrow new RuntimeException();\r\n\t\t}\r\n\t\tresult.board = (Box[]) board.clone();\r\n\t\treturn result;\r\n\t}",
"protected final O... | [
"0.83995575",
"0.8209224",
"0.8192727",
"0.78029597",
"0.77484375",
"0.7690251",
"0.7690251",
"0.76525444",
"0.73936266",
"0.7369666",
"0.73524594",
"0.728919",
"0.7287786",
"0.72253793",
"0.71600425",
"0.71341634",
"0.7105117",
"0.70311195",
"0.700817",
"0.70036924",
"0.6990... | 0.8859982 | 0 |
ToString method for Board. | @Override
public String toString() {
StringBuilder sb = new StringBuilder();
//Print board
int c = 0;
for (Piece piece : board) {
if (piece == null) {
sb.append("\t");
} else {
sb.append(piece.pieceString()).append("\t");
... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String toString()\n\t{\n\t\tString s = \"\";\n\t\tfor(int r = 0; r < board.length; r++)\n\t\t{\n\t\t\tfor(int c = 0; c < board[0].length; c++)\n\t\t\t{\n\t\t\t\ts += \"|\" + board[r][c];\n\t\t\t}\t\t\t\t\n\t\t\ts += \"|\" + \"\\n\" + \"-------------------\" + \"\\n\";\n\t\t}\n\t\treturn s;\n\t}",
"public ... | [
"0.8447841",
"0.83170426",
"0.8241111",
"0.820521",
"0.8147127",
"0.8138529",
"0.8114983",
"0.80876404",
"0.8083503",
"0.8064477",
"0.8054218",
"0.798601",
"0.7962315",
"0.7943855",
"0.7869261",
"0.78541845",
"0.7844291",
"0.7834369",
"0.7810531",
"0.7765031",
"0.7700164",
... | 0.8201244 | 4 |
Represents the board of Pieces. 4x4. | public Piece[] getBoard() {
return board;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public OthelloBoard (int height, int width){\n super(height, width);\n m_Pieces = new OthelloPiece[WIDTH][HEIGHT];\n m_PieceCount+=4;\n \n }",
"private Board create4by4Board() {\n Tile[][] tiles;\n Tile t1 = new Tile(0, 4);\n Tile t2 = new Ti... | [
"0.6960172",
"0.6871505",
"0.6693149",
"0.6661959",
"0.66611725",
"0.66515905",
"0.6529679",
"0.6524264",
"0.64737695",
"0.64692813",
"0.6453492",
"0.64451987",
"0.6343312",
"0.6334752",
"0.6319503",
"0.62921596",
"0.6289504",
"0.62496436",
"0.6247684",
"0.62465835",
"0.62429... | 0.63580936 | 12 |
Returns the metric name. | public abstract String getName(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"java.lang.String getMetricName();",
"public String metricName() {\n return this.metricName;\n }",
"public String getName() {\n \treturn metricMetadata.getName();\n }",
"public String getMetricName() {\n return this.MetricName;\n }",
"com.google.protobuf.ByteString getMetricNameByt... | [
"0.9027858",
"0.83396626",
"0.8221193",
"0.8206966",
"0.8190998",
"0.75678897",
"0.7256314",
"0.71969444",
"0.7196357",
"0.65780306",
"0.6564218",
"0.6439271",
"0.6429318",
"0.63559896",
"0.63258713",
"0.624326",
"0.622743",
"0.6201581",
"0.6166817",
"0.61324793",
"0.61300725... | 0.0 | -1 |
Returns the description of this metric. | public abstract String getDescription(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String getDescription() {\n \treturn metricMetadata.getDescription();\n }",
"public String getDescription() {\n if (description == null) {\n description = Description.getDescription(this);\n }\n return description;\n }",
"@Override\r\n\tpublic String getDesc... | [
"0.8842358",
"0.7796318",
"0.7629663",
"0.7566019",
"0.7542266",
"0.754172",
"0.754172",
"0.754172",
"0.754172",
"0.754172",
"0.7533555",
"0.7532331",
"0.7532109",
"0.7506865",
"0.7506865",
"0.7506865",
"0.7506865",
"0.7506865",
"0.7506865",
"0.7506865",
"0.7506865",
"0.750... | 0.0 | -1 |
Returns the unit of this metric. | public abstract String getUnit(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String unit() {\n return this.unit;\n }",
"public String getUnit() {\n\t\tString unit;\n\t\ttry {\n\t\t\tunit = this.getString(\"unit\");\n\t\t} catch (Exception e) {\n\t\t\tunit = null;\n\t\t}\n\t\treturn unit;\n\t}",
"public String getUnit()\n {\n return (this.unit);\n }",
"public Str... | [
"0.8506343",
"0.8418792",
"0.823919",
"0.82091856",
"0.8187678",
"0.8187678",
"0.8187678",
"0.8092982",
"0.80339384",
"0.7979287",
"0.7869787",
"0.7829437",
"0.77820146",
"0.77543205",
"0.7751282",
"0.76875335",
"0.7644389",
"0.74471325",
"0.74325097",
"0.74292016",
"0.742493... | 0.6607105 | 74 |
Returns the type of this metric. | public abstract MetricDataType getType(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String getType() {\r\n return this.getClass().getName();\r\n }",
"public String getType() {\n return (String) getObject(\"type\");\n }",
"public final String getType() {\n return this.getClass().getName();\n }",
"public String getType() {\n\t\treturn TYPE_NAME;\n\t}",
"public... | [
"0.7049675",
"0.70209527",
"0.70151436",
"0.69554645",
"0.69268245",
"0.69268245",
"0.69268245",
"0.69268245",
"0.69268245",
"0.69268245",
"0.69268245",
"0.69268245",
"0.6926267",
"0.6916516",
"0.6916516",
"0.6916516",
"0.69144344",
"0.6914125",
"0.68927956",
"0.6890156",
"0.... | 0.81259805 | 0 |
1. find the top tag 2. find the top level tags within it 3. reorder the tags based on the sort order 4. apply the changes to the document | private boolean performRearrange(List<CommonToken> tokens) throws BadLocationException
{
List<TagHolder> topLevelTags=new ArrayList<MXMLRearranger.TagHolder>();
int tagLevel=0;
for (int tokenIndex=0;tokenIndex<tokens.size();tokenIndex++)
{
CommonToken token=tokens.get(tokenIndex);
System.out.println(toke... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void sort() {\n documents.sort();\n }",
"private void devideVorlage(List<TemplateTag> tags) throws MissingTagException{\r\n \t\tTreeSet<TemplateTag> sortedTags = new TreeSet<TemplateTag>();\r\n \t\tfor (TemplateTag tag:tags){\r\n \t\t\tint position = template.indexOf(tag.name);\r\n \t\t\tif(position >... | [
"0.5828753",
"0.5592646",
"0.54797655",
"0.54664594",
"0.54234815",
"0.53948385",
"0.5353384",
"0.532636",
"0.53102815",
"0.5294943",
"0.52933735",
"0.52709776",
"0.52380025",
"0.5212677",
"0.5196087",
"0.51607305",
"0.51382947",
"0.51218784",
"0.50995064",
"0.5091501",
"0.50... | 0.50196606 | 24 |
Search forward to find the next tag name and add it to the holder | private void addTagName(TagHolder holder, List<CommonToken> tokens, int tokenIndex)
{
tokenIndex++;
for (;tokenIndex<tokens.size(); tokenIndex++)
{
CommonToken tok=tokens.get(tokenIndex);
if (tok.getType()==MXMLLexer.GENERIC_ID)
{
holder.setTagName(tok.getText());
return;
}
else if (tok.g... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void goToNextTag(String tag) throws ParseException {\n // Get the text inside the column\n String open = \"<\" + tag;\n int pos = html.indexOf(open, position + 1);\n if (pos == -1) {\n throw new ParseException(\"Cannot skip tag because open \" + tag + \" doesnt exist.\... | [
"0.6061773",
"0.6057768",
"0.6010363",
"0.5956096",
"0.5586467",
"0.54936856",
"0.5443552",
"0.54242253",
"0.5398983",
"0.5390891",
"0.5384347",
"0.5375731",
"0.5365955",
"0.53430665",
"0.5339067",
"0.5336429",
"0.530248",
"0.5279522",
"0.5246683",
"0.5237727",
"0.5209708",
... | 0.5816617 | 4 |
TODO Autogenerated method stub | public List<Exception> getErrors() {
return null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.608016... | 0.0 | -1 |
The day we search | public DepotTimetableAsk() {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"java.lang.String getFoundingDate();",
"private Integer recognizeDay(String header) {\n Integer returned = -1;\n for (Integer day = 0; day < 7; day++) {\n if (header.contains(this.daysPatterns[day])) {\n returned = day;\n break;\n }\n ... | [
"0.6887448",
"0.6556532",
"0.6490291",
"0.6444248",
"0.62702",
"0.62017447",
"0.6182862",
"0.6114915",
"0.6029131",
"0.5976414",
"0.5970821",
"0.59685695",
"0.5950594",
"0.5937545",
"0.59284854",
"0.5908405",
"0.59021896",
"0.5900115",
"0.5895375",
"0.58770806",
"0.58704334",... | 0.0 | -1 |
TODO Autogenerated method stub | public void updateDoctor(Promodel pro2) {
pro.updateDoctor(pro2);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.608016... | 0.0 | -1 |
Constructor MotorPositionConstant is a Command that runs while setting a SensorMotor's position to the provided (double) value. | public MotorPositionConstant(String name, PositionSensorMotor motor, double position, boolean endOnArrival,
CommandBase fallbackCommand) {
super();
setName(name);
addRequirements(motor);
this.motor = motor;
this.position = position;
this.endOnArrival = endOnArrival;
this.fallbackCommand = fallbackComma... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void moveServoTo(double motorPosition) {\n\t\ttry {\n\t\t\t// Get the servo that is available\n\t\t\tMotorMover.getInstance();\n\t\t\tSystem.out.println(\"Lock opening: Moving to lock position \" + motorPosition);\n\t\t\tservo.setMaxPosition(210.0);\n\t\t\tservo.setTargetPosition(motorPosition);\n\t\... | [
"0.60840845",
"0.597522",
"0.59429336",
"0.5753173",
"0.56535286",
"0.55937374",
"0.5592571",
"0.55914384",
"0.556831",
"0.5549541",
"0.5540395",
"0.553276",
"0.5492339",
"0.54241157",
"0.5422216",
"0.54204947",
"0.5340164",
"0.53289366",
"0.52913356",
"0.5251129",
"0.5238023... | 0.7024969 | 0 |
Store application properties where the mappers/reducers can access them | private void setProperties( JobConf conf ) throws IOException {
Config index_conf = ConfigFactory.load();
conf.set( CONFIG_PROPERTIES, index_conf.toString());
// Also set mapred speculative execution off:
conf.set( "mapred.reduce.tasks.speculative.execution", "false" );
// Reducer count dependent on c... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void createApplicationProperties()\n {\n _applicationPropertiesMap = new HashMap<String,Object>();\n _message.setApplicationProperties(new ApplicationProperties(_applicationPropertiesMap));\n }",
"public Vector getApplicationProperties() {\n return appProperties;\n }",
"pr... | [
"0.62221694",
"0.59337384",
"0.5901856",
"0.5638826",
"0.5593013",
"0.5549183",
"0.5502642",
"0.53766775",
"0.5341507",
"0.5323771",
"0.530679",
"0.53013706",
"0.52942216",
"0.5258264",
"0.5224611",
"0.51498723",
"0.5101973",
"0.50807625",
"0.5072047",
"0.50583285",
"0.503428... | 0.49843886 | 22 |
Set menu on top of page | @Override
public boolean onCreateOptionsMenu(Menu menu) {
getMenuInflater().inflate(R.menu.menu_product, menu);
return true;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\tpublic void setUpMenu() {\n\t\t\n\t}",
"public void initMenu(){\n\t}",
"public void menu(){\n super.goToMenuScreen();\n }",
"private void goToMenu() {\n\t\tgame.setScreen(new MainMenuScreen(game));\n\n\t}",
"@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getM... | [
"0.672006",
"0.64817727",
"0.64587194",
"0.6417921",
"0.6388163",
"0.6387113",
"0.63316315",
"0.62807864",
"0.6235086",
"0.6215",
"0.6190447",
"0.6134153",
"0.61158043",
"0.61138606",
"0.61041564",
"0.6096726",
"0.6082685",
"0.6081529",
"0.60773283",
"0.6076684",
"0.6074035",... | 0.0 | -1 |
Extends the name space prefix with the actual name space All tests that need to ensure privacy, i.e. no other test shall mess up their data, shall use name spacing. Data that can be messed up by other tests and there fore needs to be unique shall contain the name space prefix that will be replaced at run time. | public String namespaceString(String plainString) throws RuntimeException {
if(plainString.startsWith(NAME_SPACE_PREFIX)) {
return (plainString.replace(NAME_SPACE_PREFIX, nameSpaceThreadLocale.get()));
}
if(plainString.startsWith(SCENARIO_NAME_SPACE_PREFIX)) {
if(cucumberManager.getCurr... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setNameSpacePrefix(String nsPrefix) {\n this.nsPrefix = nsPrefix;\n }",
"public void setNameSpace(String namespace) {\n this.namespace = namespace;\n }",
"void declarePrefix(String prefix, String namespace);",
"public void testSetNamespacePrefix() throws RepositoryException{\n... | [
"0.648035",
"0.6409376",
"0.6367173",
"0.63550985",
"0.6283052",
"0.62811834",
"0.62018746",
"0.61542785",
"0.60871536",
"0.60683703",
"0.6037412",
"0.6014632",
"0.59980583",
"0.58802295",
"0.58627194",
"0.5848953",
"0.5843615",
"0.5831952",
"0.5810405",
"0.578928",
"0.578928... | 0.5553234 | 31 |
TODO Autogenerated method stub | public ProjectBean mapRow(ResultSet rs, int rowNum) throws SQLException {
ProjectBean user = new ProjectBean();
user.setPopID(rs.getInt("Pop_id"));
user.setPopTitle(rs.getString("Pop_title"));
user.setPopCategory(rs.getString("Pop_category"));
user.setPopDescription(rs.getString("Pop_description"))... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.66708666",
"0.65675074",
"0.65229905",
"0.6481001",
"0.64770633",
"0.64584893",
"0.6413091",
"0.63764185",
"0.6275735",
"0.62541914",
"0.6236919",
"0.6223816",
"0.62017626",
"0.61944294",
"0.61944294",
"0.61920846",
"0.61867654",
"0.6173323",
"0.61328775",
"0.61276996",
"0... | 0.0 | -1 |
TODO Autogenerated method stub | public void deleteUser(int userID) {
String sql = "DELETE FROM Portfolio_of_Project WHERE Pop_id = " + userID;
jdbcTemplate.update(sql);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.608016... | 0.0 | -1 |
Save a new record | public abstract T create(T obj); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void save();",
"public void save();",
"public void save();",
"public void save();",
"@Override\n\tpublic void save(Borrowrecord borrowrecord) {\n\t\tthis.borrowrecordMapper.insert(borrowrecord);\n\t}",
"@Override\r\n\tpublic void save() {\n\r\n\t\ts.save();\r\n\r\n\t}",
"protected void saveRecor... | [
"0.74424285",
"0.74424285",
"0.74424285",
"0.74424285",
"0.72065663",
"0.7140481",
"0.7019621",
"0.69679135",
"0.69554865",
"0.6946507",
"0.6936493",
"0.693491",
"0.6912591",
"0.6880172",
"0.6880172",
"0.6880172",
"0.68445075",
"0.6839437",
"0.68290406",
"0.6826043",
"0.68141... | 0.0 | -1 |
Find a record by ID | public abstract T findOne(int id); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Data findById(Object id);",
"@Override\r\n\tpublic FyTestRecord findById(Long id) {\n\t\treturn testRecordDao.findOne(id);\r\n\t}",
"T findById(ID id) ;",
"@Override\r\n\tpublic void find(Integer id) {\n\r\n\t}",
"public Record readRecord(Long id);",
"@Override\n public T findById(ID id) throws... | [
"0.7562682",
"0.75476134",
"0.7504318",
"0.7428646",
"0.73869836",
"0.72333455",
"0.72254604",
"0.721012",
"0.7177093",
"0.70928437",
"0.7081635",
"0.7073389",
"0.70669705",
"0.70416963",
"0.7020453",
"0.7019908",
"0.70075625",
"0.6996231",
"0.69666135",
"0.6942355",
"0.69294... | 0.734769 | 5 |
Find a range of records | public abstract ArrayList<T> findAll(int limit, int offset); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"java.util.List<AuditoriaUsuario> findRange(int startPosition, int maxResults, String sortFields, String sortDirections);",
"List<ResultsView2> findByCnoBetween(int min,int max);",
"private List<T> findRange(RequestData requestData) {\n javax.persistence.criteria.CriteriaQuery cq = getEntityManager().ge... | [
"0.7039367",
"0.6976257",
"0.68763286",
"0.66017723",
"0.6409292",
"0.6336907",
"0.62372786",
"0.6203736",
"0.61523646",
"0.61312336",
"0.61223817",
"0.60525864",
"0.6045",
"0.6043015",
"0.6035334",
"0.60046893",
"0.5958898",
"0.59534305",
"0.5899947",
"0.5896917",
"0.5882848... | 0.0 | -1 |
Return the number or records | public abstract int count(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected abstract int getNumRecords();",
"public Integer countRecordReturns();",
"int getRecordCount();",
"public int getNumOfRecords() {\n return records.size();\n }",
"@Override\r\n\tpublic int findTotalRecords() throws Exception {\n\t\treturn 0;\r\n\t}",
"public Integer getRecordCount() {\n... | [
"0.8051749",
"0.7750377",
"0.77486926",
"0.727311",
"0.71539915",
"0.71320885",
"0.7112529",
"0.7109262",
"0.70870304",
"0.70578545",
"0.7027972",
"0.69540745",
"0.6926355",
"0.6839428",
"0.6808404",
"0.67633057",
"0.67633057",
"0.67633057",
"0.6762192",
"0.6762192",
"0.67585... | 0.0 | -1 |
Give the timestamp of the current date and time | public Timestamp getTimestamp() {
return new Timestamp(new Date().getTime());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private String getCurrentTimestamp() {\n\n String mytime = java.text.DateFormat.getTimeInstance().format(Calendar.getInstance().getTime());\n String mydate =java.text.DateFormat.getDateTimeInstance().format(Calendar.getInstance().getTime());\n return mytime;\n }",
"public static Timestamp... | [
"0.8310103",
"0.81689453",
"0.8151778",
"0.8142482",
"0.8054355",
"0.8031589",
"0.7972714",
"0.7957746",
"0.7897369",
"0.7854024",
"0.7831557",
"0.7791672",
"0.77037936",
"0.7697269",
"0.76740867",
"0.7661463",
"0.76450354",
"0.7606529",
"0.7605676",
"0.7591607",
"0.7577201",... | 0.0 | -1 |
Returns the last inserted ID for a database query | public int getLastInsertedId(PreparedStatement statement) throws SQLException {
ResultSet generatedKeys = statement.getGeneratedKeys();
if (generatedKeys.next()) return (int) generatedKeys.getLong(1);
return 0;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public Long getLastInsertId() {\n Long lastId = 0L;\n Map<String, Object> paramMap = new HashMap<>();\n paramMap.put(\"lastID\", lastId);\n jdbc.query(SELECT_LAST_INSERT_ID, paramMap, rowMapper);\n return lastId;\n }",
"@Query(value = \"select last_insert_id()... | [
"0.80199593",
"0.79719007",
"0.79012233",
"0.7520077",
"0.73613507",
"0.72923625",
"0.7082341",
"0.7040327",
"0.6831771",
"0.6828458",
"0.666842",
"0.65732265",
"0.6538271",
"0.6524933",
"0.6503483",
"0.6441222",
"0.6432747",
"0.6401212",
"0.6384957",
"0.6354819",
"0.62283504... | 0.74378896 | 4 |
Creates a new server scheduled event builder for the given server. | public ServerScheduledEventBuilder(Server server) {
delegate = DelegateFactory.createServerScheduledEventBuilderDelegate(server);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Server createServer(Server server){\n\t\tlogger.info(\"Creating the Server with the given details\");\n\t\tint id = servers.size()+1+1000;\n\t\tlogger.info(\"The Server id is \"+id);\n\t\tserver.setServerId(id);\n\t\tserver.setServerStatus(ServerStatus.BUILDING);\n\t\tServerBuilder serverBuilder = new Serve... | [
"0.6412051",
"0.6303565",
"0.5977673",
"0.59765536",
"0.52628225",
"0.52258736",
"0.5207759",
"0.515401",
"0.514665",
"0.5139216",
"0.5089942",
"0.5075306",
"0.50281775",
"0.49550357",
"0.49491572",
"0.4936914",
"0.48908788",
"0.48836803",
"0.48692054",
"0.48640674",
"0.48485... | 0.80042857 | 0 |
Sets the reason for the creation. This reason will be visible in the audit log entry(s). | public ServerScheduledEventBuilder setAuditLogReason(String reason) {
delegate.setAuditLogReason(reason);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setReason(String reason);",
"public void setReason(String value) {\n this.reason = value;\n }",
"@Override\n public void setReason( String arg0)\n {\n \n }",
"public void setReason(String reason) {\n this.reason = reason;\n }",
"public void setReason(String reason... | [
"0.6663615",
"0.6512384",
"0.6487992",
"0.6266184",
"0.62517434",
"0.62301683",
"0.6198617",
"0.6198617",
"0.6198617",
"0.61615044",
"0.61603546",
"0.5748674",
"0.5620754",
"0.55896395",
"0.5573764",
"0.55646163",
"0.55646163",
"0.55646163",
"0.55646163",
"0.55401456",
"0.553... | 0.60253817 | 11 |
Sets the name of the server scheduled event. | public ServerScheduledEventBuilder setName(String name) {
delegate.setName(name);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setName (String name) {\n this.name = name;\n NameRegistrar.register (\"server.\"+name, this);\n }",
"public void setEventName(String name);",
"public void setName(String name) {\n Errors e = Errors.getInstance();\n if (name.length() > 50) {\n e.setError(\"... | [
"0.6896423",
"0.67949766",
"0.6628598",
"0.6455413",
"0.6169679",
"0.6127441",
"0.6116168",
"0.60889995",
"0.6070608",
"0.6049037",
"0.6047465",
"0.6035149",
"0.59903103",
"0.59852177",
"0.5934404",
"0.5930907",
"0.5929607",
"0.59268504",
"0.5925228",
"0.5922727",
"0.59175855... | 0.79186136 | 0 |
Sets the description of the server scheduled event. | public ServerScheduledEventBuilder setDescription(String description) {
delegate.setDescription(description);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setEventDescription(String newDesc) {\n\t\tthis.description = newDesc;\n\t}",
"private void setEventDescription(String eventDescription)\n\t{\n\t\tsomethingChanged = true;\n\t\tthis.eventDescription = eventDescription;\n\t}",
"public void setDescription(String description) {\n this.description =... | [
"0.6950876",
"0.68996036",
"0.66997206",
"0.66813225",
"0.66652596",
"0.66602844",
"0.6656131",
"0.6564983",
"0.6560565",
"0.6549917",
"0.6543613",
"0.65366066",
"0.6482148",
"0.64800626",
"0.6463968",
"0.64597356",
"0.64597356",
"0.64597356",
"0.64160544",
"0.64048475",
"0.6... | 0.79255474 | 0 |
Sets the scheduled start time of the server scheduled event. | public ServerScheduledEventBuilder setScheduledStartTime(Instant scheduledStartTime) {
delegate.setScheduledStartTime(scheduledStartTime);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final void setScheduledStart(java.util.Date scheduledstart)\r\n\t{\r\n\t\tsetScheduledStart(getContext(), scheduledstart);\r\n\t}",
"public final void setScheduledStart(com.mendix.systemwideinterfaces.core.IContext context, java.util.Date scheduledstart)\r\n\t{\r\n\t\tgetMendixObject().setValue(context, M... | [
"0.7566538",
"0.72882533",
"0.6921827",
"0.6921827",
"0.6916549",
"0.6916549",
"0.6801644",
"0.67817986",
"0.67020243",
"0.6653592",
"0.6653592",
"0.6612624",
"0.66003305",
"0.6513899",
"0.650429",
"0.64760566",
"0.64630824",
"0.6408693",
"0.6395964",
"0.63815594",
"0.6370171... | 0.7507348 | 1 |
Sets the scheduled end time of the server scheduled event. | public ServerScheduledEventBuilder setScheduledEndTime(Instant scheduledEndTime) {
delegate.setScheduledEndTime(scheduledEndTime);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final void setScheduledEnd(java.util.Date scheduledend)\r\n\t{\r\n\t\tsetScheduledEnd(getContext(), scheduledend);\r\n\t}",
"public final void setScheduledEnd(com.mendix.systemwideinterfaces.core.IContext context, java.util.Date scheduledend)\r\n\t{\r\n\t\tgetMendixObject().setValue(context, MemberNames.S... | [
"0.7756697",
"0.7330091",
"0.70611554",
"0.6897964",
"0.68757606",
"0.68069625",
"0.67923963",
"0.6734847",
"0.6726902",
"0.6726902",
"0.6704425",
"0.6704425",
"0.67020226",
"0.6584039",
"0.6577177",
"0.6574082",
"0.65616715",
"0.65376997",
"0.6536675",
"0.6529971",
"0.651131... | 0.7341181 | 1 |
Sets the scheduled start and end time of the server scheduled event. | public ServerScheduledEventBuilder setScheduledStartAndEndTime(Instant scheduledStartTime, Duration duration) {
return setScheduledStartTime(scheduledStartTime).setScheduledEndTime(scheduledStartTime.plus(duration));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public ServerScheduledEventBuilder setScheduledStartTime(Instant scheduledStartTime) {\n delegate.setScheduledStartTime(scheduledStartTime);\n return this;\n }",
"public ServerScheduledEventBuilder setScheduledEndTime(Instant scheduledEndTime) {\n delegate.setScheduledEndTime(scheduledEnd... | [
"0.6856287",
"0.6749313",
"0.6733199",
"0.66154623",
"0.6431447",
"0.6376507",
"0.6360168",
"0.61947036",
"0.61513966",
"0.61306185",
"0.6086373",
"0.6055199",
"0.5991267",
"0.597811",
"0.59672016",
"0.5966794",
"0.5936533",
"0.58974624",
"0.58874416",
"0.58593345",
"0.584166... | 0.68130517 | 1 |
Sets the privacy level of the server scheduled event. | public ServerScheduledEventBuilder setPrivacyLevel(
ServerScheduledEventPrivacyLevel serverScheduledEventPrivacyLevel) {
delegate.setPrivacyLevel(serverScheduledEventPrivacyLevel);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setPrivacy(@Nullable final AlbumPrivacy privacy) {\n mPrivacy = privacy;\n }",
"public void setPortalCooldown ( int cooldown ) {\n\t\tinvokeSafe ( \"setPortalCooldown\" , cooldown );\n\t}",
"public void setPrivacy(String privacy) throws ParseException;",
"public void setPrivado(Boolean ... | [
"0.5070432",
"0.49934503",
"0.49791154",
"0.4848857",
"0.47798383",
"0.4779316",
"0.4736818",
"0.47039127",
"0.46708047",
"0.46534437",
"0.4635265",
"0.46300447",
"0.4615691",
"0.4611335",
"0.4596845",
"0.4586319",
"0.45776626",
"0.45533118",
"0.45462564",
"0.45346862",
"0.45... | 0.7481849 | 0 |
Sets the channel of the server scheduled event. | public ServerScheduledEventBuilder setChannel(ServerVoiceChannel channel) {
delegate.setChannelId(channel.getId());
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setChannel(EzyChannel channel);",
"public ServerScheduledEventBuilder setChannelId(Long channelId) {\n delegate.setChannelId(channelId);\n return this;\n }",
"public void SetChannel(int channel);",
"public void setChannel(Channel channel)\n {\n this.channel = channel;\n }",
"... | [
"0.6570824",
"0.6473136",
"0.64414775",
"0.64401466",
"0.6102281",
"0.6080319",
"0.6047398",
"0.60366195",
"0.58676755",
"0.58670974",
"0.5839634",
"0.58234435",
"0.5821302",
"0.5820105",
"0.57514906",
"0.5694472",
"0.56836414",
"0.5682053",
"0.5652145",
"0.5603479",
"0.55950... | 0.6939027 | 0 |
Sets the channel id of the server scheduled event. | public ServerScheduledEventBuilder setChannelId(Long channelId) {
delegate.setChannelId(channelId);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setChannelId( int channelId ) {\r\n this.channelId = channelId;\r\n }",
"public Builder setChannelId(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n channelId_ = value;\n onChanged();\n return this;\n }",
... | [
"0.6340392",
"0.6312064",
"0.62745464",
"0.6156224",
"0.61388075",
"0.60875875",
"0.6016108",
"0.5966649",
"0.5965249",
"0.5935995",
"0.5916044",
"0.58945733",
"0.5876428",
"0.5812904",
"0.5671132",
"0.56552505",
"0.5608655",
"0.55793995",
"0.55509573",
"0.5550748",
"0.542551... | 0.7385589 | 0 |
Sets the entity type of the server scheduled event. | public ServerScheduledEventBuilder setEntityType(ServerScheduledEventType serverScheduledEventType) {
delegate.setEntityType(serverScheduledEventType);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setEntityType(StageableEntity entityType) {\n\t\tthis.entityType = entityType;\n\t}",
"@Immutable\n @IcalProperties({\n @IcalProperty(pindex = PropertyInfoIndex.ENTITY_TYPE,\n jname = \"entityType\",\n required = true,\n eventProperty = true,\n ... | [
"0.665833",
"0.6428985",
"0.63896906",
"0.63661087",
"0.63138556",
"0.6298658",
"0.619627",
"0.5989304",
"0.59887147",
"0.58740205",
"0.5850457",
"0.5826945",
"0.58244675",
"0.58188844",
"0.56389076",
"0.5600285",
"0.5592434",
"0.5566877",
"0.55644524",
"0.55488616",
"0.55028... | 0.7490224 | 0 |
Sets the entity metadata location of the server scheduled event. | public ServerScheduledEventBuilder setEntityMetadataLocation(String entityMetadataLocation) {
delegate.setEntityMetadataLocation(entityMetadataLocation);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public ServerScheduledEventMetadataImpl(JsonNode data) {\n this.location = data.path(\"location\").textValue();\n }",
"public void setMetadata(String metadataKey, MetadataValue newMetadataValue) {\n/* 787 */ this.server.getEntityMetadata().setMetadata(this, metadataKey, newMetadataValue);\n/* ... | [
"0.6268268",
"0.5672732",
"0.5592622",
"0.5572509",
"0.5375435",
"0.5252831",
"0.51800454",
"0.51683575",
"0.5159919",
"0.5111142",
"0.50573945",
"0.5039708",
"0.5036686",
"0.50133693",
"0.49894607",
"0.4967133",
"0.4904041",
"0.48970005",
"0.488864",
"0.48865068",
"0.4878399... | 0.7966203 | 0 |
Sets the image of the server scheduled event. | public ServerScheduledEventBuilder setImage(File image) {
delegate.setImage(image);
return this;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setSleepImage(java.lang.String param) {\n localSleepImageTracker = true;\n\n this.localSleepImage = param;\n }",
"void setImage(String image);",
"public static String getEventImage(String image) {\n return EVENT_IMAGE_URL + image;\n }",
"public final void se... | [
"0.6334431",
"0.58464485",
"0.5727017",
"0.5706747",
"0.5628017",
"0.56129825",
"0.5611955",
"0.558596",
"0.55826133",
"0.55762964",
"0.55762964",
"0.55703515",
"0.5565064",
"0.55447036",
"0.5503241",
"0.5497474",
"0.5495848",
"0.5494485",
"0.5492792",
"0.5488112",
"0.5486598... | 0.76321757 | 0 |
Creates the server scheduled event. | public CompletableFuture<ServerScheduledEvent> create() {
return delegate.create();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"ServerScheduledEvent getServerScheduledEvent();",
"Schedule createSchedule();",
"public ServerScheduledEventBuilder(Server server) {\n delegate = DelegateFactory.createServerScheduledEventBuilderDelegate(server);\n }",
"public ScheduleEvent()\n\t{\n\n\t}",
"public IGenScheduleHandler create() thr... | [
"0.7398586",
"0.64512396",
"0.625238",
"0.62213176",
"0.62122726",
"0.61343336",
"0.60977656",
"0.6026956",
"0.60187185",
"0.6013536",
"0.5987351",
"0.59324956",
"0.59308493",
"0.5883403",
"0.58810663",
"0.5855522",
"0.58299464",
"0.5799067",
"0.5794303",
"0.5794303",
"0.5719... | 0.7023914 | 1 |
Converter from UUID to bd format (String) | @TypeConverter
public String fromUUID(UUID mUUID){
return mUUID.toString();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"UUID primaryFormat();",
"private char[] toDSUID(UUID uuid) {\n ByteBuffer bb = ByteBuffer.wrap(new byte[17]);\n bb.putLong(uuid.getMostSignificantBits());\n bb.putLong(uuid.getLeastSignificantBits());\n\n String s_uuid = DatatypeConverter.printHexBinary(bb.array());\n return s_... | [
"0.7186803",
"0.71059537",
"0.68113095",
"0.6506301",
"0.6445918",
"0.64290416",
"0.64067674",
"0.636946",
"0.6364604",
"0.6340528",
"0.6332257",
"0.6280351",
"0.62541336",
"0.62541336",
"0.62541336",
"0.6204633",
"0.6200487",
"0.61974883",
"0.61974883",
"0.61852074",
"0.6185... | 0.7230664 | 0 |
Converter from bd format (String) to UUID | @TypeConverter
public UUID toUUID(String string){
return UUID.fromString(string);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"UUID primaryFormat();",
"public UUID(String string) {\n FromString(string);\n }",
"public static UUID Parse(String val) {\n return new UUID(val);\n }",
"java.lang.String getUUID();",
"private String convertStringToUuid(String input) {\n String[] uuid = new String[5];\n uui... | [
"0.72868186",
"0.6766781",
"0.67178583",
"0.6683866",
"0.65918416",
"0.6543233",
"0.6512089",
"0.64901876",
"0.64506394",
"0.6198822",
"0.6126502",
"0.61225235",
"0.5999158",
"0.5970723",
"0.59517705",
"0.59512126",
"0.5881866",
"0.5875182",
"0.5868834",
"0.5867264",
"0.58446... | 0.7142816 | 1 |
Converter from Date to bd format (long) | @TypeConverter
public long fromDate(Date mDate){
return mDate.getTime();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@TypeConverter\n public Date toDate(long l){\n return new Date(l);\n }",
"@TypeConverter\n public Long fromDate(Date date) {\n if (date == null) { return null; }\n return date.getTime();\n }",
"public static long toLong( Date date ) {\n return date == null ? 0 : Func... | [
"0.6803012",
"0.65259576",
"0.6399479",
"0.61420715",
"0.61061335",
"0.6103326",
"0.60863197",
"0.5804219",
"0.58005804",
"0.57920945",
"0.575022",
"0.5680458",
"0.56533587",
"0.5630131",
"0.5603093",
"0.55935025",
"0.5557799",
"0.5496605",
"0.5491303",
"0.5482645",
"0.546135... | 0.6813835 | 0 |
Converter from bd format (long) to Date | @TypeConverter
public Date toDate(long l){
return new Date(l);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static Date convertToDate(long value) {\r\n return new Date(value);\r\n }",
"public static String longToDate(Long lo) throws ParseException {\n\n SimpleDateFormat sdf=new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");//这个是你要转成后的时间的格式\n String sd = sdf.format(new Date(lo)); //... | [
"0.6521467",
"0.64388734",
"0.63637304",
"0.62438",
"0.60767204",
"0.59891474",
"0.5987306",
"0.59499747",
"0.5945785",
"0.58986306",
"0.5880299",
"0.5841739",
"0.58207923",
"0.57965964",
"0.5790414",
"0.5755511",
"0.57320005",
"0.56014764",
"0.55604357",
"0.5537453",
"0.5535... | 0.7459064 | 0 |
Use a temporary matrix from the matrix stack instead of creating a temporary float array every frame. | public Matrix3 multiplySelf(Matrix3 m)
{
Matrix3 temp = Matrix3.REUSABLE_STACK.pop().initZero();
for (int r = 0; r < 3; r++)
{
for (int c = 0; c < 3; c++)
{
for (int k = 0; k < 3; k++)
temp.set(c, r, temp.get(c, r) + this.m[k][r] *... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void getMatrix(final float[] pMatrix) {\r\n\t\tif (this.mMatrixStackOffset - GLMatrixStack.GLMATRIX_SIZE <= GLMatrixStack.GLMATRIXSTACKOFFSET_UNDERFLOW) {\r\n\t\t\tthrow new GLMatrixStackUnderflowException();\r\n\t\t}\r\n\r\n\t\tSystem.arraycopy(this.mMatrixStack, this.mMatrixStackOffset, pMatrix, 0, GLMatr... | [
"0.61522603",
"0.59251493",
"0.5854738",
"0.58386946",
"0.574824",
"0.5734714",
"0.57201695",
"0.55805737",
"0.5535797",
"0.5519301",
"0.5440856",
"0.5395481",
"0.5340749",
"0.52727574",
"0.51867884",
"0.51679426",
"0.51642376",
"0.5145565",
"0.50914234",
"0.5079613",
"0.5056... | 0.0 | -1 |
Initializes the controller class. | @Override
public void initialize(URL url, ResourceBundle rb) {
User.setText(UserService.userStatic.getUsername());
if (UserService.userStatic.getRole().equals("ROLE_ADMIN")) {
Role.setText("Administrateur");
menu_bar.getChildren().remove(nav_menu);
menu_bar.getCh... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void initialize() {\n\t\tcontroller = Controller.getInstance();\n\t}",
"public MainController() {\n\t\tcontroller = new Controller(this);\n\t}",
"public abstract void initController();",
"public Controller() {\n super();\n }",
"public Controller() {\n super();\n }",
"public Co... | [
"0.8125658",
"0.78537387",
"0.78320265",
"0.776199",
"0.776199",
"0.76010174",
"0.74497247",
"0.7437837",
"0.7430714",
"0.742303",
"0.74057597",
"0.7341963",
"0.7327749",
"0.72634363",
"0.72230434",
"0.7102504",
"0.70575505",
"0.69873077",
"0.69721675",
"0.6944077",
"0.691256... | 0.0 | -1 |
Saves the current dodle. | public final void saveDodle() {
System.out.println("SaveTool::saveDodle - deprecated. Send `SAVE_DODLE` event instead.");
//toolRegistry.setActiveTool(null);
//stateManager.fireSaveEvent();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void save() {\t\n\t\n\t\n\t}",
"public void save() {\n\t\tthis.setState(Constants.CWorld.STATE_SAVING);\n\t\tthis.getWorld().saveAll();\n\t\tthis.setState(Constants.CWorld.STATE_ONLINE);\n\t}",
"void save();",
"void save();",
"void save();",
"public void save();",
"public void save();",
"publi... | [
"0.7097114",
"0.6849836",
"0.6756286",
"0.6756286",
"0.6756286",
"0.66826713",
"0.66826713",
"0.66826713",
"0.66826713",
"0.6579573",
"0.65381604",
"0.6456513",
"0.6408744",
"0.6406932",
"0.6394157",
"0.6381569",
"0.6373497",
"0.6373497",
"0.63719517",
"0.6360465",
"0.6340853... | 0.69524217 | 1 |
TODO Autogenerated method stub | public static void main(String[] args) {
article.add("the");
article.add("a");
article.add("some");
article.add("one");
noun.add("boy");
noun.add("girl");
noun.add("dog");
noun.add("town");
noun.add("car");
verb.add("drove");
verb.add("ran");
verb.add("jumped");
verb.add("walked");
verb.add(... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExr... | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.608016... | 0.0 | -1 |
/public static final String APIKEY="b256a26b7fa44d26ad21cafeafa198ed"; public static final String URL=" | @Override
protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
// TODO Auto-generated method stub
doPost(req, resp);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface Constants {\n\n public String API_KEY = \"AIzaSyAQLJMre7uZkM_VQMmpfC79rhxhUOEKFOs\";\n\n public String BASE_URL = \"https://maps.googleapis.com/maps/api/\";\n}",
"public static String getApiKey() {\n String sep = \"-\";\n String a = BuildConfig.GUARD_A;\n String b = B... | [
"0.6928818",
"0.68548393",
"0.6834055",
"0.68206483",
"0.6721136",
"0.67104787",
"0.6551124",
"0.64244086",
"0.6337484",
"0.63260823",
"0.6248427",
"0.62478787",
"0.62464035",
"0.6169551",
"0.61042607",
"0.60450333",
"0.60123086",
"0.5991235",
"0.59591013",
"0.59491956",
"0.5... | 0.0 | -1 |
assign the zeroth value as tallest initially | static int birthdayCakeCandles(int n, int[] ar) {
int tallest = ar[0];
int arrLength, count;
arrLength = count = ar.length;
for (int i = 1; i < arrLength; i++) {
if(tallest > ar[i]){
count = count - 1;
} else if(tallest < ar[i]) {
c... | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract int getMinimumValue();",
"static int findMin0(int[] nums) {\r\n \r\n // **** sanity check ****\r\n if (nums.length == 1)\r\n return nums[0];\r\n\r\n // **** check if there is no rotation ****\r\n if (nums[nums.length - 1] > nums[0])\r\n ret... | [
"0.6010346",
"0.59534705",
"0.5902161",
"0.5882563",
"0.5882",
"0.58787173",
"0.5869828",
"0.586697",
"0.5825978",
"0.5787355",
"0.57861835",
"0.57742536",
"0.5767749",
"0.5725945",
"0.5724855",
"0.5691285",
"0.568324",
"0.5671251",
"0.56519645",
"0.5648056",
"0.56460226",
... | 0.0 | -1 |
A listener interface to asynchronously notify progress of a long running operation such as copying from one stream to another. | public static interface ProgressListener {
public void onProgress(float progress);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface ProgressListener {\n\n void progress(long bytesRead, long contentLength, boolean done);\n\n}",
"public interface ProgressListener {\n void update(String url, long bytesRead, long contentLength, boolean done);\n}",
"void onProgress(long bytesTransferred);",
"void execute(DetailedProgres... | [
"0.70289767",
"0.6835199",
"0.6744272",
"0.6561926",
"0.6499157",
"0.649374",
"0.649155",
"0.633239",
"0.6332085",
"0.63208014",
"0.62640065",
"0.62307066",
"0.6216988",
"0.619122",
"0.6075022",
"0.60678834",
"0.60464734",
"0.60406834",
"0.60200906",
"0.60127324",
"0.6011497"... | 0.6046203 | 17 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.