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
Returns a List of String that represents how this item should appear in the ExpiredItemsReport table.
private List<String> asExpiredItemsReportTableRow(Item item) { return Arrays.asList(item.getProduct().getDescription(), item.getStorageUnitName(), item.getProductGroupName(), report.formatForReport(item.getEntryDate()), report.formatForReport(item.getExpirationDate()), item.getBarcode()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public ExpiredItemsReport getExpiredItemsReport() {\r\n\t\treturn expiredItemsReport;\r\n\t}", "public ArrayList<String> returnUrgentItems() {\n ArrayList<String> urgentItemNames = new ArrayList<>();\n\n if (toDoList.getItems().isEmpty()) {\n urgentItemNames.add(\"No More Tasks! Yay!!\")...
[ "0.6594744", "0.61823696", "0.59944427", "0.5817743", "0.57158", "0.56720465", "0.5665921", "0.56500965", "0.56483585", "0.56246513", "0.55628943", "0.55029464", "0.5489531", "0.5488322", "0.548102", "0.5477297", "0.54769623", "0.54535323", "0.5449017", "0.5448599", "0.544838...
0.76366156
0
private final List authorIds; Creates new form UpdateFrame
public UpdateFrame(Database database, String ISBN, Map<String, Author> authors, Map<String, Title> titles, Map<String, List<String>> authorTitleMap, Map<String, List<String>> titleAuthorMap) { try { for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIMana...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void addAuthorList() {\n Intent intent = new Intent();\n ArrayList<Author> authorList = new ArrayList<>(mAuthorMap.values());\n intent.putExtra(EXTRA_AUTHOR_LIST, authorList);\n setResult(RESULT_OK, intent);\n finish();\n }", "public void setAuthors(Author[] authors)...
[ "0.5897169", "0.5801407", "0.5801407", "0.5743056", "0.5715815", "0.5715569", "0.5488742", "0.54775274", "0.542317", "0.540666", "0.53856224", "0.53696114", "0.5338542", "0.53354406", "0.5326555", "0.5315897", "0.5300461", "0.52891254", "0.52891254", "0.52869624", "0.5274634"...
0.4854339
74
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { jPanel1 = new javax.swing.JPanel(); jLabel1 = new javax.swing.JLabel(); jLabel2 = new javax.swing.JLabel(); jLabel3 = new java...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Form() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public frmRectangulo() {\n initComponents();\n }", "public form() {\n ...
[ "0.7319573", "0.72908455", "0.72908455", "0.72908455", "0.7286827", "0.7248724", "0.7213511", "0.7208325", "0.7195998", "0.7190202", "0.7184771", "0.7158966", "0.7147921", "0.7093225", "0.7080275", "0.7057302", "0.69875276", "0.6977057", "0.6955658", "0.6953942", "0.69454855"...
0.0
-1
Method being called when program is executed.
public static void main(String[] args) { ComplexNumber c1 = new ComplexNumber(2, 3); ComplexNumber c2 = ComplexNumber.parse("2.5-3i"); ComplexNumber c3 = c1.add(ComplexNumber.fromMagnitudeAndAngle(2, 1.57)).div(c2).power(3).root(2)[1]; System.out.println(c3); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void intialRun() {\n }", "public void runProgram()\n\t{\n\t\tintro();\n\t\tfindLength();\n\t\tguessLetter();\n\t\tguessName();\n\t}", "@Override\r\n\tpublic void launch() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void launch() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void launch() {\n\t\t\r\n\t}", "...
[ "0.7243522", "0.68535805", "0.67648923", "0.67648923", "0.67648923", "0.67272186", "0.6720475", "0.66982794", "0.6678198", "0.66652673", "0.66652673", "0.66652673", "0.6658603", "0.6622833", "0.6614536", "0.65755594", "0.65366495", "0.65286535", "0.6508316", "0.65081996", "0....
0.0
-1
Creates new form NewJFrame
public NewJFrame() { initComponents(); //combo box comboCompet.addItem("Séléction officielle"); comboCompet.addItem("Un certain regard"); comboCompet.addItem("Cannes Courts métrages"); comboCompet.addItem("Hors compétitions"); comboCompet.addItem...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public NewJFrame() {\n Connect();\n initComponents();\n }", "public NewJFrame() {\n initComponents();\n \n }", "public NewJFrame() {\n initComponents();\n }", "public NewJFrame() {\n initComponents();\n }", "public NewJFrame() {\n initComponents...
[ "0.796484", "0.7945892", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.7931828", "0.79161865", "0.78647804", "0.7763172", "0.76817715", "0.7648401", "0.75705475", "0.7474783", "0.7441117", "0.7441071", "0.7381736", "0.7241864", "0.7152069", ...
0.71234715
21
This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { jInternalFrame1 = new javax.swing.JInternalFrame(); jInternalFrame2 = new javax.swing.JInternalFrame(); jSplitPane1 = new javax.swing....
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Form() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public MainForm() {\n initComponents();\n }", "public frmRectangulo() {\n initComponents();\n }", "public form() {\n ...
[ "0.7319037", "0.7290621", "0.7290621", "0.7290621", "0.7285163", "0.72480375", "0.72130316", "0.7207723", "0.7195822", "0.7189463", "0.7183591", "0.71580946", "0.7147075", "0.70924276", "0.70795405", "0.7056352", "0.6986753", "0.6976759", "0.6954958", "0.69533294", "0.6944831...
0.0
-1
TODO Autogenerated method stub
public static void main(String[] args) { System.out.println("Enetr first linkedlist: "); Node<Integer> list1 = takeInput(); System.out.println("Enter second linkedlist: "); Node<Integer> list2 = takeInput(); list1 = merge2Sorted(list1, list2); printList(list1); }
{ "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.66713095", "0.6567948", "0.652319", "0.648097", "0.64770466", "0.64586824", "0.64132667", "0.6376419", "0.62759", "0.62545097", "0.62371093", "0.62237984", "0.6201738", "0.619477", "0.619477", "0.61924416", "0.61872935", "0.6173417", "0.613289", "0.6127952", "0.6080854", ...
0.0
-1
The archive indexer manages the indexes task queue and performs archives indexing.
public interface ArchiveIndexer { /** * Async indexes all the archives that were marked. * <p>Does not guarantee actual indexing, it is the responsibility of {@link ArchiveIndexer} to decide on indexing * or even stop indexing in the middle. */ @Async(delayUntilAfterCommit = true) void ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected File createIndexingArchive(String format, String jobId, JSONObject jobObject, String indexType, String query) throws IOException {\n\t\tFile archive = File.createTempFile(jobId, \".zip.tmp\");\n\t\tFileOutputStream fos = null;\n\t\tZipOutputStream zos = null;\n\n\t\t// try to add to the archive\n\t\ttry ...
[ "0.6303627", "0.6107907", "0.56967336", "0.5647633", "0.5575114", "0.55067134", "0.5362945", "0.5349123", "0.53143936", "0.52806425", "0.5279508", "0.5263958", "0.52527434", "0.52450144", "0.5235446", "0.52199", "0.5199082", "0.51973003", "0.5146097", "0.5132816", "0.5130165"...
0.68807936
0
Adds the given repo path to the archive indexing queue.
@Lock void markArchiveForIndexing(RepoPath searchPath);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void addToQueue(String path) {\n ArrayList<String> temp = Global.uploadMetaData;\n\n boolean inQueue = checkInQueue(path, temp);\n\n if (!inQueue) {\n temp.add(path);\n }\n\n Global.uploadMetaData = temp;\n }", "public interface ArchiveIndexer {\n\n /**\...
[ "0.6363809", "0.631094", "0.59239227", "0.55307996", "0.5510872", "0.5269802", "0.52275085", "0.5185909", "0.51280874", "0.512546", "0.5094258", "0.49931458", "0.489093", "0.48901471", "0.48872393", "0.4840998", "0.48316616", "0.48189193", "0.48139134", "0.47880223", "0.47767...
0.686771
0
metodo que abre el seleccionador de archivos
public static ArrayList<String[]> open() { int r = file.showOpenDialog(null); ArrayList<String> data = new ArrayList<>(); String line = ""; ArrayList<String[]> datosF = new ArrayList<String[]>(); if (r == JFileChooser.APPROVE_OPTION) { arch = file.getSelectedF...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void seleccionarArchivo(){\n JFileChooser j= new JFileChooser();\r\n FileNameExtensionFilter fi= new FileNameExtensionFilter(\"pdf\",\"pdf\");\r\n j.setFileFilter(fi);\r\n int se = j.showOpenDialog(this);\r\n if(se==0){\r\n this.txtCurriculum.setText(\"\"+j.getS...
[ "0.76664567", "0.6878355", "0.6839025", "0.66826606", "0.6666317", "0.66111094", "0.6530392", "0.64566004", "0.640832", "0.63534665", "0.6334532", "0.60977525", "0.6095437", "0.60662884", "0.6048442", "0.60072786", "0.60051084", "0.6003482", "0.59996563", "0.5983712", "0.5961...
0.0
-1
metodo que verifica si lo ingresado es un numero
public static int verif(String cadena) { Scanner l = new Scanner(System.in); int m1 = -1; do { try { System.out.println(cadena); m1 = l.nextInt(); } catch (InputMismatchException e) { System.out.println("Valor no val...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean verificaNumero() {\n if (contemSomenteNumeros(jTextFieldDeposita.getText()) || contemSomenteNumeros(jTextFieldSaca.getText())\n || contemSomenteNumeros(jTextFieldTransfere.getText())) {\n return true;\n } else {\n JOptionPane.showMessageDialog(this,...
[ "0.7505959", "0.7363107", "0.7360615", "0.72953266", "0.71202976", "0.7117274", "0.71139586", "0.70554703", "0.70554703", "0.70554703", "0.6876943", "0.6833293", "0.6775988", "0.67684174", "0.67540413", "0.66565543", "0.6645541", "0.661189", "0.6607231", "0.6583045", "0.65384...
0.0
-1
Constructs a FindCommand that handles command of finding a task by searching for a keyword.
public FindCommand(String keyword) throws EmptyDescriptionException { ExceptionChecker.checkEmptyDescription("find", keyword); this.keyword = keyword; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public FindCommand(String keyword) {\n this.keyword = keyword;\n }", "public FindCommand(String keyword) {\n super();\n this.keyword = keyword;\n }", "public FindCommand(WordContainsKeywordsPredicate predicate) {\n this.predicate = predicate;\n }", "public FindCommand(Str...
[ "0.7794826", "0.7762499", "0.6926939", "0.6782853", "0.6595118", "0.6281986", "0.5965048", "0.5812202", "0.5725757", "0.568773", "0.56508124", "0.5592022", "0.54965067", "0.5486122", "0.53817314", "0.5340184", "0.5320406", "0.5286269", "0.52064615", "0.51522857", "0.50868726"...
0.74649644
2
Appends matched result to response.
private void appendMatched(StringBuilder response, String task, int index) { String matchedResult = String.format(" %d.%s\n", index, task); if (task.contains(keyword)) { response.append(matchedResult); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void addResponseToResult(String term){\n\t\tResult result = this.getResult();\n\t\tif(result==null){\n\t\t\tresult = new Result();\n\t\t\tresult.setResponse(term);\n\t\t\tthis.setResult(result);\n\t\t}\n\t\telse{\n\t\t\tString s = result.getResponse();\n\t\t\ts += \",\" + term;\n\t\t\tresult.setResponse(s);...
[ "0.63138884", "0.6199104", "0.59785587", "0.58750814", "0.5840814", "0.58376575", "0.5663542", "0.55986744", "0.5525046", "0.54766804", "0.543184", "0.5368601", "0.5326524", "0.52850354", "0.52756405", "0.5257975", "0.52571046", "0.5241939", "0.5237291", "0.5225404", "0.52110...
0.6747066
0
Returns the response after finding a task by searching for a keyword.
@Override public String execute(TaskList tasks, Ui ui, Storage storage) { StringBuilder response = new StringBuilder("Oh? You're approaching me?\n" + "Here are the matching tasks in your list:\n"); int index = 1; for (Task task : tasks.getTasks()) { String taskStr...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void findTask(String keyword) {\n int index = 1;\n for (Task task : taskList) {\n if (task.toString().contains(keyword)) {\n if (isNoTaskYetFound(index)) {\n System.out.println(\"Here are the matching tasks in your list:\");\n }\n\n ...
[ "0.69509", "0.6678856", "0.66211444", "0.63281786", "0.6183019", "0.61657655", "0.61321473", "0.6045603", "0.6034242", "0.5995378", "0.5870099", "0.5858116", "0.5826248", "0.5768328", "0.57478565", "0.57367444", "0.57013345", "0.56677365", "0.5625176", "0.559076", "0.55113566...
0.0
-1
Returns the boolean false since it is not a command that exits the program.
@Override public boolean isExit() { return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private Boolean quitCommand() {\n output.println(\"QUIT COMMAND\");\n return false;\n }", "boolean hasExitStatus();", "public boolean isExit() {\n return false;\n }", "@Override\n public boolean isExit() {\n return true;\n }", "public abstract boolean isExit();", "public...
[ "0.7491973", "0.7464659", "0.73367774", "0.7111384", "0.703174", "0.70214415", "0.6906493", "0.6877848", "0.6828523", "0.6787101", "0.6787101", "0.6787101", "0.67842823", "0.67622787", "0.67435783", "0.6727922", "0.6722395", "0.6623472", "0.66186917", "0.6615549", "0.6586232"...
0.71709377
7
return getSkill(15648, 1); //tank
protected Skill getNpcSuperiorBuff() { return getSkill(15649, 1); //warrior // return getSkill(15650, 1); //wizzard }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getFishingSkill();", "Skill getSkill(String name);", "public Skills getChosenSkill();", "public abstract SkillData skill();", "public Skills chooseSkill();", "String getSkills();", "int getSkillId();", "public Skills getSkillPrediction();", "int getIndividualAttack();", "String getSkil...
[ "0.75478244", "0.75434244", "0.7443185", "0.7247855", "0.7205357", "0.71797436", "0.699831", "0.69461954", "0.67777", "0.6715842", "0.6699433", "0.6633383", "0.654483", "0.6481332", "0.6464162", "0.6370301", "0.6342065", "0.63406694", "0.6323099", "0.6289658", "0.6274003", ...
0.66405934
11
Create a variables to pass to the graphql query
private static String createGraphqlAddTemplate(InputStream iStream, String issuerSector) throws IOException { ObjectNode variables = new ObjectMapper().createObjectNode(); // add a nested node object to our current node ObjectNode input = variables.putObject("issuerSector"); input.put(ISSUER_SECTOR_FIELD,i...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Variables createVariables();", "Graph callConstructQuery(String name, Map<String, String> params);", "@SuppressWarnings(\"boxing\")\n @Override\n protected String getCustomQueryStringVariables() {\n String unitsParam = \"\";\n if (radiusUnitOverride != null) {\n unitsParam = String.format(\"&spati...
[ "0.5589245", "0.5221484", "0.51750743", "0.51471496", "0.49801415", "0.49094486", "0.4859731", "0.48244798", "0.47849464", "0.47299847", "0.4699051", "0.46856698", "0.46341246", "0.4626571", "0.46044132", "0.45945606", "0.45860744", "0.45860735", "0.45518553", "0.45396602", "...
0.47764426
9
get fragment content view
protected abstract int getContentView();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract int getFragmentView();", "@Override\r\n\tpublic View getContentView() {\n\t\treturn contentView;\r\n\t}", "public abstract Fragment getFragment();", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) ...
[ "0.7587255", "0.69661033", "0.68915564", "0.65917087", "0.65917087", "0.65858084", "0.65115356", "0.6509243", "0.6458942", "0.64200944", "0.6363448", "0.6361907", "0.6336133", "0.62938976", "0.62902117", "0.628575", "0.6269912", "0.6261035", "0.6259743", "0.62463224", "0.6245...
0.6100919
60
inject you need fragment
protected abstract void injectFragment(FragmentComponent fragmentComponent);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void inject(SubscriberDetailsFragment fragment);", "void inject(MoviesListFragment moviesListFragment);", "private void initFragmentAutoInjection() {\n BucketApplication app;\n app = (BucketApplication) getApplication();\n\n getSupportFragmentManager().registerFragmentLifecycleCallbacks(ne...
[ "0.73440474", "0.72345996", "0.717971", "0.7152742", "0.7089114", "0.6848232", "0.6846245", "0.6680025", "0.66772157", "0.6660864", "0.6632376", "0.66128904", "0.66076595", "0.6601506", "0.6582406", "0.65633094", "0.65420496", "0.6507362", "0.6506472", "0.64961934", "0.647032...
0.74417984
0
init view or config
protected abstract void init();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected abstract void initView();", "protected abstract void initViews();", "public abstract void initViews();", "public abstract void initView();", "void initView();", "private void initViews() {\n\n\t}", "public void initView(){}", "private void initView() {\n\n }", "private void initViews(...
[ "0.7564971", "0.7463099", "0.7436261", "0.74270827", "0.7362355", "0.7358974", "0.7357497", "0.7350582", "0.7256072", "0.72189677", "0.71929675", "0.71793646", "0.71793646", "0.71506083", "0.7142233", "0.71063644", "0.7077541", "0.7077541", "0.70598924", "0.7032228", "0.70322...
0.0
-1
TODO code application logic here
public static void main(String[] args) { System.out.println("Escribe los tres números:"); Scanner sc = new Scanner(System.in); Numero numeros = new Numero(sc.nextFloat(),sc.nextFloat(),sc.nextFloat()); numeros.calcularMaior(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\n public void settings() {\n // TODO Auto-generated method stub\n \n }"...
[ "0.6082568", "0.5913159", "0.5844445", "0.58351505", "0.581159", "0.575886", "0.5741742", "0.5722983", "0.57077605", "0.5667302", "0.5660212", "0.56133604", "0.561261", "0.561261", "0.5596802", "0.5594944", "0.557857", "0.5573299", "0.5567435", "0.55486387", "0.5536881", "0...
0.0
-1
Created by PauLinHo on 17/01/2018.
public interface IStrategy<T extends Object> { static final String BITCOIN_BASE64 = "1NwaKCqfb532vVRFmBAixPbGQJhTfwpbzk"; static final String BITCOIN = "BITCOIN"; SimpleDateFormat SDF_DDMMYYYY_HHMMSS = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss"); SimpleDateFormat SDF_DDMMYYYY = new SimpleDateFormat("yy...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "public final void mo51373a() {\n }", "@Override\n public void func_104112_b() {\n \n }", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tprotected void get...
[ "0.5858172", "0.5730281", "0.5687612", "0.55761266", "0.55761266", "0.5560818", "0.55303097", "0.5507796", "0.55039537", "0.54594743", "0.545888", "0.54580426", "0.54568607", "0.5411961", "0.54103965", "0.53979385", "0.5394361", "0.537928", "0.5363684", "0.5326079", "0.532479...
0.0
-1
Default constructor for a floor.
public Floor(){ populateRooms(); level = new Room[5][5]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setFloor(int floor) {\n this.floor = floor;\n }", "FloorType createFloorType();", "public Floor(int floorNum)\n { System.out.print(\"Initializing Floor #\" + floorNum + \"...\\n\");\n this.floorNum= floorNum;\n this.occupants=0;\n }", "public FloorCrate(int x, int ...
[ "0.71335346", "0.7086641", "0.707227", "0.6874935", "0.6809516", "0.6751117", "0.64884907", "0.63746965", "0.63397765", "0.63264567", "0.62125105", "0.616386", "0.6146007", "0.6031966", "0.60018295", "0.59997207", "0.5989642", "0.5982826", "0.5980521", "0.59420115", "0.591922...
0.0
-1
Add enemies and items to the room.
public void populateRooms(){ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void addEnemies() {\n\t\tred_ghost = new Enemy();\r\n\t\tthis.add(red_ghost);\r\n\t\tenemies.add(red_ghost);\r\n\t\t\r\n\t}", "public void addEnemy(Enemy enem)\r\n\t{\r\n\t\tenemy.add(new Enemy(enem));\r\n\t}", "private void createBasicEnemies() {\n\t\tint xTemp1 = (int) app.random(60, 500);\n\t\tint x...
[ "0.6846196", "0.6526793", "0.64577425", "0.6430821", "0.63240814", "0.62344927", "0.61263585", "0.61153173", "0.60885215", "0.6023442", "0.6020053", "0.5936113", "0.5934017", "0.5901221", "0.58774084", "0.5875265", "0.58741885", "0.5841452", "0.5785145", "0.5775002", "0.57590...
0.0
-1
Advance to the next floor.
public void advanceFloor(){ //TODO: write method to move onto next floor }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void next(Lift lift) {\n if (lift.getCurrentFloor() <= 0) {\n lift.setCurrentFloor(lift.getCurrentFloor() + 1);\n lift.setDirection(Direction.UP);\n lift.setState(new OutLiftState(maxFloor, waitingPassenger));\n } else {\n lift.setCurr...
[ "0.6925196", "0.6361184", "0.6284372", "0.62702626", "0.62657684", "0.6172717", "0.6126429", "0.60786724", "0.6070096", "0.60687906", "0.58729464", "0.58535886", "0.5790342", "0.5743982", "0.571761", "0.5668346", "0.5646937", "0.56055665", "0.5590394", "0.5570479", "0.5568046...
0.856825
0
Constructs a new object.
public ApplicationStub() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "OBJECT createOBJECT();", "public ObjectFactory() {\n super(grammarInfo);\n }", "public CMObject newInstance();", "Reproducible newInstance();", "protected abstract void construct();", "public ObjectFactory() {\n\t}", "public ObjectFactory() {\r\n\t}", "private Instantiation(){}", "public ...
[ "0.7231841", "0.71967894", "0.7196264", "0.7141073", "0.70838195", "0.70537", "0.7016537", "0.6961097", "0.69576335", "0.69576335", "0.69576335", "0.69212204", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.6...
0.0
-1
Constructs a new object.
public ApplicationStub(final String id) { sessionID = id; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "OBJECT createOBJECT();", "public ObjectFactory() {\n super(grammarInfo);\n }", "public CMObject newInstance();", "Reproducible newInstance();", "protected abstract void construct();", "public ObjectFactory() {\n\t}", "public ObjectFactory() {\r\n\t}", "private Instantiation(){}", "public ...
[ "0.7232399", "0.71966016", "0.7195631", "0.71399856", "0.7084115", "0.705351", "0.70162374", "0.69599724", "0.6957191", "0.6957191", "0.6957191", "0.6921259", "0.68274945", "0.68274945", "0.68274945", "0.68274945", "0.68274945", "0.68274945", "0.68274945", "0.68274945", "0.68...
0.0
-1
Constructs a new object.
public ApplicationStub(final Context context) { super(context); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "OBJECT createOBJECT();", "public ObjectFactory() {\n super(grammarInfo);\n }", "public CMObject newInstance();", "Reproducible newInstance();", "protected abstract void construct();", "public ObjectFactory() {\n\t}", "public ObjectFactory() {\r\n\t}", "private Instantiation(){}", "public ...
[ "0.7231841", "0.71967894", "0.7196264", "0.7141073", "0.70838195", "0.70537", "0.7016537", "0.6961097", "0.69576335", "0.69576335", "0.69576335", "0.69212204", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.68277836", "0.6...
0.0
-1
write your code here
public static void main(String[] args) throws NoSuchAlgorithmException { String text = "Hello World"; System.out.println("Исходный текст : " + text); MessageDigest sha1 = MessageDigest.getInstance("MD5"); byte[] bytes = sha1.digest(text.getBytes()); StringBuilder stringBuilder =...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void logic(){\r\n\r\n\t}", "public static void generateCode()\n {\n \n }", "@Override\n\tprotected void logic() {\n\n\t}", "private static void cajas() {\n\t\t\n\t}", "void pramitiTechTutorials() {\n\t\n}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\r\n\tpub...
[ "0.61019534", "0.6054925", "0.58806974", "0.58270746", "0.5796887", "0.56999695", "0.5690986", "0.56556827", "0.5648637", "0.5640487", "0.56354505", "0.56032085", "0.56016207", "0.56006724", "0.5589654", "0.5583692", "0.55785793", "0.55733466", "0.5560209", "0.55325305", "0.5...
0.0
-1
Create a new BrowserBookmarksAdapter.
public BrowserBookmarksAdapter(BrowserBookmarksPage b, String curPage, String curTitle, Bitmap curThumbnail, boolean createShortcut, boolean mostVisited) { mNeedsOffset = !(createShortcut || mostVisited); mMostVisited = mostVisited; mExtraOffset = mNeedsOffset ? 1 : 0; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private BookmarkStore() {\n }", "private JMenu getMnuBookmarks() {\r\n\t\tif (mnuBookmarks == null) {\r\n\t\t\tmnuBookmarks = new JMenu();\r\n\t\t\tmnuBookmarks.setText(\"Bookmarks\");\r\n\t\t\tmnuBookmarks.add(getMniAddBookmark());\r\n\t\t\tmnuBookmarks.add(getSepBookmark1());\r\n\t\t}\r\n\t\treturn mnuBookm...
[ "0.5805813", "0.55703634", "0.5490129", "0.54251814", "0.5249629", "0.5227281", "0.5211594", "0.51920485", "0.5094895", "0.50383615", "0.5014062", "0.5005061", "0.49929833", "0.49877682", "0.49490926", "0.48994732", "0.48933417", "0.48814115", "0.4857349", "0.48498482", "0.48...
0.6301139
0
Return a hashmap with one row's Title, Url, and favicon.
public Bundle getRow(int position) { Bundle map = new Bundle(); if (position < mExtraOffset || position >= mCount) { return map; } mCursor.moveToPosition(position- mExtraOffset); String url = mCursor.getString(Browser.HISTORY_PROJECTION_URL_INDEX); map.putStri...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public HashMap getMetaData() ;", "@Override\n public Map<String, String> get() {\n\n Map<String, String> hugoMap = Maps.newHashMap();\n try {\n final CSVParser parser = new CSVParser(this.reader, CSVFormat.TDF.withHeader());\n for (CSVRecord record : parser) {\n\n hugoMap.put(...
[ "0.6245056", "0.57167", "0.56097895", "0.5563274", "0.54082274", "0.5369132", "0.5367373", "0.53364", "0.5325811", "0.5325811", "0.53045005", "0.5298679", "0.5284141", "0.52805185", "0.525112", "0.5249199", "0.52474385", "0.5242562", "0.5207399", "0.5198571", "0.51868576", ...
0.5512763
4
Update a row in the database with new information. Requeries the database if the information has changed.
public void updateRow(Bundle map) { // Find the record int id = map.getInt("id"); int position = -1; for (mCursor.moveToFirst(); !mCursor.isAfterLast(); mCursor.moveToNext()) { if (mCursor.getInt(Browser.HISTORY_PROJECTION_ID_INDEX) == id) { position = mCurso...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void updateRow() throws SQLException\n {\n m_rs.updateRow();\n }", "public void update() {\n\t\tSession session = DBManager.getSession();\n\t\tsession.beginTransaction();\n\t\tsession.update(this);\n\t\tsession.getTransaction().commit();\n\t}", "public void updateRow() throws SQLException {\n\n...
[ "0.76243484", "0.71735966", "0.7132843", "0.71302325", "0.68364096", "0.6729438", "0.6668245", "0.6630495", "0.6625206", "0.6602377", "0.65931606", "0.65865046", "0.65862584", "0.65796256", "0.65690875", "0.6562705", "0.6467423", "0.6454007", "0.6449404", "0.64362", "0.643350...
0.0
-1
Delete a row from the database. Requeries the database. Does nothing if the provided position is out of range.
public void deleteRow(int position) { if (position < mExtraOffset || position >= getCount()) { return; } mCursor.moveToPosition(position- mExtraOffset); String url = mCursor.getString(Browser.HISTORY_PROJECTION_URL_INDEX); String title = mCursor.getString(Browser.HIST...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic int deleteOne(int idx) throws SQLException {\n\t\treturn 0;\r\n\t}", "public void removeRow(int ind) throws SQLException {\n/* 417 */ notSupported();\n/* */ }", "public DResult delete(byte[] row, long startId) throws IOException;", "private void deleteItem(int position){\n ...
[ "0.6847546", "0.6774978", "0.67226374", "0.6661464", "0.66263455", "0.6525299", "0.650678", "0.642685", "0.6387509", "0.6370888", "0.6368474", "0.63339484", "0.6328056", "0.62111205", "0.6206831", "0.6195558", "0.61873347", "0.61863995", "0.615474", "0.6120856", "0.6103511", ...
0.66970015
3
Delete all bookmarks from the db. Requeries the database. All bookmarks with become visited URLs or if never visited are removed
public void deleteAllRows() { StringBuilder deleteIds = null; StringBuilder convertIds = null; for (mCursor.moveToFirst(); !mCursor.isAfterLast(); mCursor.moveToNext()) { String url = mCursor.getString(Browser.HISTORY_PROJECTION_URL_INDEX); WebIconDatabase.getIns...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@NonNull\n Completable deleteAllBookmarks();", "@Transactional\n\t@Override\n\tpublic void deleteAll() {\n\t\tanchorKeywordsDAO.deleteAll();\n\t}", "@Override\n\tpublic void deleteAll() {\n\t\tdao.deleteAll();\n\n\t}", "public void deleteAll()\r\n\t{\r\n\t\ttry\r\n\t\t{\r\n\t\t\tbookdao.openCurrentSession...
[ "0.6770624", "0.6663627", "0.64626986", "0.64561194", "0.6337642", "0.6331788", "0.6331788", "0.6331788", "0.6274906", "0.62567145", "0.62567145", "0.62567145", "0.62567145", "0.62512726", "0.6237894", "0.6156626", "0.6114424", "0.6114424", "0.6114424", "0.61100364", "0.61100...
0.7438835
0
Refresh list to recognize a change in the database.
public void refreshList() { mCursor.requery(); mCount = mCursor.getCount() + mExtraOffset; notifyDataSetChanged(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void refreshList() {\n }", "public void reload(){\n populateList();\n }", "private void refreshList() {\n if (loadStepsTask != null) {\n loadStepsTask.cancel(false);\n }\n loadStepsTask = new LoadStepsTask(this, dbManager);\n loadStepsTa...
[ "0.7798432", "0.77070326", "0.73630536", "0.72651756", "0.7222413", "0.71428436", "0.6986079", "0.69658893", "0.6898079", "0.6855831", "0.6802371", "0.6774958", "0.6760501", "0.67529947", "0.6743131", "0.6731542", "0.66961676", "0.66606766", "0.66427755", "0.66370916", "0.663...
0.7213283
5
Update the bookmark's favicon. This is a convenience method for updating a bookmark favicon for the originalUrl and url of the passed in WebView.
static void updateBookmarkFavicon(ContentResolver cr, String originalUrl, String url, Bitmap favicon) { final Cursor c = queryBookmarksForUrl(cr, originalUrl, url, true); if (c == null) { return; } boolean succeed = c.moveToFirst(); ContentValues values = ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@JsonProperty(\"favicon_url\")\n public void setFaviconUrl(String faviconUrl) {\n this.faviconUrl = faviconUrl;\n }", "com.google.protobuf.ByteString getFavicon();", "@Override\n public void onPageStarted (WebView view, String url, Bitmap favicon)\n {\n }", "@Override\n ...
[ "0.5856515", "0.5565576", "0.5525429", "0.55089444", "0.5499581", "0.54863876", "0.5458956", "0.5458956", "0.5458956", "0.5458956", "0.5458956", "0.5458956", "0.54499406", "0.5447315", "0.544188", "0.5417084", "0.5413023", "0.54012764", "0.5344473", "0.5335785", "0.52822924",...
0.7926136
0
Strip the query from the given url.
private static String removeQuery(String url) { if (url == null) { return null; } int query = url.indexOf('?'); String noQuery = url; if (query != -1) { noQuery = url.substring(0, query); } return noQuery; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static String removeQuery(final String urlString) {\n if (urlString == null) {\n return null;\n }\n return Uri.parse(urlString).buildUpon().clearQuery().toString();\n }", "public String cleanURL(String url) {\n\t\treturn this.removeQueryString(this.removeExtension(url));...
[ "0.6988166", "0.6688287", "0.6551162", "0.65293175", "0.6413922", "0.6365457", "0.59189874", "0.59188354", "0.56759256", "0.56518066", "0.5646121", "0.5581205", "0.5572583", "0.5475397", "0.5472413", "0.54703087", "0.54170305", "0.5416015", "0.54091024", "0.53448254", "0.5332...
0.7982644
0
How many items should be displayed in the list.
public int getCount() { if (mDataValid) { return mCount; } else { return 0; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "int getItemsCount();", "int getItemsCount();", "int getNumItems();", "public int numberOfItems()\n {\n return dessertList.size();\n }", "public int getNumberOfItems() {\r\n return decorItems.size();\r\n }", "public int getSize() {\r\n return list.getItemCount();\r\n }", "pu...
[ "0.7663259", "0.7663259", "0.76521885", "0.74543697", "0.74388707", "0.74245185", "0.73998165", "0.73822916", "0.73798656", "0.7368569", "0.72622865", "0.72561044", "0.72401893", "0.7224705", "0.72216207", "0.72216207", "0.72156423", "0.71754444", "0.71562517", "0.71213704", ...
0.0
-1
Get the data associated with the specified position in the list.
public Object getItem(int position) { return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\t\tpublic Object getItem(int position) {\n\t\t\treturn listData.get(position);\r\n\t\t}", "@Override\n\t\tpublic Object getItem(int position) {\n\t\t\treturn mlistData.get(position);\n\t\t}", "@Override\n public Object getItem(int position) {\n return listData.get(position);\n }", ...
[ "0.72820246", "0.72739184", "0.7202337", "0.7182795", "0.7128945", "0.7125719", "0.7092692", "0.7071994", "0.7030282", "0.7030282", "0.7018749", "0.69829845", "0.6965652", "0.6953013", "0.6949147", "0.6921494", "0.6912498", "0.6909801", "0.69017", "0.69017", "0.69017", "0.6...
0.0
-1
Get the row id associated with the specified position in the list.
public long getItemId(int position) { return position; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getIdForRow(int row);", "public static int getRowIdFromDb() {\n // get DB helper\n mDbHelper = PointOfSaleDb.getInstance(context);\n\n // Each row in the list stores amount and date of transaction -- retrieves history from DB\n SQLiteDatabase db = mDbHelper.getReadableDa...
[ "0.69481605", "0.66123194", "0.6571436", "0.65488386", "0.6542914", "0.65157574", "0.65059495", "0.65059495", "0.6489457", "0.64832616", "0.64832616", "0.64832616", "0.64832616", "0.64832616", "0.64832616", "0.64832616", "0.64832616", "0.6473032", "0.6470207", "0.6464281", "0...
0.63549745
82
Get a View that displays the data at the specified position in the list.
public View getView(int position, View convertView, ViewGroup parent) { if (!mDataValid) { throw new IllegalStateException( "this should only be called when the cursor is valid"); } if (position < 0 || position > mCount) { throw new AssertionError( ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public View getView(int position, View convertView, ViewGroup parent) {\n Item item = getItem(position);\n // Check if an existing view is being reused, otherwise inflate the view\n if (convertView == null) {\n convertView = LayoutInflater.from(getContext()).inflate(R...
[ "0.6413296", "0.6286941", "0.62562656", "0.6229439", "0.6220235", "0.6162428", "0.6160567", "0.6145458", "0.6137479", "0.6132373", "0.61263216", "0.61153036", "0.6079484", "0.607682", "0.6075601", "0.6068753", "0.6068753", "0.6064249", "0.60605216", "0.60357505", "0.6032543",...
0.6203187
5
Return the title for this item in the list.
public String getTitle(int position) { return getString(Browser.HISTORY_PROJECTION_TITLE_INDEX, position); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getItemTitle() {\n\t return this.itemTitle;\n\t}", "public String getTitle() {\n return titleName;\n }", "public java.lang.Object getTitle() {\n return title;\n }", "public java.lang.String getTitle() {\n return title;\n }", "public java.lang.String getTitle() {...
[ "0.8138567", "0.75739336", "0.7549567", "0.75477636", "0.753402", "0.75334567", "0.75283736", "0.75283736", "0.75283736", "0.7504783", "0.7504783", "0.7504783", "0.7504783", "0.7504783", "0.7504783", "0.7504783", "0.7474082", "0.7469672", "0.7469672", "0.7469672", "0.74687755...
0.0
-1
Return the Url for this item in the list.
public String getUrl(int position) { return getString(Browser.HISTORY_PROJECTION_URL_INDEX, position); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Schema(description = \"Link to get this item\")\n public String getUrl() {\n return url;\n }", "public String getURL(int position){\n Item current = getItem(position);\n return current.URL();\n }", "@java.lang.Override\n public java.lang.String getUrl() {\n return instance.ge...
[ "0.72664714", "0.72027", "0.6838746", "0.6838746", "0.6813099", "0.67827374", "0.6578248", "0.65592635", "0.6553667", "0.650457", "0.65002346", "0.6494931", "0.64946556", "0.649146", "0.6465298", "0.64582413", "0.6451141", "0.64328986", "0.64328986", "0.6414491", "0.6414491",...
0.0
-1
Return the favicon for this item in the list.
public Bitmap getFavicon(int position) { return getBitmap(Browser.HISTORY_PROJECTION_FAVICON_INDEX, position); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "com.google.protobuf.ByteString getFavicon();", "@JsonProperty(\"favicon_url\")\n public String getFaviconUrl() {\n return faviconUrl;\n }", "@ZAttr(id=800)\n public String getSkinFavicon() {\n return getAttr(Provisioning.A_zimbraSkinFavicon, null);\n }", "public URI getIconUri() {\n...
[ "0.66692096", "0.6618526", "0.6323338", "0.6185059", "0.6034272", "0.5947659", "0.59458613", "0.5846148", "0.5813889", "0.5812242", "0.5809749", "0.579239", "0.578549", "0.578549", "0.578549", "0.578549", "0.5774118", "0.570012", "0.5699338", "0.56739724", "0.5646321", "0.5...
0.62481284
3
Return whether or not this item represents a bookmarked site.
public boolean getIsBookmark(int position) { if (position < mExtraOffset || position > mCount) { return false; } mCursor.moveToPosition(position - mExtraOffset); return (1 == mCursor.getInt(Browser.HISTORY_PROJECTION_BOOKMARK_INDEX)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean isSite() {\n return site;\n }", "boolean isSetBodySite();", "public boolean isSiteOnly()\n\t\t{\n\t\t\tboolean isSiteOnly = false;\n\t\t\tisSiteOnly = !isGroupPossible() && !isPubviewPossible();\n\t\t\treturn isSiteOnly;\n\t\t}", "public boolean hasSite() {\n return fieldSetFlag...
[ "0.64148605", "0.62671226", "0.6230242", "0.6157166", "0.6025338", "0.5882011", "0.5871463", "0.563737", "0.5588414", "0.5586472", "0.556911", "0.55513424", "0.55505866", "0.5546784", "0.5535611", "0.5508223", "0.55007553", "0.5497897", "0.548902", "0.5480961", "0.54753464", ...
0.5528343
15
Private helper function to return the title or url.
private String getString(int cursorIndex, int position) { if (position < mExtraOffset || position > mCount) { return ""; } mCursor.moveToPosition(position- mExtraOffset); return mCursor.getString(cursorIndex); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "java.lang.String getTitle();", "java.lang.String getTitle();", "java.lang.String getTitle();", "java.lang.String getTitle();", "java.lang.String getTitle();", "String getTitle();", "String getTitle();", "String getTitle();", "String getTitle();", "String getTitle();", "String getTitle();", "S...
[ "0.7411172", "0.7411172", "0.7411172", "0.7411172", "0.7411172", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "0.70400697", "...
0.0
-1
set (no duplicati) ordinato (Comparable)
public static void main(String[] args) { ProvaCollezioni pc = new ProvaCollezioni(); pc.spesa.add("latte"); pc.spesa.add("pane"); pc.spesa.add("biscotti"); pc.spesa.add("olio"); pc.spesa.add("biscotti"); System.out.println(pc.spesa.size()); for (String voce : pc.spesa) { pc.spesaFiltrata...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Object insert(Comparable o);", "@Override\n\tpublic int compareTo(Objeto o) {\n\t\treturn 0;\n\t}", "@Override\r\n\tpublic int compareTo(Object o) {\n\t\treturn 0;\r\n\t}", "@Override\r\n\t\tpublic int compareTo(Object o) {\n\t\t\treturn 0;\r\n\t\t}", "@Override\n\tpublic int compareTo(Object o) {\n...
[ "0.64475906", "0.6358678", "0.6274193", "0.6238324", "0.62372357", "0.62213457", "0.62213457", "0.62213457", "0.6203354", "0.6203354", "0.6203354", "0.6203354", "0.6203354", "0.6203354", "0.6203354", "0.6203354", "0.61934656", "0.61476374", "0.60651267", "0.60493404", "0.6047...
0.0
-1
check if the player can move to new cell
private void tryMovePlayer(int direction) { int layerOffset = 0, rowOffset = 0, colOffset = 0; boolean canMove = false; Maze3D.Cell currentCell = maze3D[playerLayer][playerRow][playerCol]; Maze3D.Cell nextCell = null; try { switch (direction) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n void checkCannotForceWithForcedCellOccupied() {\n assertFalse(abilities.checkCanMove(turn, board.getCellFromCoords(1, 0)));\n }", "private static boolean canMove() {\n return GameManager.getCurrentTurn();\r\n }", "boolean canMove (int newRow, int newColumn) {\n return canM...
[ "0.72045094", "0.71344805", "0.7124317", "0.70607144", "0.69600207", "0.6948297", "0.6934185", "0.6887584", "0.6880736", "0.68551975", "0.6816106", "0.6813313", "0.67950433", "0.6762874", "0.67621386", "0.673858", "0.67285883", "0.6717482", "0.67056924", "0.668696", "0.668572...
0.6756651
15
Given an array of integers, find the highest product you can get from three of the integers.
public int getHighestProduct(int[] array) { if (array.length < 3) { throw new IllegalArgumentException("Need at least 3 numbers in the array"); } int lowest = Math.min(array[0], array[1]); int highest = Math.max(array[0], array[1]); int highestProdOfTwo = array[0]*array[1]; int lowestProdOfTwo = array[0...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static int highestProductOf3(int[] arr) {\n int a = max(arr[0], max(arr[1], arr[2]));\n int c = min(arr[0], min(arr[1], arr[2]));\n int b = arr[0] + arr[1] + arr[2] - a - c;\n\n int x = c;\n int y = b;\n\n for(int i = 3; i < arr.length; i++) {\n if(arr[i]...
[ "0.83103323", "0.7622613", "0.7546119", "0.7510364", "0.7418841", "0.7367409", "0.7318665", "0.72994375", "0.71788555", "0.7130869", "0.7118748", "0.71145344", "0.71089315", "0.70736504", "0.7073224", "0.7019269", "0.6969061", "0.69212264", "0.6917021", "0.69010055", "0.68599...
0.84067166
0
Returns the smallest int value stored in a sorted array of unique ints that may be shifted. Behavior with arrays not following these restrictions is undefined.
public static int findMinElement(int[] array) { if(array.length < 1) { throw new IllegalArgumentException("array is empty"); } int left = 0; int right = array.length - 1; int mid = (left + right) / 2; while(left < right) { if(array[(mid - 1) % arra...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "int min() {\n\t\t// added my sort method in the beginning to sort our array\n\t\tint n = array.length;\n\t\tint temp = 0;\n\t\tfor (int i = 0; i < n; i++) {\n\t\t\tfor (int j = 1; j < (n - i); j++) {\n\t\t\t\tif (array[j - 1] > array[j]) {\n\t\t\t\t\ttemp = array[j - 1];\n\t\t\t\t\tarray[j - 1] = array[j];\n\t\t\t...
[ "0.71575487", "0.7156503", "0.71241856", "0.7046829", "0.70219797", "0.70182973", "0.6892487", "0.68645823", "0.6856561", "0.68446666", "0.6837296", "0.6809772", "0.67991525", "0.6770575", "0.6707057", "0.6698134", "0.6670625", "0.66698134", "0.6664112", "0.66242486", "0.6621...
0.6523463
24
/ free cache memory
void mips3_exit(void) { if (mips3.icache) free(mips3.icache); mips3.icache = NULL; if (mips3.dcache) free(mips3.dcache); mips3.dcache = NULL; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void destroy() {\n destroyCache();\n }", "void clearCache();", "void clearCache();", "public void releaseCachedPages() {\n cache.removeAll();\n }", "public void dereferenceCache() {\n this.cache = null;\n }", "public void dispose() {\n/* 105 */ this.cache.clear();\n/* ...
[ "0.7752284", "0.74954534", "0.74954534", "0.74804467", "0.7419694", "0.73723966", "0.73455137", "0.73211265", "0.72180116", "0.720979", "0.7205416", "0.71356934", "0.7124703", "0.711743", "0.7116921", "0.7101674", "0.7093136", "0.70724756", "0.7047683", "0.70190054", "0.69579...
0.6382773
63
/ kludge for DRC support
void mips3drc_set_options(UINT8 cpunum, UINT32 opts) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private USI_ADRC() {}", "zzang mo29839S() throws RemoteException;", "zzafe mo29840Y() throws RemoteException;", "zzand mo29852bb() throws RemoteException;", "public interface C0335c {\n }", "void mo21072c();", "private void b044904490449щ0449щ() {\n /*\n r7 = this;\n r0 = new rr...
[ "0.60595846", "0.5870751", "0.56965524", "0.5665452", "0.5642538", "0.559198", "0.55419874", "0.5507504", "0.5471501", "0.54613227", "0.5459305", "0.54589576", "0.5448807", "0.54396313", "0.54298526", "0.5396819", "0.539624", "0.5390525", "0.53802425", "0.53676575", "0.535860...
0.0
-1
/ COP0 (SYSTEM) EXECUTION HANDLING
static UINT32 update_cycle_counting(void) { UINT32 count = (activecpu_gettotalcycles64() - mips3.count_zero_time) / 2; UINT32 compare = mips3.cpr[0][COP0_Compare]; UINT32 cyclesleft = compare - count; double newtime; //printf("Update: count=%08X compare=%08X delta=%08X SR=%08X time=%f\n", count, compare...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void exec();", "abstract void exec();", "static int onShellCommand(Shell shell, String cmd) {\n char c;\n List<AppOpsManager.PackageOps> ops;\n if (cmd == null) {\n return shell.handleDefaultCommands(cmd);\n }\n PrintWriter pw = shell.getOutPrintWriter();\n ...
[ "0.6287724", "0.6282971", "0.57839787", "0.5771908", "0.5721865", "0.57100636", "0.56740254", "0.56582284", "0.5636788", "0.56013376", "0.55723035", "0.5539308", "0.5529748", "0.5513594", "0.5486344", "0.54766554", "0.5469948", "0.5465142", "0.5460428", "0.5419257", "0.540244...
0.0
-1
/ COP1 (FPU) EXECUTION HANDLING
INLINE UINT64 get_cop1_reg(int idx) { return mips3.cpr[1][idx]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void createCoProcFPU(Code32 code, int opCode, int cond, int Rt, int extReg) {\r\n\t\tcode.instructions[code.iCount] = (cond << 28) | opCode | (extReg << 16) | (Rt << 12);\r\n\t\tcode.incInstructionNum();\r\n\t}", "INLINE void handle_cop1x(UINT32 op)\n\t{\n\t\tif (!(SR & SR_COP1))\n\t\t\tgenerate_exceptio...
[ "0.6802283", "0.6691847", "0.5931674", "0.5765218", "0.57306874", "0.5494913", "0.5447721", "0.5410107", "0.54083693", "0.5256154", "0.5233742", "0.5228444", "0.5222473", "0.51875705", "0.51433825", "0.5123597", "0.5104303", "0.5089713", "0.5070774", "0.50704247", "0.5067198"...
0.0
-1
/ COP1X (FPU EXTRA) EXECUTION HANDLING
INLINE void handle_cop1x(UINT32 op) { if (!(SR & SR_COP1)) generate_exception(EXCEPTION_BADCOP, 1); switch (op & 0x3f) { case 0x00: /* LWXC1 */ FDVALS = RLONG(RSVAL32 + RTVAL32); break; case 0x01: /* LDXC1 */ FDVALD = RDOUBLE(RSVAL32 + RTVAL32); break; case 0x08: /* SWXC1 */ ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void createCoProcFPU(Code32 code, int opCode, int cond, int Rt, int extReg) {\r\n\t\tcode.instructions[code.iCount] = (cond << 28) | opCode | (extReg << 16) | (Rt << 12);\r\n\t\tcode.incInstructionNum();\r\n\t}", "private void createFPdataConv(Code32 code, int opCode, int cond, int Vd, int Vm, int opc, i...
[ "0.67006624", "0.5290628", "0.51883775", "0.513252", "0.5094165", "0.5076649", "0.50626564", "0.5051097", "0.501544", "0.49706745", "0.49183413", "0.49126315", "0.48925915", "0.48815194", "0.48655057", "0.4811145", "0.48103577", "0.47988793", "0.4778157", "0.4739401", "0.4727...
0.70490956
0
/ COP2 (CUSTOM) EXECUTION HANDLING
INLINE UINT64 get_cop2_reg(int idx) { return mips3.cpr[2][idx]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract void exec();", "@Override\r\n\tprotected void processExecute() {\n\r\n\t}", "void exec(Env e, AST[] args) { throw H2O.unimpl(\"No exec method for `\" + this.opStr() + \"` during `apply` call\"); }", "public abstract boolean execute(PlugInContext context) throws Exception;", "private void handleInv...
[ "0.6210035", "0.6131817", "0.60463417", "0.60129344", "0.6012811", "0.5896481", "0.5894432", "0.5884478", "0.58309853", "0.57866645", "0.57845306", "0.5767402", "0.57451826", "0.5744674", "0.5736322", "0.5731132", "0.57241595", "0.5674554", "0.56503236", "0.56322706", "0.5626...
0.0
-1
/ CORE EXECUTION LOOP
int mips3_execute(int cycles) { //printf("mips3_execute (PC=%08X)\n", mips3.pc); /* count cycles and interrupt cycles */ mips3_icount = cycles; mips3_icount -= mips3.interrupt_cycles; mips3.interrupt_cycles = 0; if (mips3.bigendian) change_pc32bedw(mips3.pc); else change_pc32bedw(mips3.pc); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void run() {\r\n\t\t\r\n\t\t// While the PC is less than allocated memory and less than SP\r\n\t\twhile (getPC() < getLIM() && getPC() < getSP()) {\r\n\t\t\tm_instr = m_MMU.fetch(getPC());\r\n\t\t\t// Increment PC counter by Instruction Size now\r\n\t\t\t// since nowhere lower does it get called again\r\n\t...
[ "0.6336203", "0.6335354", "0.63226557", "0.6250774", "0.6237948", "0.6153345", "0.61266506", "0.61188", "0.607024", "0.6066919", "0.6037296", "0.6032512", "0.5999147", "0.59837115", "0.5960953", "0.59551877", "0.5948242", "0.59432065", "0.5931406", "0.59304774", "0.59304774",...
0.0
-1
/ COMPLEX OPCODE IMPLEMENTATIONS
static void lwl_be(UINT32 op) { offs_t offs = SIMMVAL + RSVAL32; data32_t temp = RLONG(offs & ~3); if (RTREG) { if (!(offs & 3)) RTVAL64 = (INT32)temp; else { int shift = 8 * (offs & 3); RTVAL64 = (INT32)((RTVAL32 & (0x00ffffff >> (24 - shift))) | (temp << shift)); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Operations operations();", "private native double SumaC(double operador_1, double operador_2);", "private int caculate(Operation opt, int t1, int t2) {\n\t\tint res;\n\t\tswitch (opt) {\n\t\tcase ADD:\n\t\t\tres = t1 + t2;\n\t\t\tbreak;\n\t\tcase SUB:\n\t\t\tres = t1 - t2;\n\t\t\tbreak;\n\t\tcase MUL:\n\t\t\tr...
[ "0.579187", "0.5782323", "0.5763005", "0.5583698", "0.54705924", "0.5446826", "0.5415564", "0.54087913", "0.5405904", "0.5394022", "0.5376116", "0.53482044", "0.532981", "0.53080374", "0.52980006", "0.5276717", "0.52735645", "0.52394235", "0.52337307", "0.52305657", "0.522642...
0.0
-1
take the payment from users
public static void main(String[] args) { double payment = 0; Scanner in = new Scanner(System.in); boolean positivePayment = true; do { System.out.print("Enter the payment amount: "); try { payment = in.nextDouble() ; if (payment < 0) { positivePayment = false; throw new Negative...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String makePayment(String userName, String teamName, Payment payment) throws RemoteException, InterruptedException;", "public void performPayment() {\n payment.executePayment(amount);\n }", "public void makePayment() {\r\n System.out.println(\"pay\");\r\n setPayed(true);\r\n }", "p...
[ "0.7185866", "0.7101156", "0.7026332", "0.70052624", "0.6993821", "0.6894361", "0.6888935", "0.68057805", "0.6782139", "0.67730176", "0.6721925", "0.6709448", "0.670482", "0.6656089", "0.6579775", "0.65621656", "0.6512218", "0.6491067", "0.64868677", "0.64828354", "0.64334744...
0.0
-1
A constant that contains the number of jugglers that one circuit can have
public static void main(String[] args) { // Start a new instance of this class, which parses and adds jugglefest.txt to your Lists JuggleFestCircuitAssignments assignment = null; try { assignment = new JuggleFestCircuitAssignments(); System.err.println("Added " + assignm...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getConstantCount() {\r\n return EnthalpyVapour.CONSTANT_COUNT;\r\n }", "int getNumberOfCavalry();", "public int numberOfKnightsIn() { // numero di cavalieri a tavola\n \n return numeroCompl;\n }", "public int getNumberOfComponents();", "public abstract int numOfSameTypeNeighbour...
[ "0.6506253", "0.6356201", "0.6182387", "0.602044", "0.60038644", "0.6000018", "0.59919053", "0.5983999", "0.59719807", "0.5936247", "0.58930534", "0.5891693", "0.587338", "0.58541834", "0.5839397", "0.5830615", "0.5822291", "0.58080107", "0.580524", "0.5800974", "0.5783194", ...
0.0
-1
Attempts to add every juggler to their firstchoice circuit If that circuit is already full, after being added to the circuit, the worst person in the circuit will be kicked to their 2nd choice
public void addAllJugglersToFirstCircuitChoice() { for (int currentJuggler = 0; currentJuggler < jugglers.size(); currentJuggler++) { // For each juggler who needs to be added to a circuit... int currentJugglerMostDesiredCircuitIndex = jugglers.get(currentJuggler).getDesiredCircuits().get(0); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void makeFirstRound() {\n Strategy tactics = null;\n ArrayList<Producer> auxProducerList = new ArrayList<>(listOfProducers.getList());\n for (Distributor dst : listOfDistributors.getList()) {\n if (dst.getSubscribedproducers().isEmpty()) {\n int auxNeededPower ...
[ "0.5846012", "0.57558227", "0.57429266", "0.5648818", "0.5616296", "0.55650526", "0.5506383", "0.53809154", "0.5380134", "0.5353792", "0.5352084", "0.53507125", "0.53470355", "0.53196317", "0.52973074", "0.5292134", "0.5291874", "0.52860504", "0.52852464", "0.5246074", "0.523...
0.8271821
0
Remove this juggler from his current circuit.
public void kickToLowerDesiredCircuit(int jugglerBeingKicked, int circuitJugglerIsCurrentlyIn) { circuits.get(circuitJugglerIsCurrentlyIn).getJugglersInCircuit().remove( circuits.get(circuitJugglerIsCurrentlyIn).getJugglersInCircuit().indexOf(jugglerBeingKicked)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void remove() {\n\t }", "public void remove() {\n\t }", "public void remove() {\n\t }", "public final void remove () {\r\n }", "public void remove() {\r\n return;\r\n }", "public void remove() {\n removeNode(this);\n }", "public void remove() {\n\n ...
[ "0.6414046", "0.6414046", "0.6414046", "0.6404475", "0.6402909", "0.6396315", "0.6383913", "0.63818985", "0.6369792", "0.6318739", "0.6318739", "0.6290424", "0.6290424", "0.6290424", "0.6290424", "0.6290424", "0.6290424", "0.6290424", "0.6288735", "0.6280419", "0.62427", "0...
0.0
-1
Takes in a user's jugglefest.txt file and reads it linebyline, parsing and adding each line to their arrays
public JuggleFestCircuitAssignments() throws FileNotFoundException { // Prompt the user for the jugglefest.txt file and store the path to a variable // Scanner userFileNameInput = new Scanner(System.in); // System.out.println("Please enter the path to your jugglefest.txt file"); // Strin...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void getDataFromFile(){\n\n try\n {\n File file = new File( fileName );\n FileInputStream fis = new FileInputStream( file );\n DataInputStream in = new DataInputStream(fis);\n BufferedReader br = new BufferedReader(new InputStreamReader(in));\n String message = \"\",...
[ "0.5957833", "0.5932612", "0.5897084", "0.5895178", "0.5894573", "0.5893767", "0.58590883", "0.58192617", "0.5807401", "0.58052146", "0.5797004", "0.5711522", "0.56944275", "0.56923366", "0.5687254", "0.5666475", "0.566062", "0.56511724", "0.5647744", "0.56375444", "0.5627143...
0.62138575
0
Test if the list is logically empty.
public boolean isEmpty( ) { return header.next == null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean empty() {\n\t\treturn list.size() == 0;\n\t}", "public static boolean empty() {\n\n if (list.size() != 0){\n return false;\n }\n return true;\n }", "public boolean empty() {\n if (list.size() == 0) {\n return true;\n }\n else {\n...
[ "0.85706264", "0.85014397", "0.8394054", "0.83663195", "0.83663195", "0.83433235", "0.83208483", "0.8307951", "0.82785374", "0.82604975", "0.8256402", "0.82369184", "0.8215179", "0.81770074", "0.8164669", "0.8161009", "0.81303084", "0.8104123", "0.80912656", "0.79676914", "0....
0.0
-1
Make the list logically empty.
public void makeEmpty( ) { header.next = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void makeEmpty() {\r\n\t\tArrays.fill(list, -1);\r\n\t}", "public void makeEmpty() {\n // remove Squares until empty\n while (!exploreList.isEmpty()) {\n exploreList.getNext();\n }\n }", "public void makeEmpty() {\n System.out.println(\"List is now empty\");\n ...
[ "0.8348013", "0.77435744", "0.7662704", "0.76451147", "0.76307905", "0.73778", "0.7342188", "0.730314", "0.7217259", "0.71914214", "0.71914214", "0.7176521", "0.714788", "0.71270126", "0.7109684", "0.7094476", "0.70119107", "0.7009763", "0.70068604", "0.69944215", "0.69820255...
0.6899806
28
Return an iterator representing the header node.
public LinkedListItr zeroth( ) { return new LinkedListItr( header ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public ListIterator getHeaders()\n { return headers.listIterator(); }", "public ListIterator getHeaderNames() {\n ListIterator li = this.headers.listIterator();\n LinkedList retval = new LinkedList();\n while (li.hasNext()) {\n SIPHeader sipHeader = (SIPHeader) li.next...
[ "0.7547807", "0.7223722", "0.6943666", "0.69106495", "0.6592624", "0.65584123", "0.64848894", "0.6247986", "0.61993086", "0.61544365", "0.612524", "0.60952926", "0.6058907", "0.60422957", "0.5980112", "0.5969269", "0.5969007", "0.5959527", "0.5948375", "0.5946342", "0.5892751...
0.60001403
14
Return an iterator representing the first node in the list. This operation is valid for empty lists.
public LinkedListItr first( ) { return new LinkedListItr( header.next ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public LinkedListIterator<AnyType> first() {\n return new LinkedListIterator<AnyType>(header.next);\n }", "public ListIterator iterator()\n {\n return new ListIterator(firstLink);\n }", "public Node<T> getFirst() \r\n {\r\n if (isEmpty()) return sentinel;\r\n return sentinel.next;...
[ "0.7300311", "0.71235216", "0.71110433", "0.709144", "0.70602316", "0.7020782", "0.69913626", "0.69345045", "0.6923151", "0.6860733", "0.67683417", "0.67280084", "0.6708393", "0.66136545", "0.6609241", "0.6600038", "0.6590816", "0.65790087", "0.6532418", "0.648783", "0.64878"...
0.6963401
7
Return iterator corresponding to the first node containing an item.
public LinkedListItr find( Object x ) { ListNode itr = header.next; while( itr != null && !itr.element.equals( x ) ) itr = itr.next; return new LinkedListItr( itr ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public Iterator<Item> iterator() {\n return new HeadFirstIterator();\n }", "public Item next() throws XPathException {\n while (true) {\n NodeInfo next = (NodeInfo)iterator.next();\n if (next == null) {\n current = null;\n positi...
[ "0.6841889", "0.6589411", "0.6363438", "0.61736107", "0.6149679", "0.6119475", "0.6082776", "0.60471165", "0.60451186", "0.60408306", "0.60058814", "0.59655833", "0.5963659", "0.5867978", "0.5847075", "0.5831629", "0.58231044", "0.58204603", "0.579043", "0.57896346", "0.57881...
0.5386369
66
Return iterator prior to the first node containing an item.
public LinkedListItr findPrevious( Object x ) { ListNode itr = header; while( itr.next != null && !itr.next.element.equals( x ) ) itr = itr.next; return new LinkedListItr( itr ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public Iterator<Item> iterator() {\n return new HeadFirstIterator();\n }", "OIterator<V> before();", "public Item next() throws XPathException {\n while (true) {\n NodeInfo next = (NodeInfo)iterator.next();\n if (next == null) {\n current = n...
[ "0.65342605", "0.61520076", "0.6139895", "0.60605067", "0.6060185", "0.60481954", "0.58963287", "0.5861567", "0.58472735", "0.5841323", "0.5834209", "0.5798078", "0.5795983", "0.5783272", "0.5735753", "0.57341075", "0.57179755", "0.5691694", "0.56890255", "0.56815654", "0.562...
0.59792966
6
Remove the first occurrence of an item.
public void remove( Object x ) { LinkedListItr p = findPrevious( x ); if( p.current.next != null ) p.current.next = p.current.next.next; // Bypass deleted node }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public Item removeFirst() {\n nextFirst = moveForward(nextFirst, 1);\n Item output = items[nextFirst];\n items[nextFirst] = null;\n size -= 1;\n return output;\n }", "Object removeFirst();", "public Item removeFirst() {\r\n if (isEmpty()) {\r\n ...
[ "0.8124812", "0.77813673", "0.7642432", "0.7637581", "0.75555396", "0.74784", "0.73648924", "0.73228943", "0.73153096", "0.72929865", "0.7280261", "0.7173665", "0.7112929", "0.7095792", "0.70660245", "0.7061142", "0.70455295", "0.70293605", "0.7020801", "0.7019287", "0.701816...
0.0
-1
Get the conent by type
public Integer getRandomIndexByType(int type){ Random randomGenerator = new Random(); newContent.clear(); for(int i = 0; i<this.type.size(); i++) { if(this.type.get(i) == type) { newContent.add(this.content.get(i)); } } Integer index = randomGenerator.nextInt(newContent.size()); return index; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic String getType() {\n\t\treturn \"Concert\";\r\n\t}", "private Acao.Tipo getTipo(String tipo) {\n if (tipo.contentEquals(DISPARO.getName())) {\n return DISPARO;\n }\n\n if (tipo.contentEquals(DESCONEXAO.getName())) {\n return DESCONEXAO;\n }\...
[ "0.63419604", "0.60253316", "0.5992642", "0.5979966", "0.5923641", "0.59140724", "0.5912702", "0.5867254", "0.5810114", "0.5745841", "0.56737447", "0.5660343", "0.5657048", "0.56316316", "0.55868375", "0.55831116", "0.5574545", "0.55485857", "0.55132645", "0.5507623", "0.5502...
0.0
-1
Get a message from file by index
public String getNotiContent(int index){ return content.get(index); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Res.Msg getMsg(int index);", "io.dstore.engine.Message getMessage(int index);", "io.dstore.engine.Message getMessage(int index);", "io.dstore.engine.Message getMessage(int index);", "io.dstore.engine.Message getMessage(int index);", "io.dstore.engine.Message getMessage(int index);", "public synchronize...
[ "0.7004804", "0.69117886", "0.69117886", "0.69117886", "0.69117886", "0.69117886", "0.6766431", "0.6673877", "0.6544813", "0.6488643", "0.6473983", "0.6473983", "0.6473983", "0.6473983", "0.6473983", "0.6470233", "0.6470233", "0.6466554", "0.6429158", "0.6404653", "0.6404653"...
0.5582563
66
Get message from file by random type
public String getContentByArrayTypeRandom(int...type){ ArrayList<String> arrayMessage = new ArrayList<String>(); Random randomGenerator = new Random(); for (int j = 0; j<type.length; j++){ for(int i = 0; i<this.type.size(); i++) { if(this.type.get(i) == type[j]) { arrayMessage.add(this.content.get...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getAttachFileByArrayTypeRandom(int...type){\n\t\tArrayList<String> arrayAttachFile = new ArrayList<String>();\n\t\tRandom randomGenerator = new Random();\n\t\tfor (int j = 0; j<type.length; j++){\n\t\t\tfor(int i = 0; i<this.type.size(); i++)\n\t\t\t{\t\n\t\t\t\tif(this.type.get(i) == type[j]) {\n\t\...
[ "0.5753247", "0.5593399", "0.54552853", "0.5321626", "0.5315495", "0.5205512", "0.52054566", "0.5198405", "0.5194884", "0.51843446", "0.5158554", "0.50920457", "0.5079871", "0.5063669", "0.5042158", "0.5041736", "0.5039787", "0.5016215", "0.49992588", "0.49916524", "0.4981684...
0.59985733
0
Get mode from file by random type
public String getModeByArrayTypeRandom(int...type){ ArrayList<String> array = new ArrayList<String>(); Random randomGenerator = new Random(); for (int j = 0; j<type.length; j++){ for(int i = 0; i<this.type.size(); i++) { if(this.type.get(i) == type[j]) { array.add(this.mode.get(i)); } } }...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static FileIOMode valueOf(int mode){\r\n\t\tswitch(mode){\r\n\t\t\tcase 0: return NON_STREAM;\r\n\t\t\tcase 1: return STREAM;\r\n\t\t\tcase 2: return BOTH;\r\n\t\t\tcase -1: return NONE;\r\n\t\t\tdefault: return null;\r\n\t\t}\r\n\t}", "public static int fileType(File file) {\n for (String type : i...
[ "0.5901427", "0.5848196", "0.5715686", "0.54570687", "0.5456189", "0.5377375", "0.52813303", "0.52782154", "0.52566355", "0.51885027", "0.5186996", "0.51721925", "0.5153644", "0.5133552", "0.51124954", "0.5074389", "0.50309837", "0.5013837", "0.5003754", "0.49750438", "0.4968...
0.5700248
3
. Create a new History node object
public final void addHistoryNode(final ShapePicaso shape, final int operation, final Object newHist, final Object oldHist) { if (newHist instanceof SceneCoordinates && operation == Operations.MOVE) { SceneCoordinates newVal = (SceneCoordinates) newHist; SceneCoordinates oldVal = (SceneCoordinates) old...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private History() {}", "public History() {\n }", "public History(History historyData) {\n\tthis.timestampMinute = historyData.getTimestampMinute();\n\tthis.status = historyData.getStatus();\n\tthis.plug = historyData.getPlug();\n }", "public HistoryGraph() {\n revisions = new HashSet<Revision>()...
[ "0.72306657", "0.6916947", "0.6458725", "0.643741", "0.64204895", "0.63812536", "0.6371915", "0.63579065", "0.6208519", "0.6120133", "0.60602015", "0.60544163", "0.6021408", "0.6021139", "0.6014176", "0.59828997", "0.5976352", "0.5976352", "0.58450687", "0.5816305", "0.580477...
0.60942554
10
. Add a node without previous or new object, for delete, for draw
public final void addHistoryNode(final ShapePicaso shape, final int operation) { if (operation == Operations.DELETE || operation == Operations.DRAW) { HistoryNode node = new HistoryNode(shape, operation); this.historyManager.addNewRecord(node); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void addNode()\n {\n Node newNode = new Node(this.numNodes);\n this.nodeList.add(newNode);\n this.numNodes = this.numNodes + 1;\n }", "public void addNode() {\r\n \r\n Nod nod = new Nod(capacitate_noduri);\r\n numar_noduri++;\r\n noduri.add(nod);\r\n }", ...
[ "0.672394", "0.65281326", "0.6503216", "0.6500664", "0.63441014", "0.63416517", "0.6258217", "0.62443876", "0.6233943", "0.61997443", "0.618217", "0.6178405", "0.6147245", "0.6142399", "0.6142326", "0.6128075", "0.6099769", "0.609513", "0.60570586", "0.6048624", "0.60441947",...
0.0
-1
. Undo the context to the previews state
public final void undo() { this.historyManager.undo(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void undo() {\n\t\t\r\n\t}", "@Override\n\tpublic void undo() {\n\t\tlight.off();\n\t}", "@Override\n public void undo() {\n Memento temp = createMemento();\n memento.restore();\n memento = temp;\n }", "public void undo() {\n }", "protected final void undo() {\n ...
[ "0.7164444", "0.6932179", "0.69059116", "0.6888256", "0.6869684", "0.68208224", "0.67334604", "0.6733197", "0.6733197", "0.6717346", "0.66810673", "0.66480744", "0.66480744", "0.66480744", "0.66384155", "0.66156733", "0.6516074", "0.6515352", "0.64975244", "0.64790756", "0.64...
0.66010606
16
. Redo the context to the next state
public final void redo() { this.historyManager.redo(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\t\t\tprotected void restoreContext() {\n\t\t\t\t\r\n\t\t\t}", "public void reset() {\n context.reset();\n state = State.NAME;\n }", "public void reset() {\n\t\treset(ModSettings.currentContext);\n\t}", "protected void resetState()\n {\n // Nothing to do by def...
[ "0.6881498", "0.65221566", "0.6331624", "0.6165009", "0.61412925", "0.61164266", "0.60641193", "0.60161746", "0.59693784", "0.59675884", "0.596567", "0.59639204", "0.592049", "0.5912353", "0.5912353", "0.5912353", "0.5912353", "0.59119445", "0.5907788", "0.5894306", "0.586687...
0.0
-1
Creates a new ValidatorStandardSubsetBroad validator.
public ValidatorStandardSubsetBroad() { super(); addErrorKey(ERROR_KEY1); addValidatorErrorListener(new DefaultErrorListener(), ERROR_KEY1); addErrorKey(ERROR_KEY2); addValidatorErrorListener(new DefaultErrorListener(), ERROR_KEY2); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private TSLValidatorFactory() {\r\n\t\tsuper();\r\n\t}", "public BundleValidator() {\n\t\tsuper();\n\t}", "public Wps10Validator() {\r\n super();\r\n xmlTypeValidator = XMLTypeValidator.INSTANCE;\r\n }", "public GenericSchemaValidator() {}", "public SpecValidator() {\n\t\tsuper();\n\t}", ...
[ "0.4894249", "0.47646338", "0.47617212", "0.47493842", "0.474759", "0.47248787", "0.47162527", "0.46213746", "0.45720822", "0.4530216", "0.451608", "0.4498111", "0.44854268", "0.44813108", "0.44649836", "0.44632477", "0.44602233", "0.44489136", "0.43682253", "0.43623248", "0....
0.64180887
0
The method that is executed when you hit the run button.
public static void main(String[] args) { // create a scanner for user input Scanner input = new Scanner(System.in); // declare integer variable int posInt; // only allows user to enter positive integer do{ // ask the user for a postivie integer System.out.println("Please e...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract void executeRunButton();", "@Override\n\tpublic void actionPerformed(ActionEvent e) {\n\t\tRun();\n\t}", "default void run() {\n\t\tSystem.out.println(\"run\");\r\n\t}", "@Override\n public void run() {\n nextButtonAction(); // invoking next button //\n ...
[ "0.79754335", "0.7550978", "0.7196994", "0.7061655", "0.70090747", "0.70074403", "0.69017625", "0.68695426", "0.6855391", "0.6853005", "0.6842966", "0.6823052", "0.6823052", "0.6823052", "0.6823052", "0.6823052", "0.68221825", "0.6808255", "0.68016386", "0.6769912", "0.675637...
0.0
-1
Returns a list of task records.
@GetMapping(value="/all",produces= { MediaType.APPLICATION_JSON_VALUE }) public List<TaskDTO> getAllTasks() { return taskService.getAllTasks(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static List<DiagramTask> getAllrecords()\r\n {\r\n List<DiagramTask> tasks = new ArrayList();\r\n \r\n try\r\n {\r\n tasks = TASK_DAO.retrieveTask();\r\n \r\n }\r\n catch (HibernateException e)\r\n {\r\n addMessage(\"Error!...
[ "0.7653332", "0.737288", "0.71132785", "0.7069109", "0.7053144", "0.7053144", "0.6977781", "0.6956452", "0.69157153", "0.6890589", "0.6887421", "0.6885465", "0.683065", "0.67333645", "0.6731582", "0.6645706", "0.6638877", "0.6633417", "0.6623075", "0.66105086", "0.65689003", ...
0.6237429
43
Adds a new task record.
@PreAuthorize("hasRole('ADMIN') or hasRole('DBA')") @PostMapping(value="/add",consumes= { MediaType.APPLICATION_JSON_VALUE },produces= { MediaType.APPLICATION_JSON_VALUE }) public StatusDTO addtask(@RequestBody TaskDTO task) { taskService.addTask(task); StatusDTO status = new StatusDTO(); status.setMessage("Ta...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void addTask(Task task){\n SQLiteDatabase db = this.getWritableDatabase();\n ContentValues values = new ContentValues();\n values.put(KEY_ID, task.getId());\n values.put(KEY_LABEL, task.getLabel());\n values.put(KEY_TIME, task.getTime());\n db.insert(TABLE_NAME, nul...
[ "0.7659062", "0.7264049", "0.7260238", "0.71724904", "0.70858103", "0.6998211", "0.69910336", "0.6971978", "0.69668686", "0.69631237", "0.6963067", "0.6923598", "0.6920122", "0.6893734", "0.6820563", "0.68176574", "0.6805576", "0.67994845", "0.6779452", "0.6757607", "0.672788...
0.5999587
71
Returns a particular task record for a given task id.
@GetMapping(value="/{taskId}",produces= { MediaType.APPLICATION_JSON_VALUE }) public TaskDTO getTask(@PathVariable("taskId") Integer taskId) { return taskService.getTaskDTO(taskId); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic Teatask getById(int taskid)\n\t{\n\t\treturn teataskMapper.getById(taskid);\n\t}", "@Nullable\n public Task getTask(int id) {\n Task output = null;\n\n // get a readable instance of the database\n SQLiteDatabase db = getReadableDatabase();\n if (db == null) retu...
[ "0.7581322", "0.74201405", "0.7370575", "0.71835136", "0.71777195", "0.71391374", "0.7125044", "0.70673925", "0.70073986", "0.6956902", "0.68519133", "0.6838586", "0.6791982", "0.6684294", "0.66681474", "0.661242", "0.65782404", "0.65374535", "0.64607215", "0.64562154", "0.64...
0.5783087
56
Deletes a particular task record for a given task id.
@PreAuthorize("hasRole('ADMIN') or hasRole('DBA')") @DeleteMapping(value="/delete/{taskId}",produces= { MediaType.APPLICATION_JSON_VALUE }) public StatusDTO deleteTask(@PathVariable("taskId") Integer taskId) { taskService.deleteTask(taskId); StatusDTO status = new StatusDTO(); status.setMessage("Task Status de...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void deleteByid(int taskid)\n\t{\n\t\tteataskMapper.deleteByid(taskid);\n\t}", "public void deleteTask(long task_id) {\n SQLiteDatabase db = this.getWritableDatabase();\n db.delete(TABLE_TASKS, KEY_ID + \" = ?\",\n new String[] { String.valueOf(task_id) });\n }...
[ "0.7898437", "0.7817556", "0.76332706", "0.7533177", "0.7397137", "0.73969394", "0.73633426", "0.73439246", "0.7181288", "0.7050157", "0.69655913", "0.69454795", "0.6909172", "0.68971795", "0.6878985", "0.6878719", "0.68749535", "0.6833033", "0.67598045", "0.67338", "0.651430...
0.6036659
55
Updates a particular task record for a given task id inside task dto.
@PostMapping(value="/update",consumes={MediaType.APPLICATION_JSON_VALUE},produces={MediaType.APPLICATION_JSON_VALUE}) public StatusDTO updateTask(@RequestBody TaskDTO task){ taskService.updateTask(task); StatusDTO status = new StatusDTO(); status.setMessage("Task details updated successfully"); stat...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "TaskResponse updateTask(TaskRequest taskRequest, Long taskId);", "public int updateTask(Task task) {\n SQLiteDatabase db = this.getWritableDatabase();\n\n ContentValues values = new ContentValues();\n values.put(KEY_TASKNAME, task.getTaskName());\n values.put(KEY_STATUS, task.getStatu...
[ "0.7458916", "0.6744763", "0.6680115", "0.64767677", "0.64695317", "0.64297676", "0.635232", "0.63452154", "0.6332466", "0.6240078", "0.6237575", "0.6204066", "0.61785144", "0.6145372", "0.6142452", "0.6108643", "0.6090374", "0.60670775", "0.6051184", "0.6031232", "0.59709436...
0.66896737
2
array[low, high) [3, 4)
static void mergeSortInner(int[] array, int low, int high, int[] extra) { if (low == high - 1) { return; } if (low >= high) { return; } // 1. 平均切分 int mid = low + (high - low) / 2; // [low, mid) + [mid, high) // 2. 分治算法处理所有...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "int toIndex(int x, int y);", "public static int[] getindex(int[] values) {\n\t \n\t \n\t \n\t int[] b = {64,128,192,256};\n\t \n\t int redindex = 0;\n\t int greenindex=0;\n\t int blueindex=0;\n\t \n\t for(int i=0; i<indexlevel8.length;i++) {\n\t if(values[0] <= indexlevel8[i]) { redindex = i; break;}\...
[ "0.6054442", "0.596132", "0.5943214", "0.5894508", "0.58818674", "0.58099", "0.58080333", "0.57578844", "0.5733277", "0.5706539", "0.5691846", "0.558316", "0.55678254", "0.5531905", "0.55246866", "0.55077577", "0.5456926", "0.54338", "0.5423674", "0.5422031", "0.5406708", "...
0.0
-1
Check for internet Connection
public void requestWishList() { if (!hasInternetConnection()) { PromeetsDialog.show(this, getString(R.string.no_internet)); } else { UserPOJO userPOJO = (UserPOJO) PromeetsUtils.getUserData(PromeetsPreferenceUtil.USER_OBJECT_KEY, UserPOJO.class); if (userPOJO == null)...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private boolean checkInternetConnection() {\n\n ConnectivityManager connectivityManager = (ConnectivityManager) this.getSystemService(Context.CONNECTIVITY_SERVICE);\n\n NetworkInfo networkInfo = connectivityManager.getActiveNetworkInfo();\n\n return (networkInfo != null && networkInfo.isConnec...
[ "0.84628665", "0.84476465", "0.84306777", "0.81418335", "0.81308925", "0.8106153", "0.80978614", "0.8035138", "0.8012396", "0.8009557", "0.79658365", "0.79598814", "0.7922596", "0.7906905", "0.78431284", "0.7831871", "0.7831871", "0.78183144", "0.7804141", "0.7793943", "0.778...
0.0
-1
Convenience method to scale to the given dimensions then relocate the label with respect to the vertical and horizontal alignment.
public void transform( final Dimension dimension ) { transform( dimension.width, dimension.height ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void rescaleLabels() {\n // TJJ Nov 2018 - make sure labels scale correct on any changes\n // to the ring display\n ViewManager vm = getViewManager();\n rangeRings.setLabelSize(vm.getMaster().getDisplayScale());\n }", "@Override\n\tpublic void relocate()\n\t{\n\n\t\tint w =...
[ "0.63598627", "0.6258514", "0.62430376", "0.6162367", "0.60718983", "0.5998164", "0.5923843", "0.58438593", "0.5801641", "0.5713673", "0.555801", "0.5467515", "0.5460853", "0.54255974", "0.5385561", "0.5377537", "0.5372596", "0.53633285", "0.53508383", "0.5344178", "0.531387"...
0.0
-1
Scales the dimensions of the label to fit its parent's boundaries, then multiplying the value by the given factor.
public void transform( final float factor ) { final var compDimen = new ScalableDimension( getParentBounds() ); transform( compDimen.scale( factor ) ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void scale(double factor);", "public void scale(Point P, int scaleFactor) {\n\n\n }", "public void rescale(double newFactor) {\n\t\tthis.branchScale = branchScale*newFactor;\n\t\t\n\t\tfor(Node n : root.getOffspring()) {\n\t\t\trescale( (DrawableNode)n);\n\t\t}\n\t}", "public void scale(double factor) {\r...
[ "0.65898544", "0.6095427", "0.6080471", "0.6073372", "0.58383626", "0.5832363", "0.57077014", "0.5658275", "0.5630474", "0.56298435", "0.5627958", "0.5614429", "0.54993916", "0.54993176", "0.5479493", "0.5464382", "0.5457549", "0.541703", "0.5410349", "0.54092073", "0.5341351...
0.7227268
0
Scales the dimensions of the label to fit its parent's boundaries, while maintaining the aspect ratio, then relocate the label with respect to the vertical and horizontal alignment.
public void transform() { final var bounds = getParentBounds(); transform( bounds.width, bounds.height ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void rescaleLabels() {\n // TJJ Nov 2018 - make sure labels scale correct on any changes\n // to the ring display\n ViewManager vm = getViewManager();\n rangeRings.setLabelSize(vm.getMaster().getDisplayScale());\n }", "@Override\r\n protected void layout() {\n\r\n ...
[ "0.63880956", "0.63432246", "0.6321429", "0.61515296", "0.603632", "0.59089804", "0.5744234", "0.5711586", "0.5683837", "0.5586184", "0.5568681", "0.5565173", "0.5523072", "0.5522165", "0.54808205", "0.54596233", "0.5458717", "0.5457843", "0.5435925", "0.5431179", "0.5423533"...
0.54843694
14
Helper method to determine the width and height of the text.
private Rectangle2D getTextExtents( final String text, final Font font, final Graphics graphics ) { return getFontMetrics( font ).getStringBounds( text, graphics ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public float getTextSizePx() {\n return mPaint.getTextSize();\n }", "public float getTextSize() {\n return mTextContainer.getTextSize();\n }", "public float getTextSize() {\n return mTextSize;\n }", "public int getStringWidth(String text);", "@Override\n public Dimension me...
[ "0.72839886", "0.7101025", "0.7072482", "0.70218897", "0.69029963", "0.6803273", "0.6758387", "0.67521983", "0.6723733", "0.6679325", "0.65860623", "0.6555608", "0.65500766", "0.6498299", "0.6498299", "0.6463411", "0.6434071", "0.6431419", "0.6406148", "0.639242", "0.636094",...
0.6449596
16
Returns the bounds of the parent component, accounting for insets.
private Rectangle getParentBounds() { final var bounds = mParentBounds; return bounds == null ? mParentBounds = calculateBounds( getParent() ) : bounds; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public PBounds getBoundsReference() {\n\t\tPBounds bds = super.getBoundsReference();\n\t\tgetUnionOfChildrenBounds(bds);\n\n\t\tcachedChildBounds.setRect(bds);\n\t\tdouble scaledIndent = INDENT/renderCamera.getViewScale();\t\t\n\t\tbds.setRect(bds.getX()-scaledIndent,bds.getY()-scaledIndent,bds.getWidth()+2*scaled...
[ "0.7311694", "0.7284412", "0.712919", "0.709222", "0.70690733", "0.6882633", "0.68151", "0.67955464", "0.6761089", "0.6699749", "0.66946626", "0.6692886", "0.6688945", "0.6688945", "0.66876036", "0.66646856", "0.66520613", "0.6645735", "0.6636", "0.6611845", "0.6573798", "0...
0.77123266
0
returns a Result object containing all criteria for the specified alarm in the requestBody
@Security.Authenticated(Authenticate.class) public static Result getCriteria(Integer id){ Query q= new Query(); q.select(new ArrayList<String>()).from("criteria").where("AlarmID", "=", Integer.toString(id)); return HttpHelper.query(q.query, fields); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Security.Authenticated(Authenticate.class)\n\tpublic static Result postCriteria(Integer alarmId){\n\t\tQuery q= new Query();\n\t\tRequestBody body= request().body();\n\t\tObjectNode obj = (ObjectNode) body.asJson();\n\t\t \n\t\tif(alarmId == null) \n\t\t\treturn badRequest(\"Invalid alarmId\");\n\t\t\n\t\tif(!ins...
[ "0.5949282", "0.5491134", "0.54311645", "0.5247718", "0.524358", "0.5109285", "0.49622893", "0.4947013", "0.48533717", "0.4846987", "0.48337337", "0.48279074", "0.47631505", "0.47125158", "0.46970418", "0.46937764", "0.4690706", "0.46641514", "0.46457762", "0.46240085", "0.46...
0.5185223
5
adds a new Criteria for the specified Alarm, and returns a Result object
@Security.Authenticated(Authenticate.class) public static Result postCriteria(Integer alarmId){ Query q= new Query(); RequestBody body= request().body(); ObjectNode obj = (ObjectNode) body.asJson(); if(alarmId == null) return badRequest("Invalid alarmId"); if(!instrumentCheck(alarmId, obj)) re...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Security.Authenticated(Authenticate.class)\n\tpublic static Result putCriteria(Integer alarmId, Integer id){\n\t\tQuery q= new Query();\n\t\tRequestBody body= request().body();\n\t\t\n\t\tObjectNode obj = (ObjectNode) body.asJson();\n\n\t\tif(!instrumentCheck(alarmId, obj)) \n\t\t\treturn badRequest(\"Invalid ins...
[ "0.57075393", "0.546117", "0.52366054", "0.5167696", "0.5121394", "0.5121394", "0.5121394", "0.5121394", "0.5121394", "0.5121394", "0.5121394", "0.5012916", "0.5006374", "0.49824142", "0.48578677", "0.48518375", "0.4840476", "0.48302042", "0.48207173", "0.47875857", "0.476645...
0.6288214
0
modifies the specified Criteria for the specified Alarm, and returns a Result object
@Security.Authenticated(Authenticate.class) public static Result putCriteria(Integer alarmId, Integer id){ Query q= new Query(); RequestBody body= request().body(); ObjectNode obj = (ObjectNode) body.asJson(); if(!instrumentCheck(alarmId, obj)) return badRequest("Invalid instrument/field combination");...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Security.Authenticated(Authenticate.class)\n\tpublic static Result postCriteria(Integer alarmId){\n\t\tQuery q= new Query();\n\t\tRequestBody body= request().body();\n\t\tObjectNode obj = (ObjectNode) body.asJson();\n\t\t \n\t\tif(alarmId == null) \n\t\t\treturn badRequest(\"Invalid alarmId\");\n\t\t\n\t\tif(!ins...
[ "0.5696294", "0.5142282", "0.5139911", "0.5097339", "0.50265616", "0.4897881", "0.48973885", "0.4882501", "0.48752916", "0.48631662", "0.48132402", "0.4778541", "0.47392482", "0.46606117", "0.46514174", "0.46514174", "0.46514174", "0.46514174", "0.46358615", "0.46229142", "0....
0.58704567
0
deletes the specified Criteria for the specified Alarm, and returns a Result object
@Security.Authenticated(Authenticate.class) public static Result deleteCriteria(Integer alarmId, Integer id){ Query q= new Query(); RequestBody body= request().body(); q.delete() .from("criteria") .where(primaryKey, "=", Integer.toString(id)) .andWhere("alarmID", "=", Integer.toString(alarmId)); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "int deleteByExample(ScheduleCriteria example);", "int deleteByExample(TbaDeliveryinfoCriteria example);", "int deleteByPrimaryKey(Long pineAlarmId);", "int deleteByPrimaryKey(@Param(\"mainId\") Integer mainId, @Param(\"alarmId\") Integer alarmId);", "int deleteByExample(BasicinfoCriteria example);", "int...
[ "0.61625534", "0.60213673", "0.6000858", "0.59058213", "0.5787608", "0.57773143", "0.5769287", "0.57270145", "0.56634444", "0.5610502", "0.5499249", "0.54830855", "0.5466178", "0.5379644", "0.53675056", "0.53259057", "0.5324948", "0.5317173", "0.53049797", "0.5301703", "0.527...
0.69887626
0
checks for the existence of the instrument and it's field, returns true if present
public static boolean instrumentCheck(Integer alarmId, ObjectNode obj){ Query q= new Query(); // instrument name must exist String instrumentName =obj.get("instrumentName").toString(); instrumentName = instrumentName.substring(1,instrumentName.length()-1); q.select(count).from("instruments") .where("name", ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "boolean hasField3();", "boolean hasField1();", "boolean hasField4();", "boolean hasField0();", "boolean hasField2();", "public boolean isSet(_Fields field) {\n if (field == null) {\n throw new IllegalArgumentException();\n }\n\n switch (field) {\n case COMB_INSTRUMENT_ID:\n return i...
[ "0.6447134", "0.630724", "0.6306607", "0.6247436", "0.61951363", "0.6115473", "0.60597456", "0.6054545", "0.6026493", "0.593627", "0.5901971", "0.57990104", "0.5759569", "0.57564247", "0.5756119", "0.5751079", "0.5749114", "0.5722194", "0.56756693", "0.56756693", "0.5669367",...
0.60556006
7
Constructeur de la class Seance_Salle
public Seance_Salle(int id_seance,int id_salle) { this.id_salle=id_salle; this.id_seance=id_seance; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Salle() {\n\t\tsuper();\n\t\t// TODO Auto-generated constructor stub\n\t}", "public ListSemental() {\n }", "public Sobre() {\n\t\tsuper();\n\t\tinitialize();\n\t}", "public StructuraSemestru2() {\n startSemester= Constants.SEMESTER_START2;\n beginHoliday=Constants.HOLIDAY_START2;\n ...
[ "0.8270011", "0.6949898", "0.6876602", "0.6803934", "0.6714339", "0.66638947", "0.666006", "0.66205543", "0.6615814", "0.65909535", "0.6569345", "0.65610915", "0.6540517", "0.6526037", "0.64809966", "0.6467021", "0.64640075", "0.64616245", "0.64397246", "0.6430057", "0.640414...
0.8310662
0
head of the list / This function prints contents of linked list starting from the given node
public void printList() { Node tnode = head; while (tnode != null) { System.out.print(tnode.data + "->"); tnode = tnode.next; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void printList(Node head)\n {\n while(head!=null){\n System.out.print(head.data+\" \");\n head = head.next;\n }\n }", "public void printList(Node head) \n { \n Node n = head; \n \n while (n != null) \n { \n System.out.pri...
[ "0.8218361", "0.80711174", "0.80438733", "0.7932564", "0.7910297", "0.78943896", "0.7890818", "0.7849013", "0.7839126", "0.7830152", "0.77936447", "0.77008927", "0.7666364", "0.76586163", "0.76199335", "0.7617765", "0.76063526", "0.76028085", "0.7592019", "0.7536944", "0.7526...
0.7446373
28
/ Inserts a new Node at front of the list.
public void push(int new_data) { /* * 1 & 2: Allocate the Node & Put in the data */ Node new_node = new Node(new_data); /* 3. Make next of new Node as head */ new_node.next = head; /* 4. Move the head to point to new Node */ head = new_node; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Node insertBefore(Node node);", "public void insertAtFront(T insertItem) {\n\t\tNode<T> node = new Node<T>(insertItem);\n\t\t\n\t\tif (isEmpty()) // firstNode and lastNode refer to same object\n\t\t\tfirstNode = lastNode = node;\n\t\telse { // firstNode refers to new node\n\t\t\tnode.nextNode = firstNode;...
[ "0.7586085", "0.7575391", "0.7555718", "0.7529886", "0.74939305", "0.7480744", "0.7462563", "0.74121946", "0.74019086", "0.73777163", "0.7375027", "0.73719895", "0.73556674", "0.73262125", "0.73254985", "0.72882205", "0.7258221", "0.7238087", "0.72095525", "0.7188574", "0.717...
0.0
-1