query_id stringlengths 32 32 | query stringlengths 7 6.75k | positive_passages listlengths 1 1 | negative_passages listlengths 88 101 |
|---|---|---|---|
4f8d4c5b6d647875cfc673c0710ed1c9 | Remote connections are alive when the box on the other end is responding to commands. | [
{
"docid": "9057b7c574cc87e0e7a08a7c66d087e5",
"score": "0.0",
"text": "def alive?\n\t\tindex('/', 'alive_check')\n\t\ttrue\n\trescue\n\t\tfalse\n\tend",
"title": ""
}
] | [
{
"docid": "38f1f3d2bada87dd15304646c90b23e8",
"score": "0.6399692",
"text": "def connected\n process Statuses::CONNECTED\n end",
"title": ""
},
{
"docid": "bcefffc6ce873cce05c336da876a897c",
"score": "0.63730097",
"text": "def alive?\n @irc.connected?\n end",
... |
99adcdb8ae50510fc9a957f93d6545b1 | GET /admin/market_orgs GET /admin/market_orgs.json | [
{
"docid": "777c4f2477ed4be42ec35d4bced9f5e5",
"score": "0.7756497",
"text": "def index\n @market_orgs = MarketOrg.all\n end",
"title": ""
}
] | [
{
"docid": "29e6bc42cd7d97b3ed9e9465515aa86a",
"score": "0.7662164",
"text": "def list_orgs()\n route = \"/user/orgs\"\n request(route, \"GET\", {})\n end",
"title": ""
},
{
"docid": "818f8e632f99a9d19ef5e4c7f9d3f231",
"score": "0.69762194",
"text": "def get_organizations\n ... |
01eee84187bedd447b32738417d5b360 | remove Zappos.com related substrings from title page. These break the search on the Zappos API. | [
{
"docid": "410ba78362ca43310e8e47ac7b7fbe91",
"score": "0.0",
"text": "def formatSearchTerm(term)\n term.gsub!(\" at Zappos.com\", \"\")\n term.gsub!(\" - Zappos Couture\", \"\")\n term.gsub!(\" - Zappos.com Free Shipping BOTH Ways\", \"\")\n term.gsub!(\" at Couture.Zappos.com\", \"\")\n ... | [
{
"docid": "106e3e6e8db5f4c0322b89972a6ff11a",
"score": "0.7141617",
"text": "def remove_title_if_present\n @doc.css('title').each { |node| node.remove }\n end",
"title": ""
},
{
"docid": "de05475c18c894a7d053112b506d0e73",
"score": "0.70490694",
"text": "def trim_title\n ... |
e5b36d34e0d5f35ef7e272110932ea1c | Smartly formats and localizes a date range | [
{
"docid": "90f0c3634868563b21c1ef3472c0fc4d",
"score": "0.6360168",
"text": "def date_range(from_date, until_date, options = {})\n options.symbolize_keys!\n format = options[:format] || :short\n separator = options[:separator] || \"-\"\n\n if format.to_sym == :short\n month_names = I18... | [
{
"docid": "6b7e4553c59b0f70ea574dbe4f5ce866",
"score": "0.6872116",
"text": "def date_range_s(format = :short)\n return date.year if all_year?\n\n if format == :long\n if start_date == end_date\n date.strftime(\"%-m/%-d/%Y\")\n else\n \"#{start_date.strftime('%-m/%-d/%Y')}... |
f8351b299f071d3d2741817c6a8f47e8 | Publishes message to destination. If a block is given a receipt will be requested and passed to the block on receipt. Accepts a transaction header ( :transaction => 'some_transaction_id' ). | [
{
"docid": "592eadb7b91ac3afc79298cee858e142",
"score": "0.711364",
"text": "def publish(destination, message, headers = {})\n headers = headers.symbolize_keys\n raise Stomp::Error::DestinationRequired unless destination\n if block_given?\n headers = headers.merge(:receipt => regis... | [
{
"docid": "99168e30726b373746e5cdeb5c271524",
"score": "0.7051168",
"text": "def send destination, message, headers = {}\n if block_given?\n headers['receipt'] = register_receipt_listener lambda {|r| yield r}\n end\n @connection.send destination, message, headers\n end",
"t... |
4b0157cfcec93287712a8afd0447014d | Notify all receivers of a message and any additional arguments. | [
{
"docid": "79bd2d003bea4f15f84093ba9fe69ec4",
"score": "0.5234333",
"text": "def send(message, *args)\n # Now we have to swap some variable references around in order to restore the binding\n # for $max_object that existed at the time the receive callback was registered.\n # This ensures... | [
{
"docid": "92d5119c36fdde6e546d77159aa6ab81",
"score": "0.6668287",
"text": "def notify(*args)\n subscribers.values.each { |subscriber| subscriber.call(*args) }\n end",
"title": ""
},
{
"docid": "d42d8c828096ce402b22dba7212b6b6f",
"score": "0.6073799",
"text": "def call\n ... |
9604d535859a83d4b1586dd4ec26ccbc | check if a presenter teaches a subject | [
{
"docid": "f6105f2b3c792871b306c1edb9ab14be",
"score": "0.7044375",
"text": "def teaches? (subject)\n return self.subjects.exists? subject\n end",
"title": ""
}
] | [
{
"docid": "66ea9f70ae4cf9b36a3547114585b52c",
"score": "0.7282486",
"text": "def has_subject?(subject)\n client.ask.whether([subject, :p, :o]).true?\n end",
"title": ""
},
{
"docid": "66ea9f70ae4cf9b36a3547114585b52c",
"score": "0.7282486",
"text": "def has_subject?(subject)... |
378a56d8121a6893debafd90ac357c93 | find sum of squares of array of numbers | [
{
"docid": "69fbf6faacefb6537083dee1bbaed6d2",
"score": "0.8241846",
"text": "def sum_of_squares\n\t\t\tinject(0) do |sum, elem|\n\t\t\t\tsum + (elem ** 2)\n\t\t\tend\n\t\tend",
"title": ""
}
] | [
{
"docid": "f3cb52c18bf35b91c454de25ee8d99be",
"score": "0.8258856",
"text": "def sum_of_squares(array)\n array.each.map{|num total += num*num}.reduce(:+) #is like fold_left. reduce works on array or collection of enumerables\nend",
"title": ""
},
{
"docid": "85df95e4ee49bf248284b60322d5a45... |
4ef41c519f70996ff08ad75dc7826a24 | Public: Set the session's parameters. This will be added to all actions that are sent to analytics. See:: ParameterMap:GA_PARAMS | [
{
"docid": "60930116f3929c1bda6e392d323b9f6b",
"score": "0.65959775",
"text": "def add_options(options)\n options.keys.each do |key| \n raise GoogleAnalyticsParameterNotFoundError, \"Parameter '#{key}'\" unless GA_PARAMS[key]\n end\n \n @sessionopts.merge!(options)\n self... | [
{
"docid": "bde7c2c01eaeb2b9d9ac1a9901b7d3fe",
"score": "0.6787449",
"text": "def google_analytics_params params\n @_ga_instance_params = params\n end",
"title": ""
},
{
"docid": "7c3491ceb74b322091d5cfcd21b25e41",
"score": "0.61826813",
"text": "def set_session_params_admin(... |
aff7bd6d42c1dd48194093462d66b82d | GET /test_subject_evaluations/new GET /test_subject_evaluations/new.xml | [
{
"docid": "96274777630471deca459dd0630415e1",
"score": "0.8015305",
"text": "def new\n @test_subject_evaluation = TestSubjectEvaluation.new\n\n respond_to do |format|\n format.html # new.html.erb\n format.xml { render :xml => @test_subject_evaluation }\n end\n end",
"title": ""... | [
{
"docid": "9a36b0314d0a45581eb754f5aceb6084",
"score": "0.6951253",
"text": "def create\n @test_subject_evaluation = TestSubjectEvaluation.new(params[:test_subject_evaluation])\n\n @test_subject_evaluation.test_subject = @test_subject\n\n respond_to do |format|\n if @test_subject_evaluati... |
5dd3f3393eb3c0b932880bc99300cf51 | check if pixi is an event | [
{
"docid": "5b84d2d316ca26bdee48e4ecb09a54b7",
"score": "0.60398245",
"text": "def event?\r\n is_category_type? 'event'\r\n end",
"title": ""
}
] | [
{
"docid": "1b2426084c7b7f41b6cc9c7fa3832b9b",
"score": "0.68232363",
"text": "def is_event?\n self.object_type.downcase.to_s == \"event\"\n end",
"title": ""
},
{
"docid": "e9a7990efd85fe189bfde2350e2b041e",
"score": "0.6753407",
"text": "def event?\n entry_type == :event\n ... |
e561e11bcf379ef5dc139c210017366b | Only allow a list of trusted parameters through. | [
{
"docid": "cfe99c574c5134248b69dea2fc2f849e",
"score": "0.0",
"text": "def region_params\n params.require(:region).permit(Region::REGISTRABLE_ATTRIBUTES +\n [region_areas_attributes: RegionArea::REGISTRABLE_ATTRIBUTES])\n end",
"title": ""
}
] | [
{
"docid": "c1f317213d917a1e3cfa584197f82e6c",
"score": "0.69497335",
"text": "def allowed_params\n ALLOWED_PARAMS\n end",
"title": ""
},
{
"docid": "e662f0574b56baff056c6fc4d8aa1f47",
"score": "0.6812623",
"text": "def strong_params\n params.require(:listing_member).permi... |
d213b9455434b505fd939da2364d0960 | Base methods: Returns the parent entity id value, if there is one. Usually inside the framework, for ProjectRow is project_id, for InvoiceRow is invoice_id, for TeamRow is team_id and so on. | [
{
"docid": "57999aaae54313344dd6b5784c7d9553",
"score": "0.7359074",
"text": "def get_parent_id()\n self.invoice_id\n end",
"title": ""
}
] | [
{
"docid": "2c8d1c28017882304e0a76abd2684e85",
"score": "0.77514875",
"text": "def parent_id\n self[parent_field_name]\n end",
"title": ""
},
{
"docid": "8b6eb6d1c0aa59b52f3e59f6c1c09468",
"score": "0.7500929",
"text": "def parent_id\n @parent_id || self.parent.t... |
338ae71815bae671e9dab128c1096587 | Replaces '' with '_', used for valid property names [DotNet] replaces keywords with substitutes form KeywordsSubstitute | [
{
"docid": "1ee3eeab36508c7880084c36d8e86143",
"score": "0.6352117",
"text": "def validate_property_name(name, camel = false)\n if camel\n valid_name = name.gsub(/-/, \"_\").camelcase\n else\n valid_name = name.gsub(/-/, \"_\")\n end\n if KeyWords.include? v... | [
{
"docid": "c575085645798037daa395c22d7eea60",
"score": "0.63746727",
"text": "def translate_key(key)\n underscore(key.to_s.gsub(/_*(.+)/, '\\1'))\n end",
"title": ""
},
{
"docid": "4e8f3df9cb10adf7f5284fdaa6b0ca1d",
"score": "0.63589394",
"text": "def underscorify\n gsu... |
7d2103ba4f8c43cd2b7650cc171a9bee | the third test will check that the class has a food rejuvenation attribute or method. | [
{
"docid": "6185d73bfe44a66efe6ecba3da3ef381",
"score": "0.737055",
"text": "def test_food_has_rejuvenation_level\n assert_equal(1, @food1.rejuvenation_level())\nend",
"title": ""
}
] | [
{
"docid": "08af69a7ca3fdfb17c00ca5a6f551783",
"score": "0.690874",
"text": "def test_food_has_name\n assert_equal(\"chicken\", @food1.name())\nend",
"title": ""
},
{
"docid": "3629dc514b70328e1436c50c3ceb5c08",
"score": "0.67667145",
"text": "def test_take_fish_from_river\n @bea... |
e53876313a86ef74775a215f951082f9 | determining the days in each month | [
{
"docid": "4af28554932dc8a705c3953c7092fff3",
"score": "0.6737462",
"text": "def days_in_month(day, month, year)\n days_month ={\n 1 => 31,\n 2 => february_valid(year),\n 3 => 31,\n 4 => 30,\n 5 => 31,\n ... | [
{
"docid": "3a210feb4a5627d728d2f202d9248b3f",
"score": "0.8603434",
"text": "def monthdays; end",
"title": ""
},
{
"docid": "58d73d7b4ed57fac84605a5afb28fb2f",
"score": "0.8365062",
"text": "def days_of_month\n days = []\n days_in_month.times { |n| days << start_of_month.a... |
25d332193df7ab320c5dbcbb92730fd0 | title movie title string returns ActiveRecord::relation (keys are symbols/strings) or nil | [
{
"docid": "bf63d136c566d81b6ff7260995bed87e",
"score": "0.0",
"text": "def get_movie_in_db(title)\n result = Movie.find_by(['title LIKE ?', '%' + params[:movie_input] + '%'])\nend",
"title": ""
}
] | [
{
"docid": "40a443416ac00634a87e05aa40b21020",
"score": "0.7345365",
"text": "def film_title()\n sql = \"SELECT f.title FROM films f INNER JOIN screenings s ON s.screening_film = f.id WHERE s.id = #{@id};\"\n result = SqlRunner.run(sql).first\n return result['title']\n end",
"title": ""
... |
fe3bff6b918c1225fd6096923fec559a | Create events and ateendees from Calendar List | [
{
"docid": "ea70eb8f1b81518d4b27326d288685cc",
"score": "0.599625",
"text": "def update_from_google\n @calendars.each do |google_event|\n event = Event.find_by(gid: google_event.id)\n # Update existing event with updated Calendar info\n if event.present?\n event.title = google_e... | [
{
"docid": "5408c8fbeb836d7ec1cbd99022e97a07",
"score": "0.6905662",
"text": "def events_now\n\n # Open empty array\n events = []\n\n # Loop over all the calendars\n CALENDARS.each do |name, id|\n\n # Get the events\n cal_events = calendar(id).find_events_in_range(Time.now, Time.now + 60)\n\n ... |
737277a758f23072cb1de3fc38def51e | Test basic embedding a comment | [
{
"docid": "2d40997dab11796bbe13322cc9e9dac9",
"score": "0.6807726",
"text": "def testCommentInEmbedded2\n RCodeLeveler::set_level(2)\n requireFile('CommentInEmbedded')\n assert_equal(nil,$Var1)\n assert_equal(nil,$Var2)\n end",
"title": ""
}
] | [
{
"docid": "dc26b19e4f2fed1212cb8267868e1bfc",
"score": "0.7547761",
"text": "def comment(text); end",
"title": ""
},
{
"docid": "dccee9a650fab116225e338f12a13afb",
"score": "0.7547315",
"text": "def test_comment\n assert_equal( @assembler.is_comment?(\"\"), nil )\n assert_equa... |
8c0c9a7570b50ed5bfa6a6217ee46936 | list_style = 'ordered' || 'unordered' | [
{
"docid": "54a7b2bd98c45b491609b69376d5e58b",
"score": "0.56136847",
"text": "def title_list(list_style)\n hash_array = json_formatted\n commit_titles = hash_array.map{ |commit| commit[:title] }\n if list_style == 'unordered'\n commit_titles.join(\"\\n\")\n else\n commit_titles.ea... | [
{
"docid": "c1a80b215e3819b1cc745b323e60804a",
"score": "0.7743295",
"text": "def list_style(item); end",
"title": ""
},
{
"docid": "df10ca0432518f05570212b6b1379b8f",
"score": "0.7198511",
"text": "def create_list_style_shorthand! # :nodoc:\n create_shorthand_properties! LIST_S... |
ae217848eccdc4aff6e9e091226065f6 | PATCH/PUT /inclasses/1 PATCH/PUT /inclasses/1.json | [
{
"docid": "98100e7e8cbbae26e744edfc41c6a83c",
"score": "0.70291215",
"text": "def update\n respond_to do |format|\n if @inclass.update(inclass_params)\n format.html { redirect_to @inclass, notice: 'Inclass was successfully updated.' }\n format.json { head :no_content }\n else... | [
{
"docid": "c7511a0d3bb550cc0da771955adcb869",
"score": "0.6579299",
"text": "def update\n @clazz = Clazz.find(params[:id])\n\n respond_to do |format|\n if @clazz.update_attributes(params[:clazz])\n format.html { redirect_to @clazz, notice: 'Clazz was successfully updated.' }\n ... |
8107c7b203a5c9fac0df8a0303669d4f | Override ActiveModel::Dirty methods in order to use code_fingerprint_changed? instead of code_changed? This is necessary because code is no longer an ActiveRecord attribute and all the _changed and _was magic no longer works. | [
{
"docid": "6ae1e8f2f3840b2ff18f6d71928e0e43",
"score": "0.6927878",
"text": "def will_save_change_to_code?\n code_fingerprint_changed?\n end",
"title": ""
}
] | [
{
"docid": "b3d8b6f4ad2dd65289df7a28619d2a34",
"score": "0.74113464",
"text": "def code_changed\n\t\t@changed = true\n\tend",
"title": ""
},
{
"docid": "6d9afa35b017938f05cba3574a8dc98c",
"score": "0.70148224",
"text": "def remove_dirty_change_check(meth)\n generated_methods.m... |
6c2ae71d6d18665c0c7489d4589afcd2 | Wrapper method. Sets the y component of the scaling of this Actor. See Transformablescale. | [
{
"docid": "ba94643d5afc0b6ffb323fb93b4f626e",
"score": "0.75519466",
"text": "def scale_y=(val)\n type_check(val, Numeric)\n @scale[1] = val\n @scale_is_dirty = @is_dirty = true\n end",
"title": ""
}
] | [
{
"docid": "4d672dbbee94937a698257969be1fcb7",
"score": "0.76317114",
"text": "def scale_y(y)\n scale(1, y)\n end",
"title": ""
},
{
"docid": "412aad6ddded4c2d3c0aea362cc20968",
"score": "0.74958163",
"text": "def scale_y\n @scale[1]\n end",
"title": ""
},
... |
efe29d234e037205f4f82f633d5bcac6 | OPTIONAL 18 & 19 & 20 | [
{
"docid": "cafc0d13ff6a293cf26224b7328002f9",
"score": "0.0",
"text": "def customer_can_afford_pet(customer, new_pet)\n if customer[:cash] >= new_pet[:price]\n return true\n else\n return false\n end\nend",
"title": ""
}
] | [
{
"docid": "94a9f9cebb96ca3b29ccb5ba3cfcdd94",
"score": "0.61686563",
"text": "def alternatives; end",
"title": ""
},
{
"docid": "67081eb3c98dc9ab87bd978f73a10e81",
"score": "0.6132603",
"text": "def advanced; end",
"title": ""
},
{
"docid": "67081eb3c98dc9ab87bd978f73a10... |
436f2a216b0f87fb58648293a296ab2c | GET /meals GET /meals.json | [
{
"docid": "aa048db382f42ed798953855aac40759",
"score": "0.0",
"text": "def index\n Meal.joins(:meal_people).where(\"meal_people.person_id\" => current_user).\n select{|meal| !meal.finished && meal.time && meal.time < Time.now}.map(&:delete)\n meals = Meal.joins(:meal_people).where(\"meal_peo... | [
{
"docid": "6cc2be40675fd581b6ad4c0e51e16008",
"score": "0.81168157",
"text": "def index\n @meals = Meal.all\n\n render json: @meals\n end",
"title": ""
},
{
"docid": "6e91fd3f22d8fd2cc36c586968f9f3ec",
"score": "0.8073322",
"text": "def index\n @meals = Meal.all\n rende... |
6f31a45cca7502ee3e70b857ced1d45d | def perform Magento2::Api.configure('dz4xnhhgfsfuyj00g6bkel0jq6mwdak2', 'hhjnlf59qh2m7an9sdpfcu0o9nox78y6', 'ie5iafduhqs1dydynidsjki582oti17w', 'mva5hldj17elic6muxmf53fq7zmm7xl5', " setup_customer end | [
{
"docid": "51403e0a040fb8ecabc99727e322d8b7",
"score": "0.0",
"text": "def perform\n Magento2::Api.configure('dz4xnhhgfsfuyj00g6bkel0jq6mwdak2', 'hhjnlf59qh2m7an9sdpfcu0o9nox78y6', 'ie5iafduhqs1dydynidsjki582oti17w', 'mva5hldj17elic6muxmf53fq7zmm7xl5', \"https://mall2door.net\")\n orders = Magent... | [
{
"docid": "68194ecb8567ad0223e1d6a37ec44ecb",
"score": "0.62946635",
"text": "def merchant_end_point; end",
"title": ""
},
{
"docid": "12df9e66f58b946844997785e245fd0e",
"score": "0.61896896",
"text": "def merchant_endpoint; end",
"title": ""
},
{
"docid": "e47c4410507d9... |
ace48a40f8c50d9d7a9f60897404e08f | Returns the value of attribute reverting | [
{
"docid": "33bd73e61a2929f1a98085081e310bda",
"score": "0.5774414",
"text": "def reverting; end",
"title": ""
}
] | [
{
"docid": "d8f7a0c9cff3c5e0a52c45102ea4af87",
"score": "0.68187994",
"text": "def original_attribute; end",
"title": ""
},
{
"docid": "d8f7a0c9cff3c5e0a52c45102ea4af87",
"score": "0.68187994",
"text": "def original_attribute; end",
"title": ""
},
{
"docid": "b23c9529176e... |
37b9516ab664cfa5fe576466e562fa6c | validates_presence_of :name, :happiness, :nausea, :height, :tickets | [
{
"docid": "6693c8d4d7c49c7e2e2fb140cc81cba2",
"score": "0.0",
"text": "def mood\n \tself.happiness > self.nausea ? \"happy\" : \"sad\" if self.happiness && self.nausea\n end",
"title": ""
}
] | [
{
"docid": "dea824eeff7dc0c599cb953af0344cde",
"score": "0.6670974",
"text": "def validate\n super\n errors.add(:name, \"can't be empty\") if name.blank?\n errors.add(:category_id, \"can't be empty\") if category_id.blank?\n errors.add(:price, \"can't be empty\") if price.blank?\n end",
... |
7604a48d00a4b6f990c557a329a6aa60 | Retrieves all guild achievements. | [
{
"docid": "3f4fa8357384850d876db98c90a5d013",
"score": "0.7649743",
"text": "def guild_achievements\r\n BnetApi::make_request('/wow/data/guild/achievements')\r\n end",
"title": ""
}
] | [
{
"docid": "500048b741cdc693850506e6c4d93795",
"score": "0.7331639",
"text": "def index\n @achievement = Achievement.get_public_achievements\n # instead of public_access we use get_public_achievements\n end",
"title": ""
},
{
"docid": "7a6e11770df781ed3dbeb3817eea32fd",
... |
689909310bbe385d36539d6cee6cc8a2 | TODO move out to Generator::PrefixHeader | [
{
"docid": "94ee69a4a7f1dd8909d4e69246449897",
"score": "0.0",
"text": "def save_prefix_header_as(pathname)\n pathname.open('w') do |header|\n header.puts \"#ifdef __OBJC__\"\n header.puts \"#import #{@podfile.platform == :ios ? '<UIKit/UIKit.h>' : '<Cocoa/Cocoa.h>'}\"\n ... | [
{
"docid": "18c1f2c1af780adbba92c90b35d0ccc2",
"score": "0.7394505",
"text": "def prefix; end",
"title": ""
},
{
"docid": "18c1f2c1af780adbba92c90b35d0ccc2",
"score": "0.7394505",
"text": "def prefix; end",
"title": ""
},
{
"docid": "18c1f2c1af780adbba92c90b35d0ccc2",
... |
56934a9599f758b8fe5149554d119098 | Return a copy of the specified +string+ with HTML special characters escaped as HTML entities. | [
{
"docid": "a777e752e677fd27114b6f85ed32a670",
"score": "0.82720476",
"text": "def html_escape( string )\n\t\t\treturn string.\n\t\t\t\tgsub( /&/, '&' ).\n\t\t\t\tgsub( /</, '<' ).\n\t\t\t\tgsub( />/, '>' )\n\t\tend",
"title": ""
}
] | [
{
"docid": "aefe9e11f1b734d096e5066b1a6dca47",
"score": "0.8545247",
"text": "def escape_html( string )\n\t\t\treturn string.\n\t\t\t\tgsub( /&/n, '&' ).\n\t\t\t\tgsub( /\\\"/n, '"' ).\n\t\t\t\tgsub( />/n, '>' ).\n\t\t\t\tgsub( /</n, '<' )\n\t\tend",
"title": ""
},
{
"docid": ... |
7e2c7009292bad3dc5505374871e79ab | GET /uders/new GET /uders/new.json | [
{
"docid": "7bba597d3212737af4a29a5425b0b2ba",
"score": "0.7862924",
"text": "def new\n @uder = Uder.new\n\n respond_to do |format|\n format.html # new.html.erb\n format.json { render json: @uder }\n end\n end",
"title": ""
}
] | [
{
"docid": "e4b92b76df5db164b1d97ca60e7f502b",
"score": "0.73085505",
"text": "def create\n @uder = Uder.new(params[:uder])\n\n respond_to do |format|\n if @uder.save\n format.html { redirect_to @uder, notice: 'Uder was successfully created.' }\n format.json { render json: @uder... |
4dd598c375794a0017b96d022bbcf2f2 | Vidurkiai TODO sitie turetu buti self | [
{
"docid": "3ac2ddfba7d7e983b3acd9c1ad54b222",
"score": "0.0",
"text": "def avg_score_vote\n sql=<<-SQL\n select\n sum(\n case action\n when 1 then 0\n when 2 then 0\n when 3 then 1\n when 4 then 1\n when 5 then 1\n end\n ) / count(*) as sant\n from votes\n ... | [
{
"docid": "ad244bd0c45d5d9274f7612fa6fee986",
"score": "0.68121207",
"text": "def suivre; end",
"title": ""
},
{
"docid": "07f4aba74008200310213b63a5f3de3f",
"score": "0.6570504",
"text": "def zuruecksetzen()\n end",
"title": ""
},
{
"docid": "eae44d68a107a1dee14f3ddfdd... |
1fc8083dc12b5d91b635e6809ab401f9 | set job status to be draft, you still need to save it outside | [
{
"docid": "d6b7def1c1c997260865fb4e26069878",
"score": "0.7279912",
"text": "def set_status_draft\n General::ChangeStatusService.new(self, StatusLancer::DRAFT).change\n end",
"title": ""
}
] | [
{
"docid": "5a38e2357740efb864313ffd94e09dce",
"score": "0.7463821",
"text": "def draft!\n self.update_attribute(:status, DRAFT)\n end",
"title": ""
},
{
"docid": "9714fd90665eba8598cb0a45957b93d7",
"score": "0.7193648",
"text": "def set_draft\n self.update_attributes(status... |
64c3f11f031b50afe826a7495942f51c | Creates a bundle of d20s | [
{
"docid": "becc8b91ad4f6469730596fe5f9cbe53",
"score": "0.4873639",
"text": "def d20\n if self == 1\n GamingDice::Dice.new(faces: 20)\n else\n GamingDice::DicePool.new(\n Array.new(self) { GamingDice::Dice.new(faces: 20) }\n )\n end\n end",
"title": ""
}
] | [
{
"docid": "4aab5781eb6c9d4f00d9dea154898f37",
"score": "0.5823465",
"text": "def create_bundle(attributes)\n BrickFTP::API::Bundle.create(attributes)\n end",
"title": ""
},
{
"docid": "4aab5781eb6c9d4f00d9dea154898f37",
"score": "0.5823465",
"text": "def create_bundle(attrib... |
f22e4a620829f652ec928d9464557b4b | Render markdown text to html tags | [
{
"docid": "9ea464a8c37efa11247b4f73a479fbd4",
"score": "0.7605083",
"text": "def render_markdown(md)\n markdown = Redcarpet::Markdown.new(Redcarpet::Render::HTML)\n markdown.render(md)\n end",
"title": ""
}
] | [
{
"docid": "b317616fa0eaf071b0489c0e1ceda6f4",
"score": "0.82781386",
"text": "def html_markup_markdown(text); end",
"title": ""
},
{
"docid": "cd5b1c71573b9b944471fd30e37ba7d6",
"score": "0.8058679",
"text": "def process_markdown(text)\n Markdown.new(text, :smart, :tables).to_htm... |
a76372485dab37b7fc7f32a33b8e9884 | GET /leads/new GET /leads/new.json | [
{
"docid": "80d988d691cd0ef542991878cab88dee",
"score": "0.0",
"text": "def new\n @lead = Lead.new\n session.delete(:click_url)\n @partyid = params[:partyid]\n @zipcode = params[:zipcode]\n @test_ind = params[:test_ind]\n @click_url = params[:click_url]\n @listingid = params[:listin... | [
{
"docid": "893df69a589745bec240acf2fb82b4de",
"score": "0.80036056",
"text": "def new\n @lead = Lead.new\n\n respond_to do |format|\n format.html # new.html.erb\n format.json { render json: @lead }\n end\n end",
"title": ""
},
{
"docid": "893df69a589745bec240acf2fb82b4de... |
eeb85d5a0178fa1c8591ec464f8f0b0a | Returns the preset choices for this custom attribute, one per line. | [
{
"docid": "78492d9fb54a20bbee70de3199d8502e",
"score": "0.65336496",
"text": "def choices_as_text\n values = custom_attribute_choices.map { |c| c.value }\n values.join(\"\\n\")\n end",
"title": ""
}
] | [
{
"docid": "a9533c5d719a2ec1b5c0d4ff435e512c",
"score": "0.5861989",
"text": "def choices\n @@choices\n end",
"title": ""
},
{
"docid": "2f29415794726c417d90dc6832b26a58",
"score": "0.5805058",
"text": "def choices_as_text=(str)\n choice_values = str.split(\"\\n\").map { |s| s... |
26d0fb505a80abecfef71c1d24f9dc2d | GET /childmasters/new GET /childmasters/new.xml | [
{
"docid": "0faab580496a1500cb15fc978764e2ac",
"score": "0.65251434",
"text": "def new\n @childmaster = Childmaster.new\n \t\n\t#Get the org_code and org_location in people table based on user id.\n\t@people=Person.find_by_id(params[:user_id])\n\tif(@people.code_option==0)\n\t\t@org_code=@people.... | [
{
"docid": "4430a1a273514f2fa5571083f53d2b8a",
"score": "0.72692364",
"text": "def new\n @childmaster = Childmaster.new\n\n respond_to do |format|\n format.html # new.html.erb\n format.json { render json: @childmaster }\n end\n end",
"title": ""
},
{
"docid": "7e38ae83ceb... |
c6234d51bc67612720fc8e41d90777a5 | POST /marathons POST /marathons.json | [
{
"docid": "ad3e3b56b98c8d282cdadf60b187e6fa",
"score": "0.62276053",
"text": "def create\n @marathon = Marathon.new(params[:marathon])\n\n respond_to do |format|\n if @marathon.save\n format.html { redirect_to @marathon, notice: 'Marathon was successfully created.' }\n format.j... | [
{
"docid": "2545c3620860d077dced8312ad55a86e",
"score": "0.6401499",
"text": "def create\n @marathon = Marathon.new(marathon_params)\n\n respond_to do |format|\n if @marathon.save\n flash[:success] = \"#{@marathon.name} was successfully created.\"\n format.html { redirect_to mar... |
4959139201d7667b09f18efe5d8a9d1b | Create all address hash key value pairs so that we still function if we were only provided with one or two of them | [
{
"docid": "c4192784107274b190f44e0a883a2b46",
"score": "0.6072492",
"text": "def setup_address_hash(options)\n options[:billing_address] = options[:billing_address] || options[:address] || {}\n options[:shipping_address] = options[:shipping_address] || {}\n end",
"title": ""
}
... | [
{
"docid": "4b92a0fc323851f57e8b5af8d1913cef",
"score": "0.7169385",
"text": "def make_addr_hash(symb_array = @addr_sym_array, addr_array = @coordinates)\n\t placeholder = {}\n\t\taddr_array.each_with_index { |v, i| placeholder.store(symb_array[i], v) }\n\t\t@addr_hash = placeholder\n\t\treturn placeh... |
311e9ec2cba31d2582241f87f50ef6e9 | Clamp the number to a specific range Examples: 234234234523.clamp(0..100) => 100 12.clamp(0..100) => 12 38817112.clamp(0..100) => 0 | [
{
"docid": "520af572979bbe29b8c387386b0771f9",
"score": "0.7332175",
"text": "def clamp(range)\n if self < range.first\n range.first\n elsif self >= range.last\n if range.exclude_end?\n range.last - 1\n else\n range.last\n end\n else\n self\n end\n end... | [
{
"docid": "73f1a10549cf80c29c9600fa6ba7d2dc",
"score": "0.81432056",
"text": "def clamp(value, min, max); end",
"title": ""
},
{
"docid": "d26fb5a6021b1e0c69d1ba46fca8b1df",
"score": "0.7977643",
"text": "def clamp(min, max); end",
"title": ""
},
{
"docid": "7a3f01d989f0... |
1ac7eb892e7917fc2e89979c41477882 | POST /admin/forms POST /admin/forms.json | [
{
"docid": "caf7acb491369f27b7b38a3915e92dc8",
"score": "0.6830222",
"text": "def create\n @admin_form = PageTemplate.new(admin_form_params)\n @admin_form.page_type = :form\n @admin_form.save\n\n params[:field].each do |k,v|\n form_item_params = params[:field][k].permit(:name, :data, :p... | [
{
"docid": "12fc3af113fe59897da2c8284d903396",
"score": "0.7034801",
"text": "def create\n @filled_form = @filled_forms.new(params[:filled_form], as: :admin)\n @filled_form.save\n respond_with :admin, @form, @filled_form\n end",
"title": ""
},
{
"docid": "ef41e881b53172dbbaa71c8181... |
78ba81262eb3198bd3791846793b16be | Adds a text watermark to each slide of the presentation. Text watermark can be setup via method arguments or withing Shape DTO for detailed customization. Both options are applicable simultaneously. | [
{
"docid": "a456dd5ee6f36f8c0a5d4b897e7e418c",
"score": "0.5872686",
"text": "def create_watermark_online_with_http_info(document, shape = nil, font_height = nil, text = nil, font_name = nil, font_color = nil, password = nil)\n if @api_client.config.debugging\n @api_client.config.logger.debu... | [
{
"docid": "8aa7f91be835492e2d918256342ed1a3",
"score": "0.7346921",
"text": "def add_watermark(text, options={})\n raise ReadOnlyError.new('Previously saved pdfs are read-only') if @saved\n\n x = options[:x] || @reader.crop_box(1).width / 2\n y = options[:y] || @reader.crop_box(1).height... |
9a74625a6340ca9be94e9de47341b041 | GET /recurring_events/1 GET /recurring_events/1.json | [
{
"docid": "bf568eecdc1636c49f5d1ea64b72b0ef",
"score": "0.58920556",
"text": "def show\n @location = Location.find( @recurring_event.location_id )\n @myevent = RecEventFollow.find_by_user_id_and_recurring_event_id( current_user.id, @recurring_event.id )\n authorize! :show, @recurring_event, :m... | [
{
"docid": "8ce774359d7c499f8f949dee7c7524ec",
"score": "0.7480162",
"text": "def index\n @recurring_events = RecurringEvent.all \n end",
"title": ""
},
{
"docid": "a14fde8d2788ca0f909cdc1ba0f47d5a",
"score": "0.7038882",
"text": "def set_recurring_event\n @recurring_event ... |
d912bdb79ec13294b624162f6ca214dd | Call this from inside a daemonized process to complete the initialization process | [
{
"docid": "a632eb445e40c2904f599c961d60a211",
"score": "0.6740449",
"text": "def running!\n DaemonKit::Initializer.continue!\n end",
"title": ""
}
] | [
{
"docid": "6a9b0e75d8e1761788a4ab0127bb29c7",
"score": "0.71120137",
"text": "def start\n parse_options\n\n if @daemon\n require \"facets/daemonize\"\n\n daemonize()\n\n # Save a process sentinel file.\n FileUtils.touch(File.join(\".temp\",\"d#{Process.pid}.pid\"))\n end\n ... |
e46a170dbb79d5eefa1102d33f3dfdf5 | method getting logo of page returns hash with informations of logo source and href | [
{
"docid": "adde37b7ac8846e44cdbb906f3cec6ca",
"score": "0.7175131",
"text": "def logo \n logo = @@doc.xpath(\"//div[contains(@id, 'logo')]\")\n logo += @@doc.xpath(\"//div[contains(@class, 'logo')]\")\n # najdenie href = .... skript\n logo_href = logo.xpath(\".//a//@href\")\n logo_src = ... | [
{
"docid": "63b9fd3495131dd2afd25e6e7fb36f17",
"score": "0.69383717",
"text": "def getLogo( a, b, c, d)\n params = Hash.new\n params['a'] = a\n params['b'] = b\n params['c'] = c\n params['d'] = d\n return doCurl(\"get\",\"/logo\",params)\n end",
"title": ""
},
{
"docid": "... |
7771053f04f5a5c77d35768abb4fd9c0 | Calculate the velocity for one axis. | [
{
"docid": "5bfdbce55230a4d80d8e4dfc1040d684",
"score": "0.7207147",
"text": "def update_vel_axis( v, a, dt )\n\n # Apply slowdown if not accelerating.\n if a == 0\n if v > 0\n v -= SLOWDOWN * dt\n v = 0 if v < 0\n elsif v < 0\n v += SLOWDOWN * dt\n v = 0 if v... | [
{
"docid": "60f4297a0d1983f3e4291eacd94aad6e",
"score": "0.74107087",
"text": "def velocity\n end",
"title": ""
},
{
"docid": "a2e3ce14531266db668719c968c9eb03",
"score": "0.7393727",
"text": "def vel\n Math::hypot(@vx, @vy)\n end",
"title": ""
},
{
"docid": "01f51... |
6d41413ee54cf943725b901aac57b997 | POST /benefits POST /benefits.json | [
{
"docid": "41d5e92987cc78cf849582c10e89e439",
"score": "0.7406117",
"text": "def create\n @benefit = Benefit.new(benefit_params)\n\n respond_to do |format|\n if @benefit.save\n format.html { redirect_to @benefit, notice: 'Benefit was successfully created.' }\n format.json { ren... | [
{
"docid": "478ccc462cbc236d9168c239d56f141a",
"score": "0.70132416",
"text": "def create\n benefit = Benefit.create benefit_params\n redirect_to new_benefit_path\n end",
"title": ""
},
{
"docid": "2ed98d519cb26dc4a9ed9ce5bf5e4617",
"score": "0.67890376",
"text": "def post_ben... |
d9669c88fbc2f5bd6ccb54399f42d91f | POST /contractorpos POST /contractorpos.json | [
{
"docid": "f3c2f105df02df9b956f3b6b7100df41",
"score": "0.74756",
"text": "def create\n @contractorpo = current_user.contractorpos.build(contractorpo_params)\n # @contractorpo = Contractorpo.new(contractorpo_params)\n\n respond_to do |format|\n if @contractorpo.save\n format.html {... | [
{
"docid": "8b405c20d8e7bf2a0c43d1474638837d",
"score": "0.67675024",
"text": "def create\n @contractor = Contractor.new(params[:contractor])\n\n respond_to do |format|\n if @contractor.save\n format.html { redirect_to @contractor, notice: 'Contractor was successfully created.' }\n ... |
d1962b5f7f776c80606bd9287ae8c59a | create_base_helpers: Creates controller_name and action_name helper methods, every time an ActionParameter instace is created. | [
{
"docid": "89b6fcefb2339a5856a3a2786af0c9ac",
"score": "0.8361042",
"text": "def create_base_helpers\n locals = { controller_name: params[:controller],\n action_name: params[:action] }\n create_methods(locals)\n end",
"title": ""
}
] | [
{
"docid": "d80c5234d75fa5394ada760bc4325555",
"score": "0.6476706",
"text": "def initialize_controller_helpers(ctx)\n ctx.extend(ControllerLevelHelpers)\n end",
"title": ""
},
{
"docid": "1f016437f7d547e3bbb1fe8488ac8746",
"score": "0.6288953",
"text": "def create_helper\n end"... |
803e96d354f9e76b6521ef739acd7eb4 | See deprecation comment for `record_create` | [
{
"docid": "87edcbc57a91e1b73f01a136757ca400",
"score": "0.0",
"text": "def clear_version_instance!\n paper_trail.clear_version_instance\n end",
"title": ""
}
] | [
{
"docid": "504132f2ff9f5d0b320de9c3a33c9a52",
"score": "0.77219164",
"text": "def create_record\n raise_must_override\n end",
"title": ""
},
{
"docid": "ba56d1206b49a10d345f0bbe896782ea",
"score": "0.74224806",
"text": "def create_record!(record)\n @created += 1\n begin\n ... |
be52e653cae4a37d643459c4f5fabf83 | DELETE /vendors/1 DELETE /vendors/1.json | [
{
"docid": "b405f59ab49dbf1e40e87e0d0e668b0c",
"score": "0.7469282",
"text": "def destroy\n @vendor.destroy\n\n respond_to do |format|\n format.html { redirect_to vendors_url }\n format.json { head :ok }\n end\n end",
"title": ""
}
] | [
{
"docid": "c970bf35ec636eb0e766deb6813bcfdc",
"score": "0.7528686",
"text": "def destroy\n @vendor = Vendor.find(params[:id])\n @vendor.destroy\n\n respond_to do |format|\n format.html { redirect_to admin_vendors_url }\n format.json { head :ok }\n end\n end",
"title": ""
},... |
f74c29bdfc4a183e1ec1b91334cd5be2 | Use callbacks to share common setup or constraints between actions. | [
{
"docid": "e909908eb24e14f9ac6da5b5a2f53c16",
"score": "0.0",
"text": "def set_subject\n @subject = Subject.find(params[:id])\n end",
"title": ""
}
] | [
{
"docid": "631f4c5b12b423b76503e18a9a606ec3",
"score": "0.60339177",
"text": "def process_action(...)\n run_callbacks(:process_action) do\n super\n end\n end",
"title": ""
},
{
"docid": "7b068b9055c4e7643d4910e8e694ecdc",
"score": "0.60135007",
"text": "d... |
4f2cac5535fff353f6d6b65320a1db6d | Schemas are stored by name, provided that the name is unique. If the unqualified name is ambiguous then it is removed from the cache. A set of unqualified names is kept to avoid reloading files for ambiguous references. | [
{
"docid": "ff8795663552d1f858e0668f6878aebf",
"score": "0.64874583",
"text": "def store_by_name(object, name = object.name.to_s)\n if schema_objects.key?(name)\n schema_objects.delete(name)\n elsif !schema_names.include?(name)\n schema_objects.store(name, object)\n ... | [
{
"docid": "8a1ddca38702af50919eba0d56caa43e",
"score": "0.63887924",
"text": "def cache\n @@schema_cache\n end",
"title": ""
},
{
"docid": "424b45f2de7086ba0638d309a3686d47",
"score": "0.6312942",
"text": "def schema_cache; end",
"title": ""
},
{
"docid": "424b45... |
0e30963afc1b75b2d93962a46710b24f | Disegna gli oggetti equipaggiati | [
{
"docid": "9f0ba3a95b77a8467cc9e2d6ea8314a3",
"score": "0.57395077",
"text": "def draw_equipment_items\n change_color(normal_color)\n (0..actor.equip_type.size).each {|i| draw_item(i) }\n end",
"title": ""
}
] | [
{
"docid": "17e55a430dab39a2e108e616f482d518",
"score": "0.6446519",
"text": "def seguro(equipo)\n update_attribute(:equipo_id, equipo)\n end",
"title": ""
},
{
"docid": "3fc03235dd336b6195ae89c3f6995991",
"score": "0.64000076",
"text": "def equip; @equip; end",
"title": ""
... |
c6174c478e80a341b815e572bbc7cc9b | GET /todos/search todos_search path | [
{
"docid": "86edef8380193bc35fefa05e559cd18e",
"score": "0.0",
"text": "def movies\n # @todos = Todo.where(task: params[:task])\n @movies = Imdb::Search.new(params[:name]).movies\n# render \"index\"\n\n end",
"title": ""
}
] | [
{
"docid": "15aedfb5308e34c8021d8fa26b12a273",
"score": "0.87687606",
"text": "def search\n @todos = Todo.search(params)\n end",
"title": ""
},
{
"docid": "6ffc1d423fb917a24fc6f263db8e6361",
"score": "0.7769273",
"text": "def index\n @search = params[:search].nil? ? '' : param... |
40a4c12c7dd6d81ed9d98622050d9877 | used by the sanitise method | [
{
"docid": "d35b864877e454c761e7c38d9d8ead89",
"score": "0.0",
"text": "def code2indent(s2)\n\n # find the beginning\n x1 = s2 =~ /^```/ \n return s2 unless x1\n\n # find the end\n x2 = s2[x1+3..-1] =~ /^```/\n return s2 unless x2\n \n codeblock = s2[x1+3..x1+x2+2]\n\n s3 =... | [
{
"docid": "62247ba314c2f4d0f6b117ebee04870c",
"score": "0.79623234",
"text": "def sanitize; end",
"title": ""
},
{
"docid": "2c395b95bd4fc442fc02481ce7cc8183",
"score": "0.75175804",
"text": "def sanitize(s); end",
"title": ""
},
{
"docid": "be72d6052ae7e7754097857788823... |
b68460a81177162c7de1af6c190d731c | Here is the test for two pair | [
{
"docid": "a9eb3666ce62e6ea9008fe7317050a5e",
"score": "0.6351363",
"text": "def white_two_pair(white_numbers)\n white = white_numbers\n if ((white[0] == white[1]) && (white[2] == white[3])) || ((white[0] == white[1]) && (white[3] == white[4])) || ((white[1] == white[2]) && (white[3] == white[4])... | [
{
"docid": "abd861d1e6635bd064a76292640ad98a",
"score": "0.7608385",
"text": "def test_two_letters_one_pair\r\n\t\tresults = pairs(['A', 'B'])\r\n\t\tassert_equal(1, results.count)\r\n\tend",
"title": ""
},
{
"docid": "35bf2ccac2a69afc769108c29bf61356",
"score": "0.7534222",
"text": ... |
18b87300c9eaf77646fc587a9c90d217 | POST /dpoutgoings POST /dpoutgoings.json | [
{
"docid": "a1752d140ed58e84ecd9edab3ed8a8b9",
"score": "0.556301",
"text": "def create\n @dpoutgoing = Dpoutgoing.new(dpoutgoing_params)\n\n respond_to do |format|\n if @dpoutgoing.save\n format.html { redirect_to @dpoutgoing, notice: 'Dpoutgoing was successfully created.' }\n ... | [
{
"docid": "af58c1576d998c2993bbf5c37b6b432a",
"score": "0.62863547",
"text": "def index\n @dpoutgoings = Dpoutgoing.all\n end",
"title": ""
},
{
"docid": "d88a264f20dc1e264b9304755a21ace0",
"score": "0.62208503",
"text": "def create_posting(postings)\n postings = [postings] u... |
4cd24582a2f727fc3f19582e638f9ec6 | Return all match data. | [
{
"docid": "76e33fe7d6f79030ae8d68f56e4844c6",
"score": "0.0",
"text": "def matches(str)\n each_match(str).to_a\n end",
"title": ""
}
] | [
{
"docid": "98131226aa7b50922b264c811ba52183",
"score": "0.74906856",
"text": "def matchdata\n @matchdata\n end",
"title": ""
},
{
"docid": "25836bec1e42d02f6c8666104a6620da",
"score": "0.7263926",
"text": "def all_matches\n\t\t@@logger.info { \"Retrieving all matches.\" } if... |
5ddae5712f27ee9705331588c54cd921 | Perform Author: Tejas Date: 30/05/2019 Reviewed By: | [
{
"docid": "b030335a6d74ef9ad7992047cf031b6a",
"score": "0.0",
"text": "def perform\n r = validate_and_sanitize\n return r unless r.success?\n\n r = add_payment_method\n return r unless r.success?\n\n r = mark_default_false_to_other_payment_methods\n return r unless r.succe... | [
{
"docid": "80a62870302f2e702d9f678c713e4922",
"score": "0.62194914",
"text": "def author\n 'Department of Veterans Affairs'\n end",
"title": ""
},
{
"docid": "ed8f7b2514a2e125f2802739f2b1f35d",
"score": "0.5963277",
"text": "def atest_ID_25863_reposted_review()\n ... |
4e904bb37ab86c2e6c0259d8e2690d9a | convienence method to get the shipping_category_id of the product | [
{
"docid": "bb22ba30e6e9f35bbca684bdf0b079d9",
"score": "0.90138984",
"text": "def shipping_category_id\n product.shipping_category_id\n end",
"title": ""
}
] | [
{
"docid": "afed4335b4e56af822aabbeeb49b7692",
"score": "0.73133695",
"text": "def shipping_categories\n\t self.line_items.collect {|l| l.product.shipping_category_id}.uniq\n end",
"title": ""
},
{
"docid": "ede29a177f062be9ae771b6b86fe878f",
"score": "0.7273212",
"text": "def ship... |
f74c29bdfc4a183e1ec1b91334cd5be2 | Use callbacks to share common setup or constraints between actions. | [
{
"docid": "1b04e85fe0dc0ae200e5b17132c38b6a",
"score": "0.0",
"text": "def set_parse\n @orig_parse = Parse.find(params[:parse_id])\n @parse = Parse.new course: @orig_parse.course, xls_file: @orig_parse.xls_file\n end",
"title": ""
}
] | [
{
"docid": "bd89022716e537628dd314fd23858181",
"score": "0.6162554",
"text": "def set_required_actions\n # TODO: check what fields change to asign required fields\n end",
"title": ""
},
{
"docid": "3db61e749c16d53a52f73ba0492108e9",
"score": "0.60452986",
"text": "def action_hook... |
b9ddc4b306519299864dffde3b536d95 | rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity, Metrics/PerceivedComplexity, Layout/LineLength | [
{
"docid": "ea0cf41cfb6cfb3556b570930f4c8eba",
"score": "0.0",
"text": "def validate_decorator!(decorator_name, decorator_receiver, bound_method = nil)\n return if decorator_receiver.respond_to?(decorator_name)\n\n location_hint = if bound_method\n method_receiver = bound_method.receive... | [
{
"docid": "ef1e4c0cc26e4eec8642a7d74e09c9d1",
"score": "0.7219576",
"text": "def private; end",
"title": ""
},
{
"docid": "0b8b7b9666e4ed32bfd448198778e4e9",
"score": "0.60477847",
"text": "def probers; end",
"title": ""
},
{
"docid": "3660c5f35373aec34a5a7b0869a4a8bd",
... |
43daba46fc114819a25b652d379cb53e | Disable implicit links to documents | [
{
"docid": "102b97879b8e7a384ea9b913795e551d",
"score": "0.0",
"text": "def link_to_document(doc, field_or_opts, opts = { counter: nil })\n label = case field_or_opts\n when NilClass\n view_context.document_presenter(doc).heading\n when Hash\n opts = fi... | [
{
"docid": "1e19986ce6aad464467d28656c7dcc0d",
"score": "0.7094497",
"text": "def disable_link\n @disable_link = true\n end",
"title": ""
},
{
"docid": "e2d48df1618ed475a1653fa31ec60a2c",
"score": "0.6508466",
"text": "def discard_doc!\n links # force parsing of page links b... |
dc8a5f73091bbf8301a9cb3befe3e698 | GET /admin/brokers/1 GET /admin/brokers/1.json | [
{
"docid": "a81945373733e4951b987de6ea99f9a1",
"score": "0.0",
"text": "def show\n end",
"title": ""
}
] | [
{
"docid": "33b31ad99ae98fa28cb9069e8d5b6f98",
"score": "0.7035324",
"text": "def brokers\n {\n zerodha: 'Zerodha'\n }\n end",
"title": ""
},
{
"docid": "015d0b827260cf17be8f12e60a5205ba",
"score": "0.7007499",
"text": "def index\n @brokers = Broker.all\n end"... |
a7db4324023e8bc73cfcf4993630fbae | Autocorrect by swapping between two nodes autocorrecting them source://rubocoprails//lib/rubocop/cop/rails/active_record_callbacks_order.rb73 | [
{
"docid": "022b56975b9b3844907e4f02f7272732",
"score": "0.73878306",
"text": "def autocorrect(corrector, node); end",
"title": ""
}
] | [
{
"docid": "5c6d9416b03e226e130cc9fa5bdcd511",
"score": "0.7220113",
"text": "def autocorrect(_node)\n succeeding_node = @offensive_nodes[0]\n preceding_node = @offensive_nodes[1]\n lambda do |corrector|\n reorder_components(corrector, succeeding_node, preceding_nod... |
bbe5b810850abd6762f7fe1f6dd53c71 | Returns the digital wallet checkbox on the Credit Card Info page. | [
{
"docid": "2f10bc7c43edf2b516c86b3b40ff56bb",
"score": "0.5141019",
"text": "def chkoutadd_digital_wallet\n $tracer.trace(__method__)\n return ToolTag.new(input.className(create_ats_regex_string(\"ats-addcctowallet\")), __method__)\n end",
"title": ""
}
] | [
{
"docid": "fbc097caa7cf2733529b54f2367ee7ca",
"score": "0.6365111",
"text": "def pswdprtct; det.checkbox(:id, 'enableWebPassword'); end",
"title": ""
},
{
"docid": "d81d2e52c4f60c722678b6a0f2aa8c37",
"score": "0.61335474",
"text": "def v3_acc_read(number); det.checkbox(:name, 'rAcc'... |
de7da69f2fc64afa49b9a5f630c6e9e8 | pop two, return quotient | [
{
"docid": "b73e49d3bc419b1ed403d1de96d7f8ff",
"score": "0.5705947",
"text": "def divide\n error_msg\n first = @inputs.pop\n second = @inputs.pop\n @inputs.push( second.to_f / first )\n end",
"title": ""
}
] | [
{
"docid": "273d8a54cdf267d0fa96da1b089c0920",
"score": "0.7306298",
"text": "def divide\n \toperand1 = pop\n \toperand2 = pop\n \tstack << (operand2 / operand1)\n end",
"title": ""
},
{
"docid": "073ad512a3bbba34c02e0d4bed119ef2",
"score": "0.7265167",
"text": "def divide\n\t\tsecon... |
f82cc21599f7252ada73c53e8a2ce7c0 | Endpoint to return all the Physician users | [
{
"docid": "b4d752a8dedc81e99848a54bfdfe72f1",
"score": "0.74266374",
"text": "def physicians\n physicians = User.physicians\n render json: { status: 200, data: physicians }\n end",
"title": ""
}
] | [
{
"docid": "a4046f8f83c1697434892752e53b1328",
"score": "0.7618796",
"text": "def index\n @physicians = Physician.where(user_id: current_user.id)\n @users = User.where(id: current_user.id)\n end",
"title": ""
},
{
"docid": "de3b087f20ee65746adea1959f862485",
"score": "0.7057887",
... |
09af1de14f35b6ef0119045abf09ff3f | GET /Render the JQGrid for bay maintenance | [
{
"docid": "592fb093a2a991d26364ecb263752abc",
"score": "0.6931349",
"text": "def index\n if params[:lightweight] != \"yes\" \n get_header_details\n end\n columns = ['id','sm_bay_id', 'cl_bay_id','description','client_id','sm_aisle_id','cl_aisle_id',\n 'aisle_id','sm_zo... | [
{
"docid": "58c5e6046f53bc92461a3853873b446b",
"score": "0.75003475",
"text": "def jqgrid\n\n\tend",
"title": ""
},
{
"docid": "7fe0be629bddf9a5582a3b9a546813c5",
"score": "0.7380364",
"text": "def index\n\n get_header_details if !request.xhr?\n columns = ['id', 'name_of_pe... |
22ef633ead25863904611ed13dcaa24f | List source import large files | [
{
"docid": "2939197929d6632c00d2dec3915f82c1",
"score": "0.6702011",
"text": "def source_import_large_files(repo, options = {})\n options = ensure_api_media_type(:source_imports, options)\n get \"#{Repository.path repo}/import/large_files\", options\n end",
"title": ""
}
] | [
{
"docid": "3157c17c9a87b24113e376060ac444dc",
"score": "0.70314145",
"text": "def source_files; end",
"title": ""
},
{
"docid": "1f7e829c6624267e31f09d11e30ab464",
"score": "0.6979955",
"text": "def source_import_large_files(repo, options = T.unsafe(nil)); end",
"title": ""
},... |
46c385af97957af88b7cba709b671b8e | the id function needs to return the primary key and is used to build the links | [
{
"docid": "aed80a6404bbbb1a93832ce582b15e71",
"score": "0.0",
"text": "def to_param\n username\n end",
"title": ""
}
] | [
{
"docid": "949c5e2dfae7d74d8af81fb7f1f008b6",
"score": "0.7140436",
"text": "def id; end",
"title": ""
},
{
"docid": "949c5e2dfae7d74d8af81fb7f1f008b6",
"score": "0.7140436",
"text": "def id; end",
"title": ""
},
{
"docid": "949c5e2dfae7d74d8af81fb7f1f008b6",
"score"... |
aee92d56d359481a8e65ead68b475397 | GET /bundlelinks/1 GET /bundlelinks/1.json | [
{
"docid": "a81945373733e4951b987de6ea99f9a1",
"score": "0.0",
"text": "def show\n end",
"title": ""
}
] | [
{
"docid": "224ca8978935aa6b253716b557a3c6d1",
"score": "0.7314525",
"text": "def index\n @bundlelinks = Bundlelink.my_bundles(current_user)\n end",
"title": ""
},
{
"docid": "75e0715fb6b4140c83e3918d21a642bc",
"score": "0.66483843",
"text": "def set_bundlelink\n @bundlelink... |
0dd9c4b9cd8e294aae2a2cee256d25a1 | invoke the specified API method on the specified service | [
{
"docid": "c0bd9ff3f4a8dce6f6458e5ddcacf807",
"score": "0.71545655",
"text": "def invoke_delegated(service_name, method_name, *args)\r\n prepare_request(service_name.to_s, service_name, method_name, *args)\r\n @controller.process(@request, @response)\r\n decode_rpc_response\r... | [
{
"docid": "902dad247f7fd2d8675154fcfcd50cd9",
"score": "0.7584425",
"text": "def invoke_layered(service_name, method_name, *args)\r\n prepare_request('api', service_name, method_name, *args)\r\n @controller.process(@request, @response)\r\n decode_rpc_response\r\n end",... |
7564db03dbc39e5cb8971fcbb4ab753b | Provide a detailed, user friendly representation source://twilioruby//lib/twilioruby/rest/taskrouter/v1/workspace.rb451 | [
{
"docid": "473108fa97cee58671b779c2ccfec06f",
"score": "0.0",
"text": "def inspect; end",
"title": ""
}
] | [
{
"docid": "3211e34cf183fef164a1dd77fb437a32",
"score": "0.7410156",
"text": "def inspect\n context = @solution.map{|k, v| \"#{k}: #{v}\"}.join(',')\n \"#<Twilio.Taskrouter.V1.WorkspaceStatisticsContext #{context}>\"\n end",
"title": "... |
458f04b13aa654647122b837158936c3 | redefine your position_taken? method here, so that you can use it in the valid_move? method above. | [
{
"docid": "7f5fcd49a29adf569fb645bbff54fb04",
"score": "0.0",
"text": "def position_taken?(board, index)\n return false if board[index] == ' ' || board[index] == '' || board[index] == nil\n true\nend",
"title": ""
}
] | [
{
"docid": "925974888641d3474d6e8f43478dd9e5",
"score": "0.8409121",
"text": "def position_taken?(board, position)\n return false if valid_move?(board, position)\n return true unless valid_move?(board, position)\nend",
"title": ""
},
{
"docid": "c3a06411de78e7ca82b9f6e428f8277b",
"scor... |
f260b0743e3635ff851ba1fb8f391b00 | GET /users/1 GET /users/1.json | [
{
"docid": "a81945373733e4951b987de6ea99f9a1",
"score": "0.0",
"text": "def show\n end",
"title": ""
}
] | [
{
"docid": "4152fb6556ae83f7cdd6c362f17ad9bf",
"score": "0.81046426",
"text": "def index\n if params[:single]\n\t url = \"#{API_BASE_URL}/users/#{params[:id]}.json\"\n\t response = RestClient.get(url)\n\t @user = JSON.parse(response.body)\n\telse\n\t url = \"#{API_BASE_URL}/users.json\"\t \n ... |
2d99732541ecdd5a69367bfe4a670f6c | Create or update remote file | [
{
"docid": "351a04e8a150ceb91f2df11f8796b6f1",
"score": "0.63422537",
"text": "def update_remote_file_content_without_validation\n update_remote_file_content(content: applied_remote_file_content, path: path)\n end",
"title": ""
}
] | [
{
"docid": "d60b7d73c524dd42aeb6c060c56ffc8f",
"score": "0.7211444",
"text": "def update_remote_file(node_id, options)\n post \"/cluster/#{node_id}/files\", options\n end",
"title": ""
},
{
"docid": "421e5b4286b05098c8c8437474ce3fa3",
"score": "0.6926576",
"text": "de... |
2f8aceb5607dc28f7836b267b635fee7 | GET /gp40s GET /gp40s.json | [
{
"docid": "a3e22f14f275a404c69bf734ff473dd8",
"score": "0.6121918",
"text": "def index\n @gp40s = Gp40.all\n @gp40s = duration(@gp40s, params)\n end",
"title": ""
}
] | [
{
"docid": "ab0983885006924ebca208ff1af4706f",
"score": "0.60532016",
"text": "def index\n @gpsds = Gpsd.all\n #respond_to do |format|\n # format.json { render }\n #end\n end",
"title": ""
},
{
"docid": "285e13d96481e6b7148547f0f994c910",
"score": "0.5956433",
"text": "... |
f74c29bdfc4a183e1ec1b91334cd5be2 | Use callbacks to share common setup or constraints between actions. | [
{
"docid": "62661848599d085f3707e09d8973b2e0",
"score": "0.0",
"text": "def set_usercenter_bankcard\n @usercenter_bankcard = Usercenter::Bankcard.find(params[:id])\n end",
"title": ""
}
] | [
{
"docid": "631f4c5b12b423b76503e18a9a606ec3",
"score": "0.60339177",
"text": "def process_action(...)\n run_callbacks(:process_action) do\n super\n end\n end",
"title": ""
},
{
"docid": "7b068b9055c4e7643d4910e8e694ecdc",
"score": "0.60135007",
"text": "d... |
fa137f74ef7811dc12720b71be306684 | ====Description: This is a convenience wrapper around assert_operator. It asserts that lhs < rhs. ====Example: assert_less_than(4, 5) ====Parameters: [lhs] The lefthand side of the comparison. [rhs] The righthand side of the comparison. [message = ""] An optional additional message that will be displayed if the asserti... | [
{
"docid": "26c959fafdd49a3f51af20a1dfe6555f",
"score": "0.8746889",
"text": "def assert_less_than(lhs, rhs, message = \"\")\\\n assert_operator(lhs, :<, rhs, message)\n end",
"title": ""
}
] | [
{
"docid": "81fe26741fa33d819210223d5f3d8d54",
"score": "0.7749168",
"text": "def assert_less_than_or_equal_to(lhs, rhs, message = \"\")\n assert_operator(lhs, :<=, rhs, message)\n end",
"title": ""
},
{
"docid": "7264eecda8533345550a867ba176f805",
"score": "0.75313574",
... |
0f644b0ed062de1d83b5d6413b395c56 | remove outbound link from self to page and inbound link to page from self return self for chaining | [
{
"docid": "6f799d1dfe92601aad3be1f18da50102",
"score": "0.60680753",
"text": "def does_not_link_to! page\n link = Link.first(:source => self, :target => page) and link.destroy\n self\n end",
"title": ""
}
] | [
{
"docid": "3fe167bab3884f48f6b646595f3ec1c8",
"score": "0.6905021",
"text": "def outbound_links= pages\n self._outbound_links.destroy\n pages.respond_to? :each and pages.each do |page|\n self.links_to! page if page.is_a? Page\n end\n end",
"title": ""
},
{
"docid": "f1095996e... |
7ebcc14701e2929c5b5fe844f8d03bcf | POST /repairs POST /repairs.json | [
{
"docid": "8ef6f7b340b25ece9c4d7a5d4c8549bc",
"score": "0.6568475",
"text": "def create\n @repair = @organization.repairs.new(repair_params.merge(user_id: current_user.id, repair_number: Organization.get_next_repair_number(@organization),\n date_of_repair: DateTime.now))\n respond_to do |for... | [
{
"docid": "ed84f0a1de7fe918deafa455fb5db125",
"score": "0.6518728",
"text": "def create\n @repair = Repair.new(params[:repair])\n\n respond_to do |format|\n if @repair.save\n format.html { redirect_to repairs_url, notice: 'Repair was successfully created.' }\n format.json { ren... |
6bfc02c60e24f49cd6e2bcc2d21bacbf | based on a Example: each_r(a,b) do |v1, v2| v2 ? v1 : v2 end | [
{
"docid": "6bc519712735232567883973641937ae",
"score": "0.7129975",
"text": "def each_r(a, b, &blk)\n\trst = {}\n\t_each_r(rst, a, b, &blk)\n\trst\nend",
"title": ""
}
] | [
{
"docid": "ab4bbc60867766e89538f724d9e5da3d",
"score": "0.5835628",
"text": "def each_pair(*) end",
"title": ""
},
{
"docid": "6f732a43c3100eca7cc4845189030aa1",
"score": "0.5766078",
"text": "def each_pair(&block); end",
"title": ""
},
{
"docid": "dc0542ad744e6b2de13d7a... |
37190c4d16ba046bbaa513699a3c0e4e | before_action :set_location, only: [:new, :create, :edit, :update] | [
{
"docid": "198b3ebaa8070424c54066963995ea58",
"score": "0.0",
"text": "def index\n if @user && !@user.photos.empty?\n @photos = User.find(@user.id).photos\n else\n redirect_to new_user_photo_path(@user)\n end \n end",
"title": ""
}
] | [
{
"docid": "b5351a56900a6deba5e4f02ee93b094d",
"score": "0.73958635",
"text": "def set_location\n @location = Location.find(params[:id])\n end",
"title": ""
},
{
"docid": "b5351a56900a6deba5e4f02ee93b094d",
"score": "0.73958635",
"text": "def set_location\n @location = Locatio... |
a2099a77c85e91272ae2f9e35b937953 | Only allow a trusted parameter "white list" through. | [
{
"docid": "59f31744f13223944a76b53ed6fc7ea7",
"score": "0.0",
"text": "def parameter_control_params\n params.require(:parameter_control).permit(:result_no, :generate_no, :e_no, :cond, :day, :mod, :cvp, :pvp)\n end",
"title": ""
}
] | [
{
"docid": "c1f317213d917a1e3cfa584197f82e6c",
"score": "0.7122997",
"text": "def allowed_params\n ALLOWED_PARAMS\n end",
"title": ""
},
{
"docid": "b32229655ba2c32ebe754084ef912a1a",
"score": "0.70535856",
"text": "def expected_permitted_parameter_names; end",
"title": "... |
7efe6ce932ce1a01cfcaade54d4e736e | Define an encoder for your temporal expression. Your encoder should push tokens onto +codes+ in a manner that your +parse_handler+ can handle them. Remember that the temporal expressions minilanguage is a stack machine that pushs arguments onto the stack before your parse handler sees them. | [
{
"docid": "e412cda975cca6520075d6ca0928ad01",
"score": "0.0",
"text": "def encode(codes)\n codes << \"<MyExt::never>\"\n end",
"title": ""
}
] | [
{
"docid": "4c2015d59b302c2bd6a24b932c3a111f",
"score": "0.6539296",
"text": "def encode encoder, options = {}\n if encoder.respond_to? :to_sym\n CodeRay.encode(input, lang, encoder, options)\n else\n encoder.encode_tokens tokens, options\n end\n end",
"title": ""
}... |
06f88ecaa72dbc8f04c21f011817b066 | Prepare site data for site payload. The method maintains backward compatibility if the key 'data' is already used in _config.yml. Returns the Hash to be hooked to site.data. | [
{
"docid": "4f10441ea23ad7386a9531d594079a5e",
"score": "0.74564993",
"text": "def site_data\n @site_data ||= (config[\"data\"] || data)\n end",
"title": ""
}
] | [
{
"docid": "5f8de75afad2c14430a66d2dac62b984",
"score": "0.68798316",
"text": "def site_payload\n old_site_hash = old_site_payload\n old_site_hash[\"site\"].merge!({\"popular_posts\" => self.popular_posts})\n old_site_hash\n end",
"title": ""
},
{
"docid": "... |
bd17c6babac7fe7747425e24f20261bb | load the JUMPS XML xml = File.read("/Users/nowak/Desktop/jumps20140625065155.xml") parser, parser.string = XML::Parser.new, xml get the root of the XML doc = parser.parse root = doc.root find the tags and get the content eve_version = root.attributes[:version] current_time = root.find_first('currentTime').content cache... | [
{
"docid": "805feb49bd47f1242146bd5a4f9bafd8",
"score": "0.7069455",
"text": "def load_raw_data(file_url)\n xml = File.read(file_url)\n parser, parser.string = XML::Parser.new, xml\n\n # get the root of the XML\n doc = parser.parse\n root = doc.root\n\n data = Hash.new\n\n # find th... | [
{
"docid": "195534bee60eb800c34322cd9538636c",
"score": "0.61027855",
"text": "def parse_intro_xml\n \n xml_doc = Document.new File.open(self.intro_xml, 'r')\n self.xml_obj = xml_doc\n \n # Grab clients\n self.clients = []\n xml_doc.elements.each(\"tsung/clients/client\") { |element... |
892572b418dadea4782726219d54ca4f | Generate an expiring URL for downloading a file that is otherwise private. Useful for providing temporary access to files. | [
{
"docid": "a6d1e594b995d84c39762973693e0817",
"score": "0.59116006",
"text": "def temp_url(object_key, temp_url_key, expires_at = Time.now.to_i + 60)\n private_url(\"GET\", object_key, temp_url_key, expires_at)\n end",
"title": ""
}
] | [
{
"docid": "bb99b1bc082bb341f04692eb8b67903e",
"score": "0.77236605",
"text": "def expiring_url(expiring_time=60)\n storage = Fog::Storage.new(self.fog_credentials)\n file = storage.directories \\\n .get(self.fog_directory) \\\n .files.get(self.path)\n return f... |
af65a3835016906f92dc6861aaa3aec6 | Define a method that, given a string of words, returns the word that has the letter "c" closest to the end of it. If there's a tie, return the earlier word. Ignore punctuation. If there's no "c", return an empty string. You may wish to write the helper methods c_distance and remove_punctuation. | [
{
"docid": "80071550a28cacc8fef6f0f73e96af64",
"score": "0.67953765",
"text": "def for_cs_sake(string)\n\n words = string.delete('.,!?').split\n\n words.select! {|word| word.include?('c')}\n\n return '' if words == []\n\n words.sort_by! {|word| word.reverse.index('c')}[0]\n\nend",
"title": ""
... | [
{
"docid": "fe2262f540639ea2cc2c01c8530c4d1d",
"score": "0.80260384",
"text": "def for_cs_sake(string)\n closest_word = \"\"\n closest_distance = 9999\n str_arr = string.split(\" \")\n str_arr.each do |curr_word|\n curr_distance = c_distance(curr_word)\n if curr_distance < closest_distance\n ... |
84033c97bccd9480c096f40de903623e | Returns +true+ if a batch of logs is ready to be sent. | [
{
"docid": "5ce6854661e09689c9d9fe53ef958d3e",
"score": "0.8364924",
"text": "def batch_ready?\n\t\tseconds_since_last_send = Concurrent.monotonic_time - self.last_send_time\n\n\t\treturn self.logs_queue.size >= self.max_batch_size ||\n\t\t\tseconds_since_last_send >= self.batch_interval\n\tend",
"t... | [
{
"docid": "5d8e77771e3601c03ee9b6944d3235dd",
"score": "0.67734367",
"text": "def all_chunks_received?\n start_chunk == nil\n end",
"title": ""
},
{
"docid": "00207c477d6cd1b60506988237c571a4",
"score": "0.6604308",
"text": "def should_call_send_status_for_empty_batch()\n if ... |
3db5a151c397c23e0b88475560ad8c44 | Second Refactoring > 1000s | [
{
"docid": "b389e03d15db68c57271a292f69725fd",
"score": "0.0",
"text": "def EnglishNumber(x)\n if x < 0\n return \"Please enter a positive number.\"\n end\n if x == 0\n return \"zero\"\n end\n\n number_string = ''\n ones = [\"one\", \"two\", \"three\", \"four\", \"five\", \"six\", \"seven\",... | [
{
"docid": "0f828e39ac6c0cb39ceb456b5ed44912",
"score": "0.6120687",
"text": "def warmup; end",
"title": ""
},
{
"docid": "599926eeb7444bf1f9f0cf9d9606f56a",
"score": "0.58488303",
"text": "def speed_up\n speed_up_by (10)\n end",
"title": ""
},
{
"docid": "5bfc645a052... |
06b9654cde4ca1fa5a394c4418b521c0 | You have 2 options here 1 pass the user 2 pass the email and the name I'll show you both | [
{
"docid": "66097832dafaa4e7e1bf5265ce14ca2b",
"score": "0.0",
"text": "def welcome(email)\n @url = new_user_session_url\n mail(from: 'bohemiancodes@gmail.com',\n to: email,\n subject: \"Welcome to Colors of Chiapas!\")\n end",
"title": ""
}
] | [
{
"docid": "011295f5eee5f10eda232c50feb24179",
"score": "0.72643155",
"text": "def set_name_and_email\n if self.user\n self.name = self.user.public_name\n self.email = self.user.email\n self.url = self.user.url\n end\n end",
"title": ""
},
{
"docid": "0bad9ba632cd3ecf1d... |
82fefdb8fc123039181e99d8bd4fe378 | Displays a message in the title bar of the terminal. | [
{
"docid": "6ddcdcdde90050cd299a57a0f4d43ef7",
"score": "0.0",
"text": "def _display_title(type, title, message, options = {})\n format = \"#{type}_title_format\".to_sym\n default_title_format = options[:default_title_format]\n title_format = options.fetch(format, default_title_fo... | [
{
"docid": "fb842df4dfe462e65847446e00cf66d9",
"score": "0.7161721",
"text": "def say(msg, title = nil)\n unless title == nil\n puts title.center(62, '~')\n end\n puts \"=> #{msg}\".ljust(62)\nend",
"title": ""
},
{
"docid": "e289ad00317c1ce51cbb58a1c6e90f71",
"score": "0.707394",... |
a9571fd7fcb71565dc123822c9256b8c | Este metodo asigna una api_key a el grupo | [
{
"docid": "6367597af5b4c37dde2cc1bccdd6d455",
"score": "0.6115718",
"text": "def set_api_key\n\t\tself.api_key = ApiKey.create()\n\tend",
"title": ""
}
] | [
{
"docid": "f433eb31536b958e2dbf75401a73e3db",
"score": "0.621966",
"text": "def api_key=(_arg0); end",
"title": ""
},
{
"docid": "f433eb31536b958e2dbf75401a73e3db",
"score": "0.621966",
"text": "def api_key=(_arg0); end",
"title": ""
},
{
"docid": "f433eb31536b958e2dbf75... |
256d3883426267e6fc3ca3c2465afa75 | POST /student_blogs POST /student_blogs.json | [
{
"docid": "bc12987fc02f948ca93743dd25be54c1",
"score": "0.7200995",
"text": "def create\n @student_blog = StudentBlog.new(student_blog_params)\n @student_blog.user = current_user\n @student_blog.slug = SecureRandom.uuid\n\n respond_to do |format|\n if @student_blog.save\n format... | [
{
"docid": "4f146524e4119c93f841fdd0df6c95c8",
"score": "0.6965668",
"text": "def create\n \t# binding.pry\n @blog = Blog.new(blog_params)\n @blog.student_id = current_user.student.id\n respond_to do |format|\n if @blog.save\n format.html { redirect_to @blog, notice: 'blog category... |
96022e692d7ffe45070dea2ff183a116 | Update global switch IPFIX export configuration Deprecated Please use /ipfixprofiles/ for switch IPFIX profile and /ipfixcollectorprofiles/ for IPFIX collector profile. | [
{
"docid": "588d5fb0ffe69453e1e91e0cd395e25c",
"score": "0.5834239",
"text": "def update_switch_ipfix_config(ipfix_obs_point_config, opts = {})\n data, _status_code, _headers = update_switch_ipfix_config_with_http_info(ipfix_obs_point_config, opts)\n return data\n end",
"title": ""
}
... | [
{
"docid": "f11c1dd62c867a7fc18f57222d081a01",
"score": "0.5830371",
"text": "def update_switch_ipfix_config(ipfix_obs_point_config, opts = {})\n data, _status_code, _headers = update_switch_ipfix_config_with_http_info(ipfix_obs_point_config, opts)\n data\n end",
"title": ""
},
{
... |