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
Removes the element from in front of queue and returns that element.
public int pop() { if (this.stack2.size() <= 0) { removeAllElementToStack2(); } return this.stack2.removeLast(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public synchronized Object removeFirstElement() {\n return _queue.remove(0);\n }", "public E remove(){\r\n if(isEmpty())\r\n return null;\r\n \r\n //since the array is ordered, the highest priority will always be at the end of the queue\r\n //--currentSize will fi...
[ "0.77138", "0.76798576", "0.76327944", "0.7575122", "0.7531917", "0.7508478", "0.7497966", "0.745763", "0.74524933", "0.7437765", "0.743221", "0.74093735", "0.73924285", "0.7386138", "0.73585826", "0.7328084", "0.7324674", "0.73099446", "0.7304494", "0.73027235", "0.72960716"...
0.0
-1
Get the front element.
public int peek() { if (this.stack2.size() <= 0) { removeAllElementToStack2(); } if (this.stack2.size() == 0) return -1; return this.stack2.getLast(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Object getFront() throws Exception {\n\t\tif(data[front]!=null)\n\t\t\n\t\t return data[front];\n\t\treturn null;\n\t}", "public int getFront() {\n return !isEmpty() ? elements[last - 1] : -1;\n }", "@Override\n\tpublic E getFront() {\n\t\treturn data[front];\n\t}", "public T getFront();"...
[ "0.77886313", "0.7760266", "0.77365255", "0.77095586", "0.76603127", "0.76504976", "0.7623654", "0.75686014", "0.7567856", "0.7549382", "0.75492996", "0.7547624", "0.7537493", "0.7534689", "0.7465438", "0.745354", "0.73278004", "0.73128647", "0.7310279", "0.73006713", "0.7195...
0.0
-1
Returns whether the queue is empty.
public boolean empty() { return this.stack2.size() == 0 && this.stack1.size() == 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean is_empty() {\n\t\tif (queue.size() <= 0) {\n\t\t\treturn true;\n\t\t}\n\t\telse {\n\t\t\treturn false;\n\t\t}\n\t}", "public boolean isEmpty() {\n return this.queue.size() == 0;\n }", "public boolean isEmpty() {\n\t\treturn queue.isEmpty();\n\t}", "public boolean isEmpty() {\n\t\tret...
[ "0.9061608", "0.8914194", "0.8852499", "0.8852499", "0.8815682", "0.8810445", "0.87997335", "0.8791669", "0.8790852", "0.87563825", "0.87563825", "0.87563825", "0.87563825", "0.87563825", "0.87563825", "0.87563825", "0.8689962", "0.8680233", "0.8680233", "0.8680233", "0.86802...
0.0
-1
A listener for autocompletion events.
public interface AutocompletionListener<T> { /** * The user has activated a suggested item. * * This means the user has explicitly activate the item, i.e., pressed enter on or clicked the * item. * @param e the event describing the activation */ public void completionActivated(AutocompletionEvent<T> e); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void completionActivated(AutocompletionEvent<T> e);", "public interface AutoCompleterCallback {\n /** Notification that an item is suggested. */\n void itemSuggested(String autoCompleteString, boolean keepPopupVisible, boolean triggerAction);\n }", "public interface AutoCompleter {\n ...
[ "0.746079", "0.71064335", "0.70941705", "0.660406", "0.6311813", "0.59670365", "0.5951281", "0.59489965", "0.5800131", "0.5792776", "0.57739544", "0.5717078", "0.57111394", "0.56674856", "0.5652919", "0.56517273", "0.56455946", "0.5628301", "0.55497944", "0.54800063", "0.5470...
0.780402
0
The user has activated a suggested item. This means the user has explicitly activate the item, i.e., pressed enter on or clicked the item.
public void completionActivated(AutocompletionEvent<T> e);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void itemSuggested(String autoCompleteString, boolean keepPopupVisible, boolean triggerAction);", "public void onInteract(Item item, Character character) {\n }", "@Override \r\n public void onItemClick(AdapterView<?> arg0, View arg1, int arg2, long arg3) {\n if(!is...
[ "0.6575054", "0.62319297", "0.6123305", "0.6053418", "0.6038379", "0.59855103", "0.5952951", "0.58402467", "0.5820094", "0.58151495", "0.5805579", "0.57987463", "0.57946366", "0.57394093", "0.5714793", "0.5701985", "0.56815195", "0.56803", "0.56803", "0.56803", "0.5667237", ...
0.5630433
27
Transforms one string into another string.
public interface Transformer { /** * Transform a string into another string * @param input string to be transformed * @return transformed string */ public String transform(String input); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String transform(String input);", "public String makeConversion(String value);", "public static CharSequence translate(StringValue sv0, StringValue sv1, StringValue sv2) {\n\n // if any string contains surrogate pairs, expand everything to 32-bit characters\n if (sv0.containsSurrogatePairs...
[ "0.6989296", "0.6348367", "0.6200172", "0.6168362", "0.6115752", "0.59966934", "0.59880406", "0.5929482", "0.5914297", "0.59095544", "0.5880361", "0.58372194", "0.5789198", "0.5744622", "0.5694687", "0.5682008", "0.5628232", "0.56104195", "0.55891234", "0.55667776", "0.554841...
0.5365853
31
Transform a string into another string
public String transform(String input);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String transform(String value){\n return value;\n }", "public String transformString( String inputString) {\n char c[]=inputString.toCharArray();\n String transformedString=\"\";\n \n for (int i =c.length-1; i>=0; i--) { \n transformedString +=c[i];\n ...
[ "0.6701977", "0.66881806", "0.66549546", "0.65929234", "0.60779315", "0.60446715", "0.6040718", "0.60188764", "0.5932092", "0.59004676", "0.58767134", "0.58567643", "0.5850812", "0.5831119", "0.57893366", "0.5757185", "0.574029", "0.56738096", "0.56412065", "0.5621362", "0.55...
0.7835902
0
This interface defines methods to configure channel admin.
public interface IChannelAdminConfiguration { /** * Configures the number of IO threads. * * @param numberOfIoThreads * the number of IO threads to configure * @return this object * @throws IllegalArgumentException * if {@code numberOfIoThreads < 0} */ IChannelAdminConfiguration numberOfIoThreads(Integer numberOfIoThreads); /** * Returns the number of IO threads, or {@code null} which means the number * is calculated based on the number of CPU cores. * * @return the number of IO threads */ Integer numberOfIoThreads(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface ChannelConfiguration {\n\n\t/**\n\t * Channel manager should use driver in listening mode\n\t */\n\tpublic static final long LISTEN_FOR_UPDATE = -1;\n\n\t/**\n\t * ChannelManager should use driver in comand mode, with no periodic reading or listening.\n\t */\n\tpublic static final long NO_READ_NO_...
[ "0.61874384", "0.59884566", "0.5970888", "0.59446275", "0.58890307", "0.58248097", "0.5814177", "0.5802416", "0.5735214", "0.5709052", "0.56087047", "0.5606326", "0.557594", "0.5559297", "0.5548318", "0.55048054", "0.5485637", "0.5458645", "0.545459", "0.5428412", "0.5423746"...
0.741072
0
Creates a new binding label provider with default text and image flags
public BindingLabelProvider() { this(DEFAULT_TEXTFLAGS, DEFAULT_IMAGEFLAGS); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setLabelProvider(ILabelProvider labelProvider) throws Exception;", "public TreeLabelProvider() {\n \t\timageMap = new HashMap();\n \t}", "@Override\n\tpublic IBaseLabelProvider getLabelProvider() {\n\t\treturn null;\n\t}", "@Override\r\n\tpublic JLabel createLabel() {\r\n\t\treturn new JLabel();\...
[ "0.6042406", "0.5862237", "0.57609314", "0.5625217", "0.5617067", "0.5567473", "0.55157787", "0.54425985", "0.5427454", "0.5417168", "0.5414608", "0.5414608", "0.54140294", "0.5389329", "0.53834105", "0.53783876", "0.5375755", "0.5363241", "0.53350633", "0.5330469", "0.531838...
0.8408095
0
TODO Autogenerated method stub
public static void main(String[] args) { LinkedListNode a = new LinkedListNode(1); LinkedListNode b = new LinkedListNode(2); LinkedListNode c = new LinkedListNode(3); LinkedListNode d = new LinkedListNode(2); LinkedListNode e = new LinkedListNode(6); LinkedListNode f = new LinkedListNode(5); a.next = b; b.next = c; c.next = d; d.next = e; e.next = f; findLocalMaxima(a); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public SesToolDatabaseJobPropertyruleExample() { oredCriteria = new ArrayList<Criteria>(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobProperty;\r\n }", "@Override\n public Map<String, String> createFieldToPropertyMapping() {\n final M...
[ "0.60996294", "0.5975225", "0.5659944", "0.5560696", "0.54269165", "0.533714", "0.51842797", "0.50247276", "0.500921", "0.49423498", "0.4876827", "0.48542002", "0.48444676", "0.48407155", "0.48362058", "0.4779195", "0.4779102", "0.47743773", "0.476344", "0.47617984", "0.47615...
0.65838474
0
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public void setOrderByClause(String orderByClause) { this.orderByClause = orderByClause; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.6582365", "0.60992026", "0.5973674", "0.56583536", "0.55613923", "0.5426823", "0.5336789", "0.51845735", "0.50238395", "0.5010588", "0.49403766", "0.4878161", "0.48527682", "0.48432302", "0.48411688", "0.48379725", "0.47777742", "0.4777052", "0.47737068", "0.47631186", "0....
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public String getOrderByClause() { return orderByClause; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.6582644", "0.60979515", "0.5973737", "0.56574816", "0.5561305", "0.542573", "0.5337626", "0.51845294", "0.502285", "0.50087845", "0.4941367", "0.48774207", "0.48521587", "0.4842773", "0.48405975", "0.48370117", "0.47781393", "0.47761074", "0.47733438", "0.47622862", "0.476...
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public void setDistinct(boolean distinct) { this.distinct = distinct; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.65834427", "0.60995626", "0.59720665", "0.56563", "0.555803", "0.5423561", "0.5334851", "0.5181285", "0.50223553", "0.5012847", "0.49378887", "0.48789757", "0.48515013", "0.48432064", "0.48416188", "0.48403534", "0.4778591", "0.4776449", "0.4769373", "0.4766553", "0.476495...
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public boolean isDistinct() { return distinct; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.65838474", "0.60996294", "0.5975225", "0.5659944", "0.5560696", "0.54269165", "0.533714", "0.51842797", "0.50247276", "0.500921", "0.49423498", "0.4876827", "0.48542002", "0.48444676", "0.48407155", "0.48362058", "0.4779195", "0.4779102", "0.47743773", "0.476344", "0.47617...
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public List<Criteria> getOredCriteria() { return oredCriteria; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.6582365", "0.60992026", "0.5973674", "0.56583536", "0.55613923", "0.5426823", "0.5336789", "0.51845735", "0.50238395", "0.5010588", "0.49403766", "0.4878161", "0.48527682", "0.48432302", "0.48411688", "0.48379725", "0.47777742", "0.4777052", "0.47737068", "0.47631186", "0....
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public void or(Criteria criteria) { oredCriteria.add(criteria); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.6582644", "0.60979515", "0.5973737", "0.56574816", "0.5561305", "0.542573", "0.5337626", "0.51845294", "0.502285", "0.50087845", "0.4941367", "0.48774207", "0.48521587", "0.4842773", "0.48405975", "0.48370117", "0.47781393", "0.47761074", "0.47733438", "0.47622862", "0.476...
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public Criteria or() { Criteria criteria = createCriteriaInternal(); oredCriteria.add(criteria); return criteria; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.65834427", "0.60995626", "0.59720665", "0.56563", "0.555803", "0.5423561", "0.5334851", "0.5181285", "0.50223553", "0.5012847", "0.49378887", "0.48789757", "0.48515013", "0.48432064", "0.48416188", "0.48403534", "0.4778591", "0.4776449", "0.4769373", "0.4766553", "0.476495...
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public Criteria createCriteria() { Criteria criteria = createCriteriaInternal(); if (oredCriteria.size() == 0) { oredCriteria.add(criteria); } return criteria; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.65838474", "0.60996294", "0.5975225", "0.5659944", "0.5560696", "0.54269165", "0.533714", "0.51842797", "0.50247276", "0.500921", "0.49423498", "0.4876827", "0.48542002", "0.48444676", "0.48407155", "0.48362058", "0.4779195", "0.4779102", "0.47743773", "0.476344", "0.47617...
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
protected Criteria createCriteriaInternal() { Criteria criteria = new Criteria(); return criteria; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.6582365", "0.60992026", "0.5973674", "0.56583536", "0.55613923", "0.5426823", "0.5336789", "0.51845735", "0.50238395", "0.5010588", "0.49403766", "0.4878161", "0.48527682", "0.48432302", "0.48411688", "0.48379725", "0.47777742", "0.4777052", "0.47737068", "0.47631186", "0....
0.0
-1
This method was generated by MyBatis Generator. This method corresponds to the database table ses_tool_database_job_propertyrule
public void clear() { oredCriteria.clear(); orderByClause = null; distinct = false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SesToolDatabaseJobPropertyruleExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "PropertyRule createPropertyRule();", "public void setJobProperty(String jobProperty) {\r\n this.jobProperty = jobProperty;\r\n }", "public String getJobProperty() {\r\n return jobPro...
[ "0.6582644", "0.60979515", "0.5973737", "0.56574816", "0.5561305", "0.542573", "0.5337626", "0.51845294", "0.502285", "0.50087845", "0.4941367", "0.48774207", "0.48521587", "0.4842773", "0.48405975", "0.48370117", "0.47781393", "0.47761074", "0.47733438", "0.47622862", "0.476...
0.0
-1
In order for all the other configurations to take effect there must be at least one decleration by the rabbitAdmin
@Bean public RabbitAdmin admin(ConnectionFactory connectionFactory) { logger.info("Kicking off Declarations"); RabbitAdmin rabbitAdmin = new RabbitAdmin(connectionFactory); /* * *********************IMPORTANT******************************** * * None of the other declarations take effect unless at least one * declaration is executed by RabbitAdmin. * * *********************IMPORTANT******************************** */ rabbitAdmin.declareExchange(topicExchange()); return new RabbitAdmin(connectionFactory); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tprotected void validateConfiguration() {\n\n\t\tsuper.validateConfiguration();\n\n\t\tAssert.state(\n\t\t\t\t!(getAcknowledgeMode().isAutoAck() && getTransactionManager() != null),\n\t\t\t\t\"The acknowledgeMode is NONE (autoack in Rabbit terms) which is not consistent with having an \"\n\t\t\t\t\t\t+...
[ "0.6181239", "0.6145979", "0.60686535", "0.5866051", "0.58380526", "0.5819316", "0.5803859", "0.5771466", "0.57652146", "0.571393", "0.56476265", "0.5594197", "0.5593568", "0.55763227", "0.5560751", "0.55376655", "0.5535459", "0.55329543", "0.5529645", "0.5520608", "0.5520474...
0.59456253
3
private constructor for the SettingsWindow class.
private SettingsWindow() { loadData(); createListeners(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SettingsWindow()\n {\n House.seed = System.currentTimeMillis();\n initWindow();\n showWindows();\n }", "public Settings() {\n initComponents();\n }", "public Settings() {\n initComponents();\n }", "private Settings() { }", "private Settings() {}", "public SettingsPan...
[ "0.82723075", "0.77874386", "0.77874386", "0.7678926", "0.7665038", "0.74947155", "0.74775773", "0.7346051", "0.73008037", "0.7259311", "0.7205227", "0.71077645", "0.7101889", "0.70955503", "0.6964701", "0.69579834", "0.6868823", "0.6823173", "0.6816366", "0.68073803", "0.675...
0.8744482
0
Returns the SettingsWindow, will create one if there is none.
public static synchronized void getSettingsWindow() { if (WINDOW == null) { WINDOW = new JFrame("Settings"); WINDOW.setContentPane(new SettingsWindow().settingsPanel); WINDOW.setDefaultCloseOperation(JFrame.HIDE_ON_CLOSE); WINDOW.pack(); } WINDOW.setVisible(true); WINDOW.requestFocus(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private SettingsWindow() {\n loadData();\n createListeners();\n }", "public static UISettings getShadowInstance() {\n Application application = ApplicationManager.getApplication();\n return application != null ? getInstance() : new UISettings();\n }", "public SettingsWindow()\n {\n ...
[ "0.6849998", "0.6836359", "0.6580317", "0.65514064", "0.6420975", "0.62767535", "0.62634075", "0.62191546", "0.61740094", "0.6162664", "0.6142389", "0.6108356", "0.6095771", "0.59891665", "0.5987086", "0.5987086", "0.5961905", "0.5913773", "0.5879011", "0.58645093", "0.585905...
0.78779465
0
Adds button functionality to the GUI
private void createListeners() { btGeneralSave.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { saveGeneralData(); } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void addButton_actionPerformed(ActionEvent e) {\n addButton();\n }", "private void createButton() {\n this.setIcon(images.getImageIcon(fileName + \"-button\"));\n this.setActionCommand(command);\n this.setPreferredSize(new Dimension(width, height));\n this.setMaximumSize(new Dimension...
[ "0.7696044", "0.74146146", "0.7397237", "0.73509187", "0.7337135", "0.71889037", "0.7155358", "0.7095997", "0.70403063", "0.70317525", "0.70205903", "0.698512", "0.6947725", "0.6942889", "0.6931416", "0.6916396", "0.69111705", "0.68991643", "0.687677", "0.68693024", "0.686608...
0.0
-1
Loads the Data for the GUI from the Settings class.
private void loadData() { //load general data Settings.loadSettings(); this.spCrawlTimeout.setValue(Settings.CRAWL_TIMEOUT / 1000); this.spRetryPolicy.setValue(Settings.RETRY_POLICY); this.spRecrawlInterval.setValue(Settings.RECRAWL_TIME / 3600000); this.spRecrawlCheckTime.setValue(Settings.RECRAWL_CHECK_TIME / 60000); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private SettingsWindow() {\n loadData();\n createListeners();\n }", "private void settings() {\n mainTitle = makeLabel(\"Settings\", true);\n add(mainTitle);\n add(content);\n add(diffSlider);\n add(colourChooser);\n add(mainB);//button to main menu\n ...
[ "0.6897466", "0.66846806", "0.6669453", "0.66071206", "0.660236", "0.659485", "0.658317", "0.65509635", "0.65463746", "0.6532988", "0.64682096", "0.64682096", "0.64682096", "0.64682096", "0.64682096", "0.64682096", "0.64682096", "0.6431186", "0.6353508", "0.62799317", "0.6279...
0.6586305
6
Saves the data currently in the GUI to the Settings class
private void saveGeneralData() { Settings.CRAWL_TIMEOUT = Integer.parseInt(spCrawlTimeout.getValue().toString()) * 1000; Settings.RETRY_POLICY = Integer.parseInt(spRetryPolicy.getValue().toString()); Settings.RECRAWL_TIME = Integer.parseInt(spRecrawlInterval.getValue().toString()) * 3600000; Settings.RECRAWL_CHECK_TIME = Integer.parseInt(spRecrawlCheckTime.getValue().toString()) * 60000; Settings.saveSettings(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void save() {\n // Convert the settings to a string\n String output = readSettings();\n \n try {\n // Make sure the file exists\n if (!settingsFile.exists()) {\n File parent = settingsFile.getParentFile();\n parent.mkdirs();\n ...
[ "0.7833475", "0.78271145", "0.7686139", "0.7515994", "0.74719745", "0.7469128", "0.74208015", "0.7276594", "0.72744024", "0.7239363", "0.7237908", "0.7233078", "0.72190934", "0.719354", "0.71588624", "0.7105278", "0.70981866", "0.70903265", "0.7035804", "0.6968239", "0.690494...
0.6795813
24
check that all attributes have a type
public static void check(Model model) { model.classes.values().forEach(aClass -> { if (aClass.name.equals("Node")) { //noop } else { aClass.properties().forEach(o -> { if (o instanceof Attribute) { Attribute attribute = (Attribute) o; if (attribute.type() == null) { throw new RuntimeException("Untyped attribute " + attribute.name() + " contained in " + attribute.parent()); } if (reserved.contains(((Attribute) o).name())) { throw new RuntimeException("Usage of a reserved attribute name : " + ((Attribute) o).name()); } } else if (o instanceof Constant) { final Constant constant = (Constant) o; if (constant.type().equals("Task") && constant.value() != null) { checkTask(constant.value()); } } }); } }); model.constants.values().forEach(constant -> { if (constant.type().equals("Task") && constant.value() != null) { checkTask(constant.value()); } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "boolean hasAttributes();", "boolean hasAttributes();", "boolean isAttribute();", "@Override\n\tpublic boolean checkTypes() {\n\t\treturn false;\n\t}", "public void getAllAttributeTypes(List<IAttributeType<?>> all);", "public void getAllAttributeTypes(List<IAttributeType<?>> all, ItemFilter<IAttributeType...
[ "0.65653914", "0.65653914", "0.653576", "0.65158045", "0.6507743", "0.63678426", "0.63242495", "0.62987614", "0.6262925", "0.62555474", "0.6183513", "0.6052635", "0.6052635", "0.6052635", "0.6052635", "0.6052635", "0.6052635", "0.6052635", "0.6052635", "0.6052635", "0.6052635...
0.54584676
98
Anagram mean same characters in both words ,but word meaning is different
public static void main(String[] args) { String str="army"; String str1="mary"; char arr[]=str.toLowerCase().toCharArray(); char arr1[]=str1.toLowerCase().toCharArray(); Arrays.sort(arr); Arrays.sort(arr1); if(Arrays.equals(arr, arr1)) { System.out.println("given strings are anagrams"); } else { System.out.println("given strings are not anagram"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private static boolean anagramWord(String first, String second) {\n\t\tif(first.length()!=second.length())return false;\n\t\tint matches = 0;\n\t\tchar[] a = first.toLowerCase().toCharArray();\n\t\tchar[] b = second.toLowerCase().toCharArray();\n\t\tfor(int i=0; i<a.length; i++){\n\t\t\tfor(int j=0; j<b.length; j+...
[ "0.80441046", "0.79066217", "0.778575", "0.75336134", "0.7488703", "0.744725", "0.7354093", "0.73459077", "0.73161256", "0.72224367", "0.71557575", "0.71444964", "0.71210593", "0.71180385", "0.70957947", "0.7068624", "0.7058004", "0.7026279", "0.70243555", "0.7022227", "0.700...
0.72661036
9
/ to deal with editBox (TYPE)
public void typeByXpath (String locator, String value){ driver.findElement(By.xpath(locator)).clear(); driver.findElement (By.xpath(locator)).sendKeys(value); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void edit() {\n\n\t}", "public void correcto( Editor<Tipo> editor );", "@Override\r\n\tpublic void edit() {\n\t\t\r\n\t}", "void onEditClicked();", "@Override\n public void checkEditing() {\n }", "private Widget editableCell(final FieldData fd, String factType) {\n\n\t\treturn ScenarioWidge...
[ "0.6632481", "0.6486794", "0.6442824", "0.6405429", "0.63856685", "0.6361216", "0.63244694", "0.6308397", "0.61849", "0.6182791", "0.61818635", "0.6143622", "0.61337185", "0.6072494", "0.6051686", "0.6025715", "0.5988627", "0.59582233", "0.5953488", "0.59497815", "0.58990437"...
0.0
-1
/ to deal with CLICK
public void clickByXpath (String locator){ driver.findElement (By.xpath(locator)).click(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tprotected void OnClick() {\n\t\t\n\t}", "@Override\n\tpublic void onClick() {\n\t\t\n\t}", "@Override\n\t\t\t\t\tpublic void mouseClicked(MouseEvent e) {\n\t\t\t\t\t}", "@Override\r\n\t\t\t\tpublic void onClick() {\n\r\n\t\t\t\t}", "@Override\r\n\t\t\t\tpublic void onClick() {\n\r\n\t\t\t\t}",...
[ "0.75400364", "0.74837667", "0.74083257", "0.73963845", "0.73963845", "0.7349526", "0.73253965", "0.7319428", "0.7319428", "0.73149496", "0.73149496", "0.73149496", "0.73149496", "0.73149496", "0.73149496", "0.73149496", "0.73149496", "0.73149496", "0.73149496", "0.73149496", ...
0.0
-1
Called when the activity is first created.
@Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void onActivityCreated(Bundle savedInstanceState) {\n\t\tsuper.onActivityCreated(savedInstanceState);\n\t\tinit();\n\t}", "@Override\r\n\tpublic void onActivityCreated(Bundle savedInstanceState) {\n\t\tsuper.onActivityCreated(savedInstanceState);\r\n\t}", "@Override\n\tpublic void onActivit...
[ "0.791686", "0.77270156", "0.7693263", "0.7693263", "0.7693263", "0.7693263", "0.7693263", "0.7693263", "0.7637394", "0.7637394", "0.7629958", "0.76189965", "0.76189965", "0.7543775", "0.7540053", "0.7540053", "0.7539505", "0.75269467", "0.75147736", "0.7509639", "0.7500879",...
0.0
-1
Creates a Toast (temporary message) when button is clicked. Note that there is a version of Toast.makeText that takes an id (R.string.blah) instead of a String. However, it is important to know how to turn an ID from res/values/strings into a String, for use in Java code.
public void showToast(View clickedButton) { String greetingText = getString(R.string.greeting_text); Toast tempMessage = Toast.makeText(this, greetingText, Toast.LENGTH_SHORT); tempMessage.show(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void onClick(View v) {\n String toastText = \"Hello World\";\n\n // This is how long we want to show the toast\n int duration = Toast.LENGTH_SHORT;\n\n // Get the context\n Context context = getApplicationConte...
[ "0.73601675", "0.7047813", "0.6873726", "0.6836748", "0.67542493", "0.66618973", "0.6659353", "0.6654861", "0.6641362", "0.662957", "0.653043", "0.653043", "0.64536023", "0.64397687", "0.63940996", "0.6356811", "0.6329284", "0.6329284", "0.63277996", "0.63272464", "0.6314362"...
0.76820093
0
Don't care. Just use whatever you've got.
@Override public void onStatusChanged(String s, int i, Bundle bundle) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "public void use()\n\t{\n\t}", "public abstract String use();", "void use();", "private stendhal() {\n\t}", "public void smell() {\n\t\t\n\t}", "public void reuse() {}", "private void strin() {\n\n\t}", "@Override\n\tpublic void jugar() {\n\t\t\n\...
[ "0.65163565", "0.6335975", "0.62639934", "0.6173157", "0.6078688", "0.6057619", "0.5940141", "0.5850578", "0.5723568", "0.5721023", "0.5721023", "0.5705576", "0.5696539", "0.568961", "0.568961", "0.5679322", "0.5654895", "0.5654836", "0.56115127", "0.5581887", "0.55740947", ...
0.0
-1
Don't care. Just use whatever you've got.
@Override public void onProviderEnabled(String s) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "public void use()\n\t{\n\t}", "public abstract String use();", "void use();", "private stendhal() {\n\t}", "public void smell() {\n\t\t\n\t}", "public void reuse() {}", "private void strin() {\n\n\t}", "@Override\n\tpublic void jugar() {\n\t\t\n\...
[ "0.65163106", "0.6334918", "0.62627953", "0.61716765", "0.60784775", "0.60555434", "0.5940251", "0.585019", "0.5722782", "0.5719769", "0.5719769", "0.5704763", "0.5695071", "0.5688851", "0.5688851", "0.56795484", "0.5654334", "0.5653295", "0.56103444", "0.55809426", "0.557403...
0.0
-1
Don't care. Just use whatever you've got.
@Override public void onProviderDisabled(String s) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "public void use()\n\t{\n\t}", "public abstract String use();", "void use();", "private stendhal() {\n\t}", "public void smell() {\n\t\t\n\t}", "public void reuse() {}", "private void strin() {\n\n\t}", "@Override\n\tpublic void jugar() {\n\t\t\n\...
[ "0.65163106", "0.6334918", "0.62627953", "0.61716765", "0.60784775", "0.60555434", "0.5940251", "0.585019", "0.5722782", "0.5719769", "0.5719769", "0.5704763", "0.5695071", "0.5688851", "0.5688851", "0.56795484", "0.5654334", "0.5653295", "0.56103444", "0.55809426", "0.557403...
0.0
-1
Constructs a new MergingResourceWrapper backed by the given resources. If primaryResource is null, secondaryResource becomes effective primaryResource.
public MergingResourceWrapper(Resource primaryResource, Resource secondaryResource) { super(primaryResource != null ? primaryResource : secondaryResource); if (primaryResource == null && secondaryResource == null) { throw new IllegalArgumentException("must wrap at least one resource"); } this.primaryResource = primaryResource != null ? primaryResource : secondaryResource; this.secondaryResource = primaryResource != null ? secondaryResource : null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public Resource getChild(String relPath) {\n\n if (secondaryResource != null) {\n\n if (childCache.containsKey(relPath)) {\n return childCache.get(relPath);\n }\n\n Resource retVal = null;\n Resource secondaryChild = secondaryResource...
[ "0.58697575", "0.5673236", "0.5241216", "0.5070621", "0.5023477", "0.49731624", "0.49007362", "0.47752348", "0.47467282", "0.4740289", "0.47259966", "0.47038004", "0.4652216", "0.46202642", "0.45579714", "0.44507408", "0.44061866", "0.4403017", "0.4371536", "0.43561712", "0.4...
0.8046774
0
Adaptor override to provide merging. If the type to adapt to is Map or ValueMap, a MergedValueMap is returned for the primaryResource and secondaryResource;
@Override public <Type> Type adaptTo(Class<Type> type) { if (secondaryResource != null && (type == ValueMap.class || type == Map.class)) { if (properties != null) { return (Type) properties; } ValueMap contentMap = primaryResource.adaptTo(ValueMap.class); ValueMap assetMap = secondaryResource.adaptTo(ValueMap.class); if (type == ValueMap.class) { properties = new MergingValueMap(contentMap, assetMap); } else if (type == Map.class) { properties = new MergingValueMap(contentMap != null ? new ValueMapDecorator(contentMap) : ValueMap.EMPTY, assetMap != null ? new ValueMapDecorator(assetMap) : ValueMap.EMPTY); } return (Type) properties; } return super.adaptTo(type); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public MergingResourceWrapper(Resource primaryResource, Resource secondaryResource) {\n super(primaryResource != null ? primaryResource : secondaryResource);\n if (primaryResource == null && secondaryResource == null) {\n throw new IllegalArgumentException(\"must wrap at least one resource...
[ "0.6281084", "0.593066", "0.5903443", "0.58796823", "0.5853835", "0.552175", "0.5468184", "0.54498315", "0.53926814", "0.53501886", "0.5321403", "0.5188782", "0.5115377", "0.5058523", "0.50307226", "0.49859685", "0.49652076", "0.4942715", "0.49354082", "0.4919197", "0.4899942...
0.7526102
0
Returns a merged child resource. If both the primaryResource and secondaryResource has the child, it is returned as a MergingResourceWrapper. If only the primaryResource or secondaryResource has the child, the child is returned as an unwrapped resource. If neither the primaryResource or secondaryResource has the child, null is returned;
@Override public Resource getChild(String relPath) { if (secondaryResource != null) { if (childCache.containsKey(relPath)) { return childCache.get(relPath); } Resource retVal = null; Resource secondaryChild = secondaryResource.getChild(relPath); Resource primaryChild = primaryResource.getChild(relPath); if (secondaryChild != null && primaryChild != null) { retVal = new MergingResourceWrapper(primaryChild, secondaryChild); } else if (secondaryChild != null && primaryChild == null) { retVal = secondaryChild; } else { retVal = primaryChild; } childCache.put(relPath, retVal); return retVal; } return super.getChild(relPath); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public MergingResourceWrapper(Resource primaryResource, Resource secondaryResource) {\n super(primaryResource != null ? primaryResource : secondaryResource);\n if (primaryResource == null && secondaryResource == null) {\n throw new IllegalArgumentException(\"must wrap at least one resource...
[ "0.71325785", "0.5886686", "0.54621714", "0.54243594", "0.53997016", "0.5122725", "0.50478613", "0.501198", "0.4945191", "0.48647955", "0.47593564", "0.4758883", "0.4742081", "0.46904477", "0.4615796", "0.46107772", "0.4541739", "0.45098996", "0.4475025", "0.44524994", "0.445...
0.73911905
0
Returns the primary resource wrapped by this object.
public Resource getPrimaryResource() { return primaryResource; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic IResource getCorrespondingResource() {\n\t\treturn getUnderlyingResource();\n\t}", "Resource getResource() {\n\t\treturn resource;\n\t}", "protected Resource getResource() {\n return resource;\n }", "public Resource getResource() {\n return resource;\n }", "public Re...
[ "0.7333313", "0.6890191", "0.6835682", "0.657472", "0.65410304", "0.65202564", "0.6519022", "0.65181637", "0.6355927", "0.6258652", "0.62483406", "0.61909777", "0.61838186", "0.6167041", "0.61609465", "0.61514926", "0.6147744", "0.6130791", "0.61022466", "0.6034271", "0.59727...
0.808226
0
Returns the primary resource wrapped by this object.
public Resource getSecondaryResource() { return secondaryResource; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Resource getPrimaryResource() {\n return primaryResource;\n }", "@Override\n\tpublic IResource getCorrespondingResource() {\n\t\treturn getUnderlyingResource();\n\t}", "Resource getResource() {\n\t\treturn resource;\n\t}", "protected Resource getResource() {\n return resource;\n }"...
[ "0.808226", "0.7333313", "0.6890191", "0.6835682", "0.657472", "0.65410304", "0.65202564", "0.6519022", "0.65181637", "0.6355927", "0.6258652", "0.62483406", "0.61909777", "0.6167041", "0.61609465", "0.61514926", "0.6147744", "0.6130791", "0.61022466", "0.6034271", "0.5972754...
0.61838186
13
public static int vertices =0; Here we are calculating min and max values for each unmatched edge's u
public void reduce(IntWritable key, Iterable<Text> values, Context output) throws IOException, InterruptedException { double min=999;double max=0; for(Text value:values) { String s[]=value.toString().split("\t"); double n=Double.parseDouble(s[1]); if(min>n)min=n; if(max<n)max=n; ver[key.get()][0]=min; ver[key.get()][1]=max; output.write(key, value); } // vertices++; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void calculateMinMaxPositions() {\n boundingVolume = null;\n if ( minMax == null ) {\n minMax = new double[6];\n\n double minX = Double.MAX_VALUE;\n double minY = Double.MAX_VALUE;\n double minZ = Double.MAX_VALUE;\n double maxX = -Double...
[ "0.6322931", "0.6109", "0.60410017", "0.5976093", "0.59297484", "0.5908942", "0.5887816", "0.58424413", "0.5823205", "0.58226115", "0.57975554", "0.579148", "0.57520133", "0.5660877", "0.565323", "0.56152886", "0.56071955", "0.554233", "0.55407363", "0.55372345", "0.5534431",...
0.0
-1
could alternatively use a HashSet (if I give nodes unique IDs)
public Node(String data) { this.data = data; status = Visited.NEW; neighbors = new ArrayList(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Set<Node<K, V>> entrySet();", "public HashSet<N> getNodes()\r\n/* 99: */ {\r\n/* 100:182 */ assert (checkRep());\r\n/* 101: */ \r\n/* 102:184 */ return new HashSet(this.map.keySet());\r\n/* 103: */ }", "public MyMultiset() {\n\t\tthis.set = new HashSet<Node>();\n\t}", "private Set<E...
[ "0.6877555", "0.68212855", "0.66717225", "0.6610874", "0.63983226", "0.6222534", "0.61995", "0.6101435", "0.60953856", "0.6086057", "0.6072773", "0.6049505", "0.6047629", "0.5982902", "0.59720737", "0.5949901", "0.59420335", "0.59339875", "0.59146184", "0.5906746", "0.5895684...
0.0
-1
not really needed protected int activeCycles = 0;
public FluoriteListener() { idleTimer = new IdleTimer(); EHEventRecorder eventRecorder = EHEventRecorder.getInstance(); // EventRecorder eventRecorder = EventRecorder.getInstance(); // eventRecorder.addCommandExecutionListener(this); // eventRecorder.addDocumentChangeListener(this); // eventRecorder.addRecorderListener(this); eventRecorder.addEclipseEventListener(this); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getCycles();", "static long GetCycleCount() {\n\t\treturn System.currentTimeMillis();\n\t}", "public int getCycle() {\n return cycle;\n }", "GlobalVariable getCycleCounterVariable();", "public final long getCycles() {\r\n return this.cycles;\r\n }", "public static int getNbCycle(...
[ "0.7716578", "0.7321053", "0.68959135", "0.66459334", "0.6639804", "0.65654856", "0.62928", "0.621635", "0.6172807", "0.6165624", "0.60916775", "0.6079226", "0.6049116", "0.60455716", "0.60221314", "0.60215366", "0.60141665", "0.60085535", "0.5927327", "0.5916294", "0.5902431...
0.0
-1
TODO Autogenerated method stub
@Override public void documentChangeFinalized(long aTimestamp) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
protected int idleCycles = 0; protected int activeCycles;
public IdleTimer() { inActivitySession = false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getCycles();", "static long GetCycleCount() {\n\t\treturn System.currentTimeMillis();\n\t}", "GlobalVariable getCycleCounterVariable();", "public int getNumIdle();", "public long getIdle() { return idle; }", "@Override\n\tpublic void idleCheck() {\n\t\t\n\t}", "@Override\n\tpublic void idleC...
[ "0.6913379", "0.6672096", "0.6637535", "0.6573881", "0.65304166", "0.6429389", "0.6429389", "0.6296111", "0.62880147", "0.62507164", "0.61995983", "0.6074229", "0.6058087", "0.6016773", "0.5933133", "0.5931446", "0.5930882", "0.58933175", "0.58002234", "0.57885736", "0.577120...
0.5716198
24
This thread is constantly polling because a sleeping process cannot be interrupted. Can have a thread wait on a timeout and be notified with each command, but is probbaly more context switches than just sleeping for some period.
public void run() { activityStartTimestamp = startTimestamp + lastCommandTimestamp; // System.out.println("Session started"); ActivitySessionStarted.newCase(this, activityStartTimestamp); // Date startDate = new Date(); // make this global also startDate = new Date(); // make this global also // Date endDate = new Date(); // in case we get no more commands or we terminate early // int idleCycles = 0; // make this a global so eclipse termination can access it // make this global also endDate = new Date(); // in case we get no more commands or we terminate early idleCycles = 0; // make this a global so eclipse termination can access it while(idleCycles < IDLE_CYCLES_THRESHOLD) { // while(idleCycles < 10) { idleLastCycle = true; try { // Thread.sleep(/*60 * */ 1000); // why is 60 removed? Thread.sleep(IDLE_CYCLE_GRANULARITY); // why is 60 removed? } catch (Exception ex) {} if(idleLastCycle) { idleCycles++; IdleCycleDetected.newCase(this, startTimestamp + lastCommandTimestamp, idleCycles); } else { endDate = new Date(); // this seems wrong, we have not ended session // actually it is correct as this is ths last cycle in which the session was active // idleCycles = 0; initActivitySession(); } } // Date endDate = new Date(); // current time // // inActivitySession = false; // sessionEnded(startDate, endDate); recordEndSession(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void sleep();", "void sleep();", "public void testInterruptedTimedPoll() {\n Thread t = new Thread(new Runnable() {\n public void run() {\n try {\n SynchronousQueue q = new SynchronousQueue();\n assertNull(q.poll(SHORT_DELAY...
[ "0.62623227", "0.62623227", "0.6122593", "0.61176205", "0.60975695", "0.6086605", "0.60747516", "0.60713285", "0.6070835", "0.6049038", "0.60452276", "0.6029674", "0.60264856", "0.60228205", "0.596702", "0.5966006", "0.5933831", "0.59323806", "0.592779", "0.59255", "0.5917372...
0.0
-1
Date endDate = new Date(); // current time
public void recordEndSession() { inActivitySession = false; activityEndTimestamp = startTimestamp + lastCommandTimestamp; long ativityDuration = activityEndTimestamp - activityStartTimestamp; ActivitySessionEnded.newCase(this, activityEndTimestamp, ativityDuration); Date aStartDate = new Date(activityStartTimestamp); Date anEndDate = new Date (activityEndTimestamp); System.out.println("Start dates:" + aStartDate + "," + startDate); System.out.println("End dates:" + anEndDate + "," + endDate); sessionEnded(startDate, endDate); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Date getEndTimeDate() {\n return endTimeDate;\n }", "public abstract Date getEndTime();", "Date getEndDate();", "Date getEndDate();", "public Date getEndTime() {\n return endTime;\n }", "public Date getEndTime() {\n return endTime;\n }", "public Date getEndTime() {\...
[ "0.7103055", "0.7086208", "0.69465756", "0.69465756", "0.69163543", "0.69163543", "0.69163543", "0.6872843", "0.6872843", "0.6872843", "0.6872843", "0.68654346", "0.68654346", "0.68559194", "0.68559194", "0.6822423", "0.67939645", "0.6761343", "0.67452407", "0.6697186", "0.66...
0.0
-1
TODO Autogenerated method stub
@Override public void timestampReset(long aStartTimestamp) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
/ Called when the scheduler initializes commands
protected void initialize() { // set the target for the PID subsystem Robot.minipidSubsystem.setSetpoint(90); // set the minimum and maximum output limits for the PID subsystem Robot.minipidSubsystem.setOutputLimits(-80, 80); // Disable safety checks on drive subsystem Robot.driveSubsystem.robotDrive.setSafetyEnabled(false); Robot.camera.setBrightness(0); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected abstract void scheduler_init();", "public void robotInit() {\n\t\toi = new OI();\n // instantiate the command used for the autonomous period\n }", "protected void initializeCommands() {\n\t\t\r\n\t\tcommands.add(injector.getInstance(Keys.inputQuestionCommand));\r\n\t\tcommands.add(injector....
[ "0.7451116", "0.6969035", "0.6950377", "0.69043624", "0.6897571", "0.68861306", "0.68845296", "0.68625647", "0.68056864", "0.68054444", "0.6803853", "0.6803105", "0.6803105", "0.6803105", "0.6803105", "0.6803105", "0.6803105", "0.6803105", "0.6803105", "0.6803105", "0.6803105...
0.0
-1
/ This routine is called by the scheduler on a regular basis so be careful when adding code to not cause blocking issues or delays as this will affect the performance of the robot.
protected void execute() { // Get output from PID and dvide by 4 double output = Robot.minipidSubsystem.getOutput(Robot.gyroSubsystem.GyroPosition(), 90) * 0.25; // limit output to 25% in either direction if (output > 25) output = 25; else if (output < -25) output = -25; // convert output to a value the drive subsystem can use (-1 to 1) output /= 100; // drive the robot, only providing the turn speed Robot.driveSubsystem.robotDrive.arcadeDrive(0, output); // Robot.driveSubsystem.tankDrive(-output, output); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void robotPeriodic() {\n }", "@Override\n public void robotPeriodic() {\n }", "@Override\n public void robotPeriodic() {\n }", "@Override\n public void robotPeriodic() {\n }", "@Override\n public void robotPeriodic() {\n }", "@Override\n public void robotPeriodic() {\n }", ...
[ "0.70950913", "0.70950913", "0.70950913", "0.70950913", "0.70950913", "0.70950913", "0.698812", "0.698812", "0.65521044", "0.6521747", "0.6521395", "0.65180826", "0.6506085", "0.648395", "0.645867", "0.64474523", "0.64432645", "0.6436221", "0.6436221", "0.6436221", "0.6435756...
0.0
-1
/ This is also called by the scheduler on a regular basis and will cause the robot to cease to function for the duration of the match if true is returned. Return true if the robot work is finished Return false if the robot is not finished
protected boolean isFinished() { // get the current angle from the gyro double currentAngle = Robot.gyroSubsystem.GyroPosition(); // see if we are within 2 degrees of the target angle (90 degrees) if (Math.abs(currentAngle - 90) <= 2) { // we have hit our goal of 90, end auto program return true; } else { // we are not quite there yet, keep going return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected boolean isFinished() {\n \tif(timer.get()>.7)\n \t\treturn true;\n \tif(Robot.gearX==0)\n \t\treturn true;\n return (Math.abs(173 - Robot.gearX) <= 5);\n }", "protected boolean isFinished() {\n //return !RobotMap.TOTE_SWITCH.get();\n \treturn false;\n }", "protected...
[ "0.77990574", "0.77670395", "0.7742199", "0.76799935", "0.7620455", "0.76136804", "0.76087373", "0.75904506", "0.7573437", "0.75587976", "0.7475847", "0.7465323", "0.74397206", "0.74275213", "0.74241245", "0.7417663", "0.74139357", "0.7406421", "0.7402047", "0.73515004", "0.7...
0.7488119
10
/ This is called when the match ends or if isFinished returns true. all systems should be disabled at this point.
protected void end() { // we are ending the, stop moving the robot Robot.driveSubsystem.arcadeDrive(0, 0); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n protected boolean isFinished() {\n return false;\r\n }", "@Override\n protected boolean isFinished() \n {\n return false;\n }", "@Override\n protected boolean isFinished() {\n return false;\n }", "@Override\n protected boolean isFinished() {\n ...
[ "0.68065155", "0.67469037", "0.674513", "0.674513", "0.67423", "0.67423", "0.67256284", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.671753", "0.6...
0.0
-1
/ This is called if for some reason the normal operation of the robot is cancelled by an external action.
protected void interrupted() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected void finalAction(){\n Robot.stop();\n requestOpModeStop();\n }", "public void cancel(){\n cancelled = true;\n }", "public void cancel() {\n\t\tcancelled = true;\n\t}", "public abstract boolean cancel();", "protected boolean reallyCancel() throws Exception { retu...
[ "0.7222925", "0.7124642", "0.6998528", "0.6960696", "0.6943702", "0.68907124", "0.68756455", "0.6841804", "0.6836578", "0.68335664", "0.68331033", "0.68331033", "0.68331033", "0.68319726", "0.68316716", "0.682359", "0.6819797", "0.6819797", "0.6819797", "0.6819797", "0.681979...
0.0
-1
Protected constructor for JSON serialization.
protected DateFieldMetadata() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private JSONHelper() {\r\n\t\tsuper();\r\n\t}", "public JSONUtils() {\n\t\tsuper();\n\t}", "private JsonUtils() {\n\t\tsuper();\n\t}", "public JsonFactory() { this(null); }", "public JsonRequestSerializer() {\n this(JNC.GSON);\n }", "public ClaseJson() {\n }", "private JsonUtils()\r\n {...
[ "0.7922768", "0.7544877", "0.7534503", "0.74213886", "0.7403433", "0.73829734", "0.73770386", "0.72506285", "0.7167426", "0.7158777", "0.7120367", "0.7069752", "0.70685524", "0.7015415", "0.7002678", "0.6913897", "0.6872082", "0.6841221", "0.6782336", "0.67653865", "0.6754830...
0.0
-1
This util function will format the string which seperate by comma
public static String formatCommaString(String text){ String[] arr = text.split(","); String result=""; for(String s: arr){ if(!"".equalsIgnoreCase(s.trim())){ result+=s+","; } } if(result.endsWith(",")){ result=result.substring(0,result.length()-1); } return result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private String commaDelimited(String strs[]) {\n StringBuffer sb = new StringBuffer();\n if (strs.length > 0) {\n sb.append(Utils.encToURL(strs[0]));\n for (int i=1;i<strs.length;i++) sb.append(\",\" + Utils.encToURL(strs[i]));\n }\n return sb.toString();\n }", "public static String buildC...
[ "0.70399773", "0.65055126", "0.63944954", "0.62887686", "0.62730604", "0.6249649", "0.6230064", "0.6206203", "0.6106288", "0.60533077", "0.60408413", "0.60081697", "0.5996798", "0.5971386", "0.5951767", "0.5858682", "0.58340764", "0.582909", "0.5790568", "0.5751137", "0.57478...
0.74489135
0
Sets the fill grade.
public void setFillLevel(final double fill) { _fillGrade = fill; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setGrade() {\n \tthis.grade = trkMdl.getBlock(this.lineColor,this.currentBlock).getGrade();\n \t//int currentBlockID = position.getCurrentBlock();\n \t//Block current = trackModel.getBlock(curentBlockID);\n \t//grade = currentBlock.getGrade();\n }", "public void setGrade (double grade)...
[ "0.7129434", "0.6978794", "0.68783563", "0.67775565", "0.6762995", "0.6762995", "0.6762995", "0.6762995", "0.6534143", "0.6422359", "0.6417921", "0.63625497", "0.63472223", "0.6327754", "0.6316481", "0.63080317", "0.63024926", "0.62976515", "0.6269397", "0.6240697", "0.615233...
0.8102897
0
Gets the fill grade.
public double getFill() { return _fillGrade; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Grade grade() {\n ////\n return Grade.average(grades.values());\n }", "public double grade() {\n\n return -1;\n }", "public String getGrade() {\n\t\treturn Grade;\n\t}", "@Override\n\tpublic int getGrade() {\n\t\treturn model.getGrade();\n\t}", "@Override\r\n public dou...
[ "0.6822902", "0.67961246", "0.67903966", "0.6763642", "0.67400676", "0.67287785", "0.67025906", "0.66879517", "0.6655862", "0.66405106", "0.6632836", "0.6607958", "0.65940887", "0.65369606", "0.6405736", "0.63940233", "0.6377978", "0.6366488", "0.6309324", "0.6275716", "0.621...
0.8875838
0
Sets the rotation angle.
public void setRotationAngle(final double rotationAngle) { _rotationAngle = rotationAngle; _polylineDecoration.setRotation(Math.toRadians(_rotationAngle)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setRotationAngle(double angle) {\n if (angle >= MIN_ROTATION_ANGLE && angle <= MAX_ROTATION_ANGLE) {\n rotationAngle = angle;\n }\n }", "public void setAngle(final float angle);", "void setAngle(double angle);", "public void setRotation(float angle) {\n \t\tthis.angle ...
[ "0.809519", "0.8062537", "0.8034735", "0.79757065", "0.79019994", "0.78355855", "0.7828996", "0.77966046", "0.7760854", "0.7726417", "0.7720127", "0.76900035", "0.767753", "0.7655309", "0.75866514", "0.75316405", "0.75174385", "0.7484579", "0.7431928", "0.74104315", "0.739394...
0.75853896
15
Gets the rotation angle.
public double getRotationAngle() { return _rotationAngle; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public double getAngle() {\n synchronized (this.angleLock) {\n return this.movementComposer.getOrientationAngle();\n }\n }", "public double getRotationAngleInRadians() {\n return Math.toRadians(rotationAngle);\n }", "public float getRotationAngle() {\n return this.m...
[ "0.83617544", "0.8321472", "0.8149913", "0.80506265", "0.7909737", "0.7888285", "0.78069675", "0.77893585", "0.777363", "0.777363", "0.7739106", "0.7727494", "0.7727494", "0.77255476", "0.77203625", "0.7704394", "0.76930785", "0.7681708", "0.76763487", "0.7670231", "0.7642721...
0.82710445
2
Sets the transparent state of the background.
public void setTransparent(final boolean transparent) { _transparent = transparent; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setTransparent(boolean a) {\n\t\tthis.transparent = a;\n\t}", "public void setBackgroundTranslucence(float alpha) {\n\t\tthis.bgAC = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, alpha);\n\t}", "protected void setScrimAlpha(float alpha) {\n mShowScrim = alpha > 0f;\n mRenderer.g...
[ "0.6638658", "0.6566992", "0.6504804", "0.64314955", "0.62922496", "0.6217981", "0.6205939", "0.6159407", "0.6151275", "0.6099531", "0.59014255", "0.5900722", "0.5848134", "0.5837283", "0.58227295", "0.5808302", "0.5806342", "0.57972157", "0.5774113", "0.57427764", "0.5730659...
0.7016982
0
Gets the transparent state of the background.
public boolean getTransparent() { return _transparent; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getTransparency() {\n return Color.TRANSLUCENT;\n }", "protected int getColor() {\n return Color.TRANSPARENT;\n }", "protected boolean getTransparent() {\n\treturn isTransparent;\n }", "public BufferedImage getBackground() {\n BufferedImage background = new BufferedIm...
[ "0.6610662", "0.6581616", "0.65387726", "0.6419712", "0.6406946", "0.6375726", "0.6331396", "0.63214916", "0.6301704", "0.6262627", "0.6230362", "0.6150271", "0.61094993", "0.6078013", "0.6070737", "0.6070125", "0.6050176", "0.6033182", "0.603224", "0.601822", "0.60088843", ...
0.70929134
0
This method adds a new node to the LinkedList
public void add(ListNode newNode) { if (length == 0) { firstNode=newNode; } else { ListNode currentNode; ListNode previousNode = null; currentNode = firstNode; while(currentNode!=null) { previousNode = currentNode; currentNode = currentNode.next; } currentNode = newNode; previousNode.next = currentNode; } length++; }
{ "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 add(Node newNode) {\r\n\t\tif (this.size() == 0) {\r\n\t\t\thead = newNode;\r\n\t\t\ttail = newNode;\r\n\t\t}else {\r\n\t\t\ttail.setNext(n...
[ "0.7895373", "0.7256669", "0.72439986", "0.72357106", "0.71900666", "0.70915574", "0.70700973", "0.7057491", "0.70306957", "0.7007064", "0.6985194", "0.69318134", "0.6920937", "0.691749", "0.6915058", "0.68879634", "0.6880775", "0.68758214", "0.6865268", "0.6864517", "0.68567...
0.74137145
1
This method Inserts node into a specific index in the LinkedList.
public void insertAtIndex(ListNode newNode, int intendedIndex) { if (length == 0) { newNode.next = firstNode.next; firstNode = newNode; } else if (intendedIndex != 0) { ListNode currentNode; ListNode previousNode; currentNode = this.getNodeAtIndex(intendedIndex); ListNode after = currentNode; previousNode = this.getNodeAtIndex(intendedIndex - 1); if (previousNode != null) { currentNode = newNode; previousNode.next = currentNode; currentNode.next = after; } else { System.out.println("Index is not valid!"); } } else if (intendedIndex == 0) { ListNode after; after = this.getNodeAtIndex(intendedIndex); firstNode = newNode; firstNode.next = after; } length++; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void insertAt(int index,int data){\n Node node =new Node();\n node.data=data;\n node.next=null;\n\n if (index == 0) {\n insertAtStart(data);\n }\n\n\nelse{\n Node n = head;\n for (int i=0; i < index-1;i++){\n n =n.next;\n }\n node.next =n.next;\n n.next = node;\n...
[ "0.78280926", "0.7765545", "0.7668145", "0.7601151", "0.7518405", "0.74334204", "0.7398514", "0.7353415", "0.7310058", "0.7291306", "0.7289898", "0.7265482", "0.7251414", "0.7229084", "0.7069026", "0.7055109", "0.70457935", "0.70306706", "0.70093507", "0.70016474", "0.6955499...
0.72082186
14
This method checks if the LinkedList is emtpy. It returns true if the bag is empty and false otherwise.
public boolean isLinkedListEmpty() { return(firstNode==null); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean isEmpty(){\n\t\treturn sizeOfLinkedList() == 0;\n\t}", "public boolean isEmpty() {\n\t\treturn(head == null);\t\t\n\t}", "public boolean isEmpty()\r\n\t {\r\n\t return head == null;\r\n\t }", "public boolean isEmpty()\n {\n return head == null;\n }...
[ "0.82265615", "0.7739114", "0.7737108", "0.7735662", "0.7721559", "0.7706232", "0.7701657", "0.7699804", "0.7699804", "0.7695575", "0.7683843", "0.7681283", "0.7681283", "0.7681283", "0.7681283", "0.7680471", "0.766417", "0.7654195", "0.7652234", "0.7648464", "0.76468587", ...
0.76387936
22
This method removes the node that contains the given "Storable" object.
public void remove(Comparable removedString) { ListNode currentNode = null; while (currentNode != null && removed == false) { returnifInTheFirstNode(); returnIfInTheCurrentNode(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void removeNode(NodeKey key);", "public boolean removeNode(Node n);", "public void removeGeneralEncapsulatedObject( org.ontoware.rdf2go.model.node.Node value) {\r\n\t\tBase.remove(this.model, this.getResource(), GENERALENCAPSULATEDOBJECT, value);\r\n\t}", "@Override\n public boolean remove(Object o) {\n ...
[ "0.58307713", "0.5721918", "0.57093006", "0.56907964", "0.5678929", "0.56477165", "0.56069463", "0.5593234", "0.5576298", "0.55603015", "0.55424285", "0.55287546", "0.5519504", "0.5516995", "0.5516616", "0.5504147", "0.550392", "0.54668254", "0.54648256", "0.5453632", "0.5452...
0.0
-1
This method clears the linkedList
public void clearLinkedList() { firstNode = null; length = 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void clearList() {\n\t\thead = null;\n\t\tlength = 0;\n\t}", "public void clearList() {\n\t\tthis.head = null;\n\t\tthis.tail = null;\n\t\tlength = 0;\n\t}", "public void clear ()\n {\n headNode.next = null;\n currentNode = headNode;\n size = 0;\n }", "public void clear() {\...
[ "0.8592266", "0.82664466", "0.81584996", "0.814652", "0.814597", "0.81432134", "0.81051534", "0.8052791", "0.7990205", "0.79727745", "0.79691386", "0.7949005", "0.79458326", "0.79436964", "0.79167277", "0.7856992", "0.7843267", "0.7842049", "0.78279465", "0.7813407", "0.78040...
0.8380722
1
This method returns true if any of the nodes in the LinkedList contains "value" for their data. Otherwise return false.
public boolean contains(Comparable value) { ListNode currentNode; currentNode = firstNode; while (currentNode != null) { if (currentNode.data.equals(value)) { return true; } else { currentNode = currentNode.next; } } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean containsValue(V value) {\r\n for (Node datum : data) {\r\n if (datum != null) {\r\n Node targetNode = datum;\r\n while (targetNode != null) {\r\n if (targetNode.value == value || targetNode.value.equals(value)) {\r\n ...
[ "0.80932266", "0.7392105", "0.73140955", "0.726488", "0.7213613", "0.7121381", "0.70232224", "0.69817173", "0.6825309", "0.6784568", "0.6722364", "0.6588937", "0.65777045", "0.65554535", "0.65420985", "0.6541202", "0.6467096", "0.6466332", "0.6439431", "0.643128", "0.64273447...
0.7624744
1
getter method that gets the size of the LinkedList.
public int returnSize() { return length; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int sizeOfLinkedList(){\n\t\treturn size;\n\t}", "@Override\n public int size() {\n\n Node nodePointer = listHead;\n int size = 0;\n while (nodePointer != null) {\n size += 1;\n nodePointer = nodePointer.next;\n }\n return size;\n }", "publi...
[ "0.88281864", "0.8132139", "0.80767727", "0.8066676", "0.80474526", "0.80321276", "0.8032034", "0.8005826", "0.79799676", "0.79688", "0.79512626", "0.792954", "0.7914197", "0.79099876", "0.78999925", "0.78959954", "0.78681684", "0.7863424", "0.7793718", "0.7764154", "0.775008...
0.0
-1
This method returns the data of a node at a given index
public ListNode getNodeAtIndex(int linkedListIndex) { int indexRunner = 0; int index = linkedListIndex; ListNode runner = firstNode; while (indexRunner < index && runner != null) { indexRunner++; runner = runner.next; } if (runner != null) { return runner; } else { return null; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getDataFromGivenIndex(int index){\n //Index validation\n checkIndex(index);\n return getNodeFromGivenIndex(index).data;\n }", "public @Override E get(int index) {\n \treturn getNode(index).data;\n }", "int getData(int node_index) {\n\t\treturn m_list_nodes.getField(node...
[ "0.8156549", "0.80566114", "0.7986764", "0.79027885", "0.7798415", "0.77436525", "0.75045574", "0.7459944", "0.7432847", "0.7429427", "0.73714703", "0.7243175", "0.72315603", "0.72313505", "0.718601", "0.7177268", "0.71351624", "0.7125584", "0.70109695", "0.69467133", "0.6945...
0.0
-1
TODO Autogenerated method stub
public static void main(String[] args) { Scanner input = new Scanner(System.in); System.out.print("Enter r1's center x-, y-coordinates, width, and height: "); double x1 = input.nextDouble(); double y1 = input.nextDouble(); double w1 = input.nextDouble(); double h1 = input.nextDouble(); System.out.print("Enter r2's center x-, y-coordinates, width, and height: "); double x2 = input.nextDouble(); double y2 = input.nextDouble(); double w2 = input.nextDouble(); double h2 = input.nextDouble(); double inMinX = x1-(w1-w2)/2; double inMaxX = x1+(w1-w2)/2; double inMinY = y1-(h1-h2)/2; double inMaxY = y1+(h1-h2)/2; double outMinX = x1-(w1+w2)/2; double outMaxX = x1+(w1+w2)/2; double outMinY = y1-(h1+h2)/2; double outMaxY = y1+(h1+h2)/2; if(x2>=inMinX&&x2<=inMaxX&&y2>=inMinY&&y2<=inMaxY) { System.out.println("r2 is inside r1"); } else if(x2>=outMaxX||x2<=outMinX||y2>=outMaxY||y2<=outMinY) { System.out.println("r2 does not overlap r1"); } else { System.out.println("r2 overlaps r1"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
Created by zhaohui on 18/01/2018.
public interface WayBillDao extends JpaRepository<WayBill, Integer>{ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "private stendhal() {\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@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\tpublic void grabar() {\n\t\t\n\t}", "private sta...
[ "0.61645174", "0.60601825", "0.5934683", "0.5879335", "0.5879335", "0.58423984", "0.5838256", "0.58364046", "0.5785977", "0.5750824", "0.574921", "0.57429266", "0.5717068", "0.57056093", "0.5687903", "0.5678691", "0.5653833", "0.565312", "0.5651082", "0.56431633", "0.56412417...
0.0
-1
the directions that the monster (Tyrone) can go north, east, south and west.
public Room goNorth(Room curRoom) { return gameMap.getRoom(curRoom.getX(), curRoom.getY() - 1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "List<Direction> getValidDirectionsForMovement();", "public Directions getDirectionsOfHits() {\n\t\tList<Coordinate> woundPositions = getWoundPositions();\n\t\tif (woundPositions.get(0).getxPosition() == woundPositions.get(1).getxPosition())\n\t\t\treturn Directions.NORTH;\n\t\telse\n\t\t\treturn Directions.WEST;...
[ "0.70904934", "0.6707342", "0.6651103", "0.65964687", "0.6504645", "0.6413884", "0.6392469", "0.6217869", "0.61548036", "0.61371505", "0.611935", "0.6114538", "0.60949385", "0.6059871", "0.60467", "0.59913504", "0.5986564", "0.5973792", "0.5949041", "0.59422857", "0.59221345"...
0.0
-1
/ / / / / / / / / / /
public Header getContentEncoding() { /* 89 */ return this.contentEncoding; /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "private int rightChild(int i){return 2*i+2;}", "public void divide() {\n\t\t\n\t}", "public abstract void bepaalGrootte();", "double passer();", "int getWidth() {return width;}", "public void zeichneQuadra...
[ "0.55392164", "0.5443003", "0.52042043", "0.51812166", "0.5094322", "0.5058843", "0.5053321", "0.50448096", "0.5025622", "0.5012025", "0.50120205", "0.50111294", "0.5003863", "0.49984357", "0.49974853", "0.4984652", "0.49787974", "0.4978001", "0.49672434", "0.4957116", "0.491...
0.0
-1
/ / / / / / / / / /
public boolean isChunked() { /* 101 */ return this.chunked; /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "private int rightChild(int i){return 2*i+2;}", "public void divide() {\n\t\t\n\t}", "public abstract void bepaalGrootte();", "public void zeichneQuadrate(){\n for (int i=0; i<10;i++)\n rect (50+i*25,50...
[ "0.5540896", "0.5446543", "0.5227331", "0.52141076", "0.5111389", "0.50963986", "0.50654864", "0.5038032", "0.50336593", "0.501189", "0.50033337", "0.5002645", "0.4999724", "0.4997505", "0.49938273", "0.4988672", "0.4982446", "0.49785286", "0.4967535", "0.49578318", "0.491564...
0.0
-1
/ / / / / / / / / / /
public void setContentType(Header contentType) { /* 114 */ this.contentType = contentType; /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "private int rightChild(int i){return 2*i+2;}", "public void divide() {\n\t\t\n\t}", "public abstract void bepaalGrootte();", "double passer();", "int getWidth() {return width;}", "public void zeichneQuadra...
[ "0.5540745", "0.5444497", "0.5205538", "0.5182055", "0.5094161", "0.50587463", "0.5053648", "0.50452423", "0.50258267", "0.50122976", "0.5012191", "0.50119436", "0.50044477", "0.49989554", "0.49980396", "0.49847832", "0.49795863", "0.49785143", "0.4966902", "0.49588826", "0.4...
0.0
-1
/ / / / / / / / /
public void setContentType(String ctString) { /* */ BasicHeader basicHeader; /* 126 */ Header h = null; /* 127 */ if (ctString != null) { /* 128 */ basicHeader = new BasicHeader("Content-Type", ctString); /* */ } /* 130 */ setContentType((Header)basicHeader); /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "public void divide() {\n\t\t\n\t}", "private int rightChild(int i){return 2*i+2;}", "public void zeichneQuadrate(){\n for (int i=0; i<10;i++)\n rect (50+i*25,50,25,25);\n }", "public abstract void b...
[ "0.5531016", "0.54378587", "0.52516115", "0.52405924", "0.5151045", "0.5127977", "0.50680465", "0.5066997", "0.50218964", "0.5013022", "0.5007318", "0.50048536", "0.49997565", "0.4994835", "0.49735898", "0.49699947", "0.49680406", "0.49594593", "0.4937881", "0.49361676", "0.4...
0.0
-1
/ / / / / / / / / / /
public void setContentEncoding(Header contentEncoding) { /* 143 */ this.contentEncoding = contentEncoding; /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "private int rightChild(int i){return 2*i+2;}", "public void divide() {\n\t\t\n\t}", "public abstract void bepaalGrootte();", "double passer();", "int getWidth() {return width;}", "public void zeichneQuadra...
[ "0.55392164", "0.5443003", "0.52042043", "0.51812166", "0.5094322", "0.5058843", "0.5053321", "0.50448096", "0.5025622", "0.5012025", "0.50120205", "0.50111294", "0.5003863", "0.49984357", "0.49974853", "0.4984652", "0.49787974", "0.4978001", "0.49672434", "0.4957116", "0.491...
0.0
-1
/ / / / / / / / /
public void setContentEncoding(String ceString) { /* */ BasicHeader basicHeader; /* 155 */ Header h = null; /* 156 */ if (ceString != null) { /* 157 */ basicHeader = new BasicHeader("Content-Encoding", ceString); /* */ } /* 159 */ setContentEncoding((Header)basicHeader); /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "public void divide() {\n\t\t\n\t}", "private int rightChild(int i){return 2*i+2;}", "public void zeichneQuadrate(){\n for (int i=0; i<10;i++)\n rect (50+i*25,50,25,25);\n }", "public abstract void b...
[ "0.5531016", "0.54378587", "0.52516115", "0.52405924", "0.5151045", "0.5127977", "0.50680465", "0.5066997", "0.50218964", "0.5013022", "0.5007318", "0.50048536", "0.49997565", "0.4994835", "0.49735898", "0.49699947", "0.49680406", "0.49594593", "0.4937881", "0.49361676", "0.4...
0.0
-1
/ / / / / / / / / / / / / / / / /
public void setChunked(boolean b) { /* 178 */ this.chunked = b; /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "private double[] getExtents(){\n return new double[] { -90, -180, 90, 180 };\n }", "double passer();", "public Integer getWidth(){return this.width;}", "int getWidth() {return width;}", "static int ...
[ "0.5398624", "0.5302166", "0.50988036", "0.50856084", "0.50632095", "0.505399", "0.50325966", "0.5016769", "0.49988022", "0.49945837", "0.49838054", "0.49793383", "0.49702466", "0.4950869", "0.4929731", "0.49185315", "0.4905335", "0.49045703", "0.49035764", "0.48944765", "0.4...
0.0
-1
/ / / / / / /
@Deprecated /* */ public void consumeContent() throws IOException {}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "public void divide() {\n\t\t\n\t}", "public void zeichneQuadrate(){\n for (int i=0; i<10;i++)\n rect (50+i*25,50,25,25);\n }", "private int rightChild(int i){return 2*i+2;}", "public abstract void b...
[ "0.54567957", "0.53680295", "0.53644985", "0.52577376", "0.52142847", "0.51725817", "0.514088", "0.50868535", "0.5072305", "0.504888", "0.502662", "0.50005764", "0.49740013", "0.4944243", "0.4941118", "0.4937142", "0.49095523", "0.48940238", "0.48719338", "0.48613623", "0.486...
0.0
-1
/ / / / / / /
public String toString() { /* 195 */ StringBuilder sb = new StringBuilder(); /* 196 */ sb.append('['); /* 197 */ if (this.contentType != null) { /* 198 */ sb.append("Content-Type: "); /* 199 */ sb.append(this.contentType.getValue()); /* 200 */ sb.append(','); /* */ } /* 202 */ if (this.contentEncoding != null) { /* 203 */ sb.append("Content-Encoding: "); /* 204 */ sb.append(this.contentEncoding.getValue()); /* 205 */ sb.append(','); /* */ } /* 207 */ long len = getContentLength(); /* 208 */ if (len >= 0L) { /* 209 */ sb.append("Content-Length: "); /* 210 */ sb.append(len); /* 211 */ sb.append(','); /* */ } /* 213 */ sb.append("Chunked: "); /* 214 */ sb.append(this.chunked); /* 215 */ sb.append(']'); /* 216 */ return sb.toString(); /* */ }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int parent(int i){return (i-1)/2;}", "private int leftChild(int i){return 2*i+1;}", "public void divide() {\n\t\t\n\t}", "public void zeichneQuadrate(){\n for (int i=0; i<10;i++)\n rect (50+i*25,50,25,25);\n }", "private int rightChild(int i){return 2*i+2;}", "public abstract void b...
[ "0.54569614", "0.5368001", "0.53633887", "0.5257851", "0.5214055", "0.5173116", "0.51397747", "0.5088974", "0.5074065", "0.50495464", "0.50273895", "0.4998961", "0.49731052", "0.49444273", "0.49405497", "0.49384844", "0.49107248", "0.4895794", "0.4873521", "0.48623255", "0.48...
0.0
-1
TODO Autogenerated method stub
@Override protected WineFragmentAdapter doInBackground( FragmentManager... params) { return new WineFragmentAdapter(params[0]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
TODO Autogenerated method stub
@Override protected void onPostExecute(WineFragmentAdapter result) { super.onPostExecute(result); mAdapter = result; mViewPager.setAdapter(mAdapter); int position = getArguments().getInt(SELECT_WINE_INDEX, 0); // Toast.makeText(getActivity(), "vino " + position, // Toast.LENGTH_SHORT) // .show(); showWine(position); proDialog.dismiss(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
Created by Administrator on 2018/2/3 0003.
public interface IgetCKXX { public Map<String,String> getCKXX(String idnum); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private stendhal() {\n\t}", "@Override\n public void perish() {\n \n }", "public final void mo51373a() {\n }", "public void mo38117a() {\n }", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "public void mo4359a() {\n ...
[ "0.60665405", "0.5926349", "0.5795968", "0.57409644", "0.5698483", "0.56660366", "0.5652111", "0.56463873", "0.5641467", "0.55915827", "0.55915827", "0.55915827", "0.55915827", "0.55915827", "0.55915827", "0.55915827", "0.5590777", "0.5581503", "0.5576103", "0.55596995", "0.5...
0.0
-1
TODO Autogenerated method stub
public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(System.out)); int t = Integer.parseInt(br.readLine()); int a = 0, b = 0; for (int i = 0; i < t; i++) { StringTokenizer st = new StringTokenizer(br.readLine()); a = Integer.parseInt(st.nextToken()); b = Integer.parseInt(st.nextToken()); bw.write(solution(a, b) + "\n"); } bw.flush(); bw.close(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
TODO Autogenerated method stub
@Override public int getContentView() { return R.layout.activity_home; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
TODO Autogenerated method stub
@Override public void onDataFinish(Bundle savedInstanceState) { super.onDataFinish(savedInstanceState); findViewById(R.id.top_back).setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { // TODO Auto-generated method stub finish(); } }); try { mCatalogObj = MConfig.CatalogList.get(getIntent().getIntExtra("index", 0)); mCatalogId = getIntent().getStringExtra("ids"); state = getIntent().getStringExtra("state"); title = getIntent().getStringExtra("title"); if (TextUtils.isEmpty(state)) { titlebar.setVisibility(View.VISIBLE); } else { mCatalogId = state; titlebar.setVisibility(View.GONE); } } catch (Exception e) { if (e != null) { Log.i("dzy", e.toString()); } finish(); } initSliding(false); if (!TextUtils.isEmpty(title)) { setTitle(title); } else { setTitle(mCatalogObj.name); } // setModuleMenuSelectedItem(mCatalogObj.index); mTitleBarAddBtn.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { // TODO } }); inflater = LayoutInflater.from(this); if (mImageCarousel == null) { mImageCarousel = new AdvancedImageCarousel(this); mImageCarousel.setDefaultImage(R.drawable.default_thumbnail_banner); mImageCarousel.setLoadingImage(R.drawable.default_thumbnail_banner); mImageCarousel.setErrorImage(R.drawable.default_thumbnail_banner); mImageCarousel.setAspectRatio(1.78f); mImageCarousel.setScaleType(ScaleType.CENTER_CROP); mImageCarousel.setIntervalTime(3000); mImageCarousel.setDotViewMargin(0, 0, ScaleConversion.dip2px(this, 10), ScaleConversion.dip2px(this, 8)); } mImageCarousel.removeAllCarouselView(); mImageCarousel.setVisibility(View.GONE); mImageCarouselLayout = new LinearLayout(this); mImageCarouselLayout.setGravity(Gravity.CENTER); mImageCarouselLayout.addView(mImageCarousel); mListView.addHeaderView(mImageCarouselLayout); mImageCarouselBottomView = (RelativeLayout) inflater.inflate(R.layout.layout_carousel_bottomview, null); mImageCarouselBottomViewIcon = (ImageView) mImageCarouselBottomView.findViewById(R.id.icon); mImageCarouselBottomViewTitle = (TextView) mImageCarouselBottomView.findViewById(R.id.title); mImageCarousel.addBottomView(mImageCarouselBottomView); setupTabBar(); SharedPreferences adManager = getSharedPreferences("ad_manager", 0); if (adManager.getBoolean("banner_enable", false)) { new Handler().postDelayed(new Runnable() { @Override public void run() { new AdBanner(HomeActivity.this, mCatalogObj.id, mAdLayout, mAdImage, mAdCloseBtn, false); } }, 5000); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
TODO Autogenerated method stub
@Override public void onClick(View v) { finish(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n public void perish() {\n \n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void getExr...
[ "0.6671074", "0.6567672", "0.6523024", "0.6481211", "0.6477082", "0.64591026", "0.64127725", "0.63762105", "0.6276059", "0.6254286", "0.623686", "0.6223679", "0.6201336", "0.61950207", "0.61950207", "0.61922914", "0.6186996", "0.6173591", "0.61327106", "0.61285484", "0.608016...
0.0
-1
Retrieve server list from config file and set it up for server setting helper
private void setServerList() { ArrayList<ServerObjInfo> _serverList = ServerConfigurationUtils.getServerListFromFile(mContext, ExoConstants.EXO_SERVER_SETTING_FILE); ServerSettingHelper.getInstance().setServerInfoList(_serverList); int selectedServerIdx = Integer.parseInt(mSharedPreference.getString(ExoConstants.EXO_PRF_DOMAIN_INDEX, "-1")); mSetting.setDomainIndex(String.valueOf(selectedServerIdx)); mSetting.setCurrentServer((selectedServerIdx == -1) ? null : _serverList.get(selectedServerIdx)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void setOldServerList(String oldConfigFile) {\n ArrayList<ServerObjInfo> _serverList =\n ServerConfigurationUtils.getServerListFromOldConfigFile(oldConfigFile);\n ServerSettingHelper.getInstance().setServerInfoList(_serverList);\n if (_serverList.size() == 0) return;\n /* force app to st...
[ "0.65907055", "0.6344071", "0.63096946", "0.62786835", "0.62312204", "0.6208253", "0.62029433", "0.6200481", "0.61954623", "0.6181031", "0.6155865", "0.6142431", "0.61142963", "0.61121887", "0.6092299", "0.6090419", "0.6073275", "0.6001034", "0.59788084", "0.5970853", "0.5953...
0.74937826
0
Get server list from previous config of app
private void setOldServerList(String oldConfigFile) { ArrayList<ServerObjInfo> _serverList = ServerConfigurationUtils.getServerListFromOldConfigFile(oldConfigFile); ServerSettingHelper.getInstance().setServerInfoList(_serverList); if (_serverList.size() == 0) return; /* force app to start login screen */ mSetting.setDomainIndex("0"); mSetting.setCurrentServer(_serverList.get(0)); _serverList.get(0).isAutoLoginEnabled = false; /* persist the configuration */ new Thread(new Runnable() { @Override public void run() { Log.i(TAG, "persisting config"); SettingUtils.persistServerSetting(mContext); } }).start(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public List<Server> getServerList() {\n return serverList;\n }", "public List<Server> getServerList() {\n return new ArrayList<Server>(serversList);\n }", "public ArrayList<Server> getServers(){\n return this.serversList;\n }", "public static ServerList getCurrentList(Context co...
[ "0.7142184", "0.69971246", "0.69555527", "0.67791164", "0.67401", "0.6713404", "0.6677674", "0.66712165", "0.66560435", "0.66559947", "0.66478336", "0.65972066", "0.6588199", "0.649931", "0.64372706", "0.6397306", "0.6378225", "0.632135", "0.63108474", "0.6310581", "0.6308163...
0.6218043
26
Provide app version for setting
private void setAppVersion() { try { String appVer = mContext.getPackageManager().getPackageInfo(mContext.getPackageName(), 0).versionName; ServerSettingHelper.getInstance().setApplicationVersion(appVer); } catch (NameNotFoundException e) { if (Config.GD_ERROR_LOGS_ENABLED) Log.e("NameNotFoundException", "Error of getting package information!"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static String getAppVersion(){\r\n return getProperty(\"version\");\r\n }", "public String getAppVersion() { return appVersion; }", "public static String getAppVersion() {\n \t\tif (props.containsKey(\"app.version\")) {\n \t\t\treturn props.getProperty(\"app.version\");\n \t\t} else {\n \t\t\treturn...
[ "0.7939517", "0.7875554", "0.76167685", "0.75680214", "0.7522436", "0.7491004", "0.7365591", "0.7095798", "0.6893855", "0.6805105", "0.677182", "0.67552406", "0.67552406", "0.66615134", "0.66571325", "0.66424406", "0.6613589", "0.6608105", "0.6600664", "0.6566861", "0.6539161...
0.78360015
2
Initialize SocialImageLoader when application start up and clear all data cache.
private void initSocialImageLoader() { if (SocialDetailHelper.getInstance().socialImageLoader == null) { SocialDetailHelper.getInstance().socialImageLoader = new SocialImageLoader(mContext); SocialDetailHelper.getInstance().socialImageLoader.clearCache(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void initImageLoader() {\n if (!ImageLoader.getInstance().isInited()) {\n ImageLoaderConfiguration config = ImageLoaderConfiguration.createDefault(getActivity().getApplicationContext());\n ImageLoader.getInstance().init(config);\n }\n }", "private void initImageLoade...
[ "0.75157666", "0.7484586", "0.71161216", "0.69575953", "0.68287855", "0.67087907", "0.65634173", "0.6557389", "0.64397156", "0.6404986", "0.6402734", "0.6389499", "0.63528645", "0.634913", "0.63451254", "0.6337446", "0.6328543", "0.6288996", "0.6266991", "0.6251213", "0.62072...
0.8552787
0
Created by maoyiding on 17711.
@Component @Mapper public interface AppraiseMapper { /** * 获取所有评价 * @return */ List<Appraise> getAll(); /** * 添加评价 * @return */ boolean addAppraise(Appraise appraise); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "public final void mo51373a() {\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}"...
[ "0.6066535", "0.5983616", "0.58933425", "0.5876099", "0.5844577", "0.5844577", "0.58179295", "0.5779001", "0.57746774", "0.5736305", "0.57216793", "0.5719395", "0.5719056", "0.5716877", "0.5710716", "0.569092", "0.56842315", "0.56841534", "0.56819487", "0.5681717", "0.5656270...
0.0
-1
This method allows to get all the Blocks for the Class on which it is;
public Collection<AssertStatement> getAsserts() { return asserts; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public BlockType[] getBlocks() {\n return blocks;\n }", "List<Block> blocks();", "public Collection<Block> getBlockCollection() {\n\t\treturn this.blocks.values();\n\t}", "public List<Block> blocks() {\n this.blocks = createBlocks();\n return this.blocks;\n }", "public Block[] ge...
[ "0.7375908", "0.7200809", "0.7049624", "0.7037432", "0.697191", "0.6917506", "0.6891312", "0.6858922", "0.6824178", "0.67747986", "0.6708682", "0.670307", "0.66874903", "0.6663993", "0.6507999", "0.6478038", "0.6432435", "0.6420729", "0.63665944", "0.63217205", "0.63004726", ...
0.0
-1
New PartDb Table include partTbl/singleTbl/broadcastTbl of new part db
public boolean isNewPartDbTable(String tbName) { return partInfoCtxCache.containsKey(tbName); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void createTables(){\n Map<String, String> name_type_map = new HashMap<>();\n List<String> primaryKey = new ArrayList<>();\n try {\n name_type_map.put(KEY_SINK_NAME, MyDatabase.TYPE_VARCHAR);\n name_type_map.put(KEY_SINK_ADDRESS, MyDatabase.TYPE_VARCHAR);\n ...
[ "0.62856865", "0.59584194", "0.5917206", "0.5747341", "0.57308066", "0.57303363", "0.5684791", "0.56596833", "0.56029654", "0.5593535", "0.55810076", "0.5565453", "0.5549549", "0.5535479", "0.55296063", "0.5525826", "0.5523942", "0.55232704", "0.5496638", "0.5496564", "0.5494...
0.5448493
27
Hospital hospital = hospitalRepository.getOne(payload.getHospitalId()); user.setHospital(hospital);
private User toUserModel(User user, UserCreateController.Payload payload) { BeanUtils.copyPropertiesIfNotNull(payload, user.getUserInfo()); BeanUtils.copyPropertiesIfNotNull(payload, user); return user; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface HospitalisationRepository extends JpaRepository<Hospitalisation,Long> {\n\n}", "private void pushToHibernate(){\n DATA_API.saveUser(USER);\n }", "public Employee save(Employee employee){\n return employeeRepository.save(employee);\n }", "public User saveUser(UserDto userDto);",...
[ "0.6421517", "0.6007115", "0.5968038", "0.5956619", "0.5916815", "0.591674", "0.58803266", "0.58682775", "0.585005", "0.58066916", "0.5806255", "0.5786679", "0.5784769", "0.5782625", "0.57617515", "0.57597417", "0.5753843", "0.57144487", "0.56970376", "0.5691767", "0.5681066"...
0.0
-1
Base Case : If j is source
public void printPath(ArrayList<Integer> parent, int index, Graph graph){ if (parent.get(index)==-1) return; //recurse till we get src printPath(parent, parent.get(index), graph); shortestVerticesToPlot.add(graph.vertices.get(index).point); System.out.print(index + "\t\t"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean isSource();", "public abstract Object getSource();", "boolean isSource();", "public boolean isSource() {\r\n \t\treturn source;\r\n \t}", "public Object getSource() {return source;}", "public abstract Source getSource();", "public boolean isSource()\n\t{\n\t\treturn isSource;\n\t}", "p...
[ "0.63789636", "0.6377021", "0.6367091", "0.63093334", "0.62024844", "0.6047472", "0.6040028", "0.59872985", "0.59667325", "0.5901832", "0.58871704", "0.58251804", "0.5800742", "0.5782137", "0.5764213", "0.5764213", "0.5759476", "0.57550114", "0.57304907", "0.5727709", "0.5715...
0.0
-1
Constructor for a new game
public Game() throws IOException { //reading the game.txt file try { HeliCopIn = new Scanner(HeliCopFile); String line = ""; while ( HeliCopIn.hasNext() ) { line = HeliCopIn.nextLine(); StringTokenizer GameTokenizer = new StringTokenizer(line); if ( !GameTokenizer.hasMoreTokens() || GameTokenizer.countTokens() != 5 ) { continue; } int XCoord = Integer.parseInt(GameTokenizer.nextToken()); int YCoord = Integer.parseInt(GameTokenizer.nextToken()); int health = Integer.parseInt(GameTokenizer.nextToken()); int NumRocketsStart = Integer.parseInt(GameTokenizer.nextToken()); int NumBulletsStart = Integer.parseInt(GameTokenizer.nextToken()); if (Player.Validate(line) == true) { //creating a new player and initialising the number of bullets; pl = new Player(XCoord,YCoord,health,NumRocketsStart,NumBulletsStart); pl.NumBullets = pl.GetNumBulletsStart(); pl.NumRockets = pl.GetnumRocketsStart(); // System.out.println(XCoord) ; //System.out.println(YCoord) ; //System.out.println(health) ; //System.out.println(NumRocketsStart) ; //System.out.println(NumBulletsStart) ; } } } catch (FileNotFoundException ex) { ex.printStackTrace(); } finally { if ( HeliCopIn != null ) { HeliCopIn.close(); } } //loading the background image and explosion image try { BackGround = ImageIO.read(new File("images\\finalcloud.jpg")); } catch (IOException e) { e.printStackTrace(); } try { Explosion = ImageIO.read(new File("images\\explosion.gif")); } catch (IOException e) { e.printStackTrace(); } try { GameOver = ImageIO.read(new File("images\\gameover.gif")); } catch (IOException e) { e.printStackTrace(); } try { GameWin = ImageIO.read(new File("images\\gamewin.gif")); } catch (IOException e) { e.printStackTrace(); } update(); int del = 2000; // createEnemyHelicopter(); time = new Timer(del , new ActionListener() { @Override public void actionPerformed(ActionEvent e) { createEnemyHelicopter(); } }); time.start(); time = new Timer(delay , new ActionListener() { @Override public void actionPerformed(ActionEvent e) { if (GameOn==true ){ updateEnemies(); UpdateBullets(); UpdateRockets(); pl.Update(); repaint(); } try { WiriteToBinary(); } catch (IOException e1) { e1.printStackTrace(); } } }); time.start(); //WiriteToBinary(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Game() {}", "public Game() {\n\n\t}", "public Game(){\n\n }", "public Game() {\n }", "public PlayableGame() {\r\n\r\n }", "public MiniGame() {\n\n\t}", "public Game() \n {\n parser = new Parser();\n name = new String();\n player = new Player();\n ai = new ...
[ "0.84696484", "0.83490264", "0.82617754", "0.8258332", "0.8125296", "0.8101999", "0.8012881", "0.8009615", "0.7991374", "0.79402465", "0.79402465", "0.78777814", "0.78719884", "0.7819811", "0.77922565", "0.7735778", "0.7726124", "0.76811224", "0.7629969", "0.7628352", "0.7587...
0.0
-1
function the update the game as well as the game characters
public void update(){ //Key listener for keyboard input addKeyListener(new KeyAdapter(){ @Override public void keyPressed(KeyEvent e) { // Moving on the x axis. if((e.getKeyCode() == KeyEvent.VK_D) || e.getKeyCode() == (KeyEvent.VK_RIGHT)) pl.moveXspeed += pl.accelXspeed; else if(e.getKeyCode() == (KeyEvent.VK_A) || e.getKeyCode() == (KeyEvent.VK_LEFT)) pl.moveXspeed -= pl.accelXspeed; // Moving on the y axis. if(e.getKeyCode() == (KeyEvent.VK_W) || e.getKeyCode() == (KeyEvent.VK_UP)) pl.moveYspeed -= pl.accelYspeed; else if(e.getKeyCode() == (KeyEvent.VK_S) || e.getKeyCode() == (KeyEvent.VK_DOWN)) pl.moveYspeed += pl.accelYspeed; else { } if (GameOn == true){ } else if (GameOn == false ) { repaint(); Data = " Number of rockets remaining: " + pl.NumRockets + "Number of bullets remaining: " +pl.NumBullets + " Remaining health: " +pl.Health +" Number of runway enemies: " + RunAwayEnemies + " Number of destroyed enemies: " +DestroyedEnemies; Email = new EmailGUI(Data); } /* else if (WinsState == true ) { repaint(); //*******************stoip game here and send email with game details Data = " Number of rockets remaining: " + pl.NumRockets +"," + " Number of bullets remaining: " +pl.NumBullets+"," + " Remaining health: " +pl.Health+"," + " Number of destroyed enemies: " +DestroyedEnemies+"," +" Number of runway enemies: " + RunAwayEnemies; Email = new EmailGUI(Data); }*/ } }); //mouse listener for mouse input addMouseListener(new MouseListener() { @Override public void mouseClicked(MouseEvent e) { //actions performed when mouse button 1 is pressed if (e.getButton() == MouseEvent.BUTTON1) { if (pl.NumBullets > 0) { //creates shoot and adds the to the list pl.Shoot(); BulletFired = true; bul = new Bullet(pl.GetXCoord() + 240,pl.GetYCoord() + 70); BulletList.add(bul); } else if (pl.NumBullets <= 0) { GameOn = false; } } //actions performed when mouse button 2 is pressed if (e.getButton() == MouseEvent.BUTTON3) { if (pl.NumRockets > 0) { //creates rockets and adds the to the list pl.FireRocket(); RocketFired = true; rock = new Rocket(pl.GetXCoord() + 200,pl.GetYCoord() + 60); RocketList.add(rock); } } } @Override public void mousePressed(MouseEvent e) { } @Override public void mouseReleased(MouseEvent e) { } @Override public void mouseEntered(MouseEvent e) { } @Override public void mouseExited(MouseEvent e) { } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void update(){\r\n\t\tupdateTurnLabel();\r\n\t\tupdateCanvas();\r\n\t}", "public void gameupdate(){\n game.update();\r\n panel.formUpdate(game.lives);\r\n }", "@Override\n public void update(Input input) {\n // Logic to update the game, as per specification must go here\n\n ...
[ "0.70985377", "0.70835453", "0.7066767", "0.69658655", "0.6938015", "0.6935518", "0.68727106", "0.6808423", "0.6776788", "0.6709139", "0.6696304", "0.6672432", "0.66716856", "0.6599922", "0.65983427", "0.65901595", "0.65900546", "0.65897757", "0.6565734", "0.6565734", "0.6565...
0.7034485
3