repo
stringclasses
235 values
path
stringlengths
11
168
func_name
stringlengths
12
143
original_string
stringlengths
83
6.91k
language
stringclasses
1 value
code
stringlengths
83
6.91k
code_tokens
listlengths
15
1.01k
docstring
stringlengths
5
25.7k
docstring_tokens
listlengths
1
427
sha
stringclasses
235 values
url
stringlengths
99
268
partition
stringclasses
1 value
summary
stringlengths
7
202
input_ids
listlengths
502
502
token_type_ids
listlengths
502
502
attention_mask
listlengths
502
502
labels
listlengths
502
502
jbox-web/ajax-datatables-rails
lib/ajax-datatables-rails/base.rb
AjaxDatatablesRails.Base.connected_columns
def connected_columns @connected_columns ||= begin view_columns.keys.map do |field_name| datatable.column_by(:data, field_name.to_s) end.compact end end
ruby
def connected_columns @connected_columns ||= begin view_columns.keys.map do |field_name| datatable.column_by(:data, field_name.to_s) end.compact end end
[ "def", "connected_columns", "@connected_columns", "||=", "begin", "view_columns", ".", "keys", ".", "map", "do", "|", "field_name", "|", "datatable", ".", "column_by", "(", ":data", ",", "field_name", ".", "to_s", ")", "end", ".", "compact", "end", "end" ]
helper methods
[ "helper", "methods" ]
2a0877f965c064716374fd4927ef1e0c53d383eb
https://github.com/jbox-web/ajax-datatables-rails/blob/2a0877f965c064716374fd4927ef1e0c53d383eb/lib/ajax-datatables-rails/base.rb#L45-L51
train
Returns the connected columns
[ 30522, 13366, 4198, 1035, 7753, 1030, 4198, 1035, 7753, 1064, 1064, 1027, 4088, 3193, 1035, 7753, 1012, 6309, 1012, 4949, 2079, 1064, 2492, 1035, 2171, 1064, 2951, 10880, 1012, 5930, 1035, 2011, 1006, 1024, 2951, 1010, 2492, 1035, 2171, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_kusto/lib/2017-09-07-privatepreview/generated/azure_mgmt_kusto/databases.rb
Azure::Kusto::Mgmt::V2018_09_07_privatepreview.Databases.check_name_availability
def check_name_availability(resource_group_name, cluster_name, database_name, custom_headers:nil) response = check_name_availability_async(resource_group_name, cluster_name, database_name, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def check_name_availability(resource_group_name, cluster_name, database_name, custom_headers:nil) response = check_name_availability_async(resource_group_name, cluster_name, database_name, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "check_name_availability", "(", "resource_group_name", ",", "cluster_name", ",", "database_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "check_name_availability_async", "(", "resource_group_name", ",", "cluster_name", ",", "database_name", ",", ...
Checks that the database name is valid and is not already in use. @param resource_group_name [String] The name of the resource group containing the Kusto cluster. @param cluster_name [String] The name of the Kusto cluster. @param database_name [DatabaseCheckNameRequest] The name of the database. @param custom_hea...
[ "Checks", "that", "the", "database", "name", "is", "valid", "and", "is", "not", "already", "in", "use", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_kusto/lib/2017-09-07-privatepreview/generated/azure_mgmt_kusto/databases.rb#L38-L41
train
Checks whether the database name is available for use.
[ 30522, 13366, 4638, 1035, 2171, 1035, 11343, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 9324, 1035, 2171, 1010, 7809, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 4638, 1035, 2171, 1035, 11343, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Model.get_hierarchical_entity_with_http_info
def get_hierarchical_entity_with_http_info(app_id, version_id, h_entity_id, custom_headers:nil) get_hierarchical_entity_async(app_id, version_id, h_entity_id, custom_headers:custom_headers).value! end
ruby
def get_hierarchical_entity_with_http_info(app_id, version_id, h_entity_id, custom_headers:nil) get_hierarchical_entity_async(app_id, version_id, h_entity_id, custom_headers:custom_headers).value! end
[ "def", "get_hierarchical_entity_with_http_info", "(", "app_id", ",", "version_id", ",", "h_entity_id", ",", "custom_headers", ":", "nil", ")", "get_hierarchical_entity_async", "(", "app_id", ",", "version_id", ",", "h_entity_id", ",", "custom_headers", ":custom_headers", ...
Gets information about a hierarchical entity in a version of the application. @param app_id The application ID. @param version_id [String] The version ID. @param h_entity_id The hierarchical entity extractor ID. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP...
[ "Gets", "information", "about", "a", "hierarchical", "entity", "in", "a", "version", "of", "the", "application", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb#L2447-L2449
train
Gets the details of a hierarchical entity.
[ 30522, 13366, 2131, 1035, 25835, 1035, 9178, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 1044, 1035, 9178, 1035, 8909, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2131, 1035, 25835,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
hashicorp/vault-ruby
lib/vault/api/auth.rb
Vault.Authenticate.approle
def approle(role_id, secret_id=nil) payload = { role_id: role_id } payload[:secret_id] = secret_id if secret_id json = client.post("/v1/auth/approle/login", JSON.fast_generate(payload)) secret = Secret.decode(json) client.token = secret.auth.client_token return secret end
ruby
def approle(role_id, secret_id=nil) payload = { role_id: role_id } payload[:secret_id] = secret_id if secret_id json = client.post("/v1/auth/approle/login", JSON.fast_generate(payload)) secret = Secret.decode(json) client.token = secret.auth.client_token return secret end
[ "def", "approle", "(", "role_id", ",", "secret_id", "=", "nil", ")", "payload", "=", "{", "role_id", ":", "role_id", "}", "payload", "[", ":secret_id", "]", "=", "secret_id", "if", "secret_id", "json", "=", "client", ".", "post", "(", "\"/v1/auth/approle/l...
Authenticate via the "approle" authentication method. If authentication is successful, the resulting token will be stored on the client and used for future requests. @example Vault.auth.approle( "db02de05-fa39-4855-059b-67221c5c2f63", "6a174c20-f6de-a53c-74d2-6018fcceff64", ) #=> #<Vault::Secret lea...
[ "Authenticate", "via", "the", "approle", "authentication", "method", ".", "If", "authentication", "is", "successful", "the", "resulting", "token", "will", "be", "stored", "on", "the", "client", "and", "used", "for", "future", "requests", "." ]
02f0532a802ba1a2a0d8703a4585dab76eb9d864
https://github.com/hashicorp/vault-ruby/blob/02f0532a802ba1a2a0d8703a4585dab76eb9d864/lib/vault/api/auth.rb#L92-L99
train
login to the approle
[ 30522, 13366, 10439, 30524, 18093, 1031, 1024, 3595, 1035, 8909, 1033, 1027, 3595, 1035, 8909, 2065, 3595, 1035, 8909, 1046, 3385, 1027, 7396, 1012, 2695, 1006, 1000, 1013, 1058, 2487, 1013, 8740, 2705, 1013, 10439, 13153, 2063, 1013, 8833,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_event_grid/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/topics.rb
Azure::EventGrid::Mgmt::V2019_02_01_preview.Topics.create_or_update_async
def create_or_update_async(resource_group_name, topic_name, topic_info, custom_headers:nil) # Send request promise = begin_create_or_update_async(resource_group_name, topic_name, topic_info, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method....
ruby
def create_or_update_async(resource_group_name, topic_name, topic_info, custom_headers:nil) # Send request promise = begin_create_or_update_async(resource_group_name, topic_name, topic_info, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method....
[ "def", "create_or_update_async", "(", "resource_group_name", ",", "topic_name", ",", "topic_info", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_create_or_update_async", "(", "resource_group_name", ",", "topic_name", ",", "topic_info", ...
@param resource_group_name [String] The name of the resource group within the user's subscription. @param topic_name [String] Name of the topic @param topic_info [Topic] Topic information @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [Conc...
[ "@param", "resource_group_name", "[", "String", "]", "The", "name", "of", "the", "resource", "group", "within", "the", "user", "s", "subscription", ".", "@param", "topic_name", "[", "String", "]", "Name", "of", "the", "topic", "@param", "topic_info", "[", "T...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_event_grid/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/topics.rb#L155-L171
train
Creates or updates a topic.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8476, 1035, 2171, 1010, 8476, 1035, 18558, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 1001, 4604, 5227, 4872, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
square/connect-ruby-sdk
lib/square_connect/api/customers_api.rb
SquareConnect.CustomersApi.delete_customer
def delete_customer(customer_id, opts = {}) data, _status_code, _headers = delete_customer_with_http_info(customer_id, opts) return data end
ruby
def delete_customer(customer_id, opts = {}) data, _status_code, _headers = delete_customer_with_http_info(customer_id, opts) return data end
[ "def", "delete_customer", "(", "customer_id", ",", "opts", "=", "{", "}", ")", "data", ",", "_status_code", ",", "_headers", "=", "delete_customer_with_http_info", "(", "customer_id", ",", "opts", ")", "return", "data", "end" ]
DeleteCustomer Deletes a customer from a business, along with any linked cards on file. When two profiles are merged into a single profile, that profile is assigned a new `customer_id`. You must use the new `customer_id` to delete merged profiles. @param customer_id The ID of the customer to delete. @param [Hash] op...
[ "DeleteCustomer", "Deletes", "a", "customer", "from", "a", "business", "along", "with", "any", "linked", "cards", "on", "file", ".", "When", "two", "profiles", "are", "merged", "into", "a", "single", "profile", "that", "profile", "is", "assigned", "a", "new"...
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/api/customers_api.rb#L139-L142
train
DeleteCustomer Returns a list of all the customer s data.
[ 30522, 13366, 3972, 12870, 1035, 8013, 1006, 8013, 1035, 8909, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 2951, 1010, 1035, 3570, 1035, 3642, 1010, 1035, 20346, 2015, 1027, 3972, 12870, 1035, 8013, 1035, 2007, 1035, 8299, 1035, 18558, 1006,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
mongodb/mongoid
lib/mongoid/config.rb
Mongoid.Config.connect_to
def connect_to(name, options = { read: { mode: :primary }}) self.clients = { default: { database: name, hosts: [ "localhost:27017" ], options: options } } end
ruby
def connect_to(name, options = { read: { mode: :primary }}) self.clients = { default: { database: name, hosts: [ "localhost:27017" ], options: options } } end
[ "def", "connect_to", "(", "name", ",", "options", "=", "{", "read", ":", "{", "mode", ":", ":primary", "}", "}", ")", "self", ".", "clients", "=", "{", "default", ":", "{", "database", ":", "name", ",", "hosts", ":", "[", "\"localhost:27017\"", "]", ...
Connect to the provided database name on the default client. @note Use only in development or test environments for convenience. @example Set the database to connect to. config.connect_to("mongoid_test") @param [ String ] name The database name. @since 3.0.0
[ "Connect", "to", "the", "provided", "database", "name", "on", "the", "default", "client", "." ]
56976e32610f4c2450882b0bfe14da099f0703f4
https://github.com/mongodb/mongoid/blob/56976e32610f4c2450882b0bfe14da099f0703f4/lib/mongoid/config.rb#L67-L75
train
Connect to a database
[ 30522, 13366, 7532, 1035, 2000, 1006, 2171, 1010, 7047, 1027, 1063, 3191, 1024, 1063, 5549, 1024, 1024, 3078, 1065, 1065, 1007, 2969, 1012, 7846, 1027, 1063, 12398, 1024, 1063, 7809, 1024, 2171, 1010, 6184, 1024, 1031, 1000, 2334, 15006, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_cdn/lib/2016-10-02/generated/azure_mgmt_cdn/profiles.rb
Azure::CDN::Mgmt::V2016_10_02.Profiles.generate_sso_uri
def generate_sso_uri(resource_group_name, profile_name, custom_headers:nil) response = generate_sso_uri_async(resource_group_name, profile_name, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def generate_sso_uri(resource_group_name, profile_name, custom_headers:nil) response = generate_sso_uri_async(resource_group_name, profile_name, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "generate_sso_uri", "(", "resource_group_name", ",", "profile_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "generate_sso_uri_async", "(", "resource_group_name", ",", "profile_name", ",", "custom_headers", ":custom_headers", ")", ".", "value!", ...
Generates a dynamic SSO URI used to sign in to the CDN supplemental portal. Supplemental portal is used to configure advanced feature capabilities that are not yet available in the Azure portal, such as core reports in a standard profile; rules engine, advanced HTTP reports, and real-time stats and alerts in a prem...
[ "Generates", "a", "dynamic", "SSO", "URI", "used", "to", "sign", "in", "to", "the", "CDN", "supplemental", "portal", ".", "Supplemental", "portal", "is", "used", "to", "configure", "advanced", "feature", "capabilities", "that", "are", "not", "yet", "available"...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_cdn/lib/2016-10-02/generated/azure_mgmt_cdn/profiles.rb#L468-L471
train
Generate SSO URI for the specified CDN profile.
[ 30522, 13366, 9699, 1035, 7020, 2080, 1035, 24471, 2072, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 6337, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 9699, 1035, 7020, 2080, 1035, 24471, 2072, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
square/connect-ruby-sdk
lib/square_connect/api/v1_employees_api.rb
SquareConnect.V1EmployeesApi.list_cash_drawer_shifts
def list_cash_drawer_shifts(location_id, opts = {}) data, _status_code, _headers = list_cash_drawer_shifts_with_http_info(location_id, opts) return data end
ruby
def list_cash_drawer_shifts(location_id, opts = {}) data, _status_code, _headers = list_cash_drawer_shifts_with_http_info(location_id, opts) return data end
[ "def", "list_cash_drawer_shifts", "(", "location_id", ",", "opts", "=", "{", "}", ")", "data", ",", "_status_code", ",", "_headers", "=", "list_cash_drawer_shifts_with_http_info", "(", "location_id", ",", "opts", ")", "return", "data", "end" ]
ListCashDrawerShifts Provides the details for all of a location's cash drawer shifts during a date range. The date range you specify cannot exceed 90 days. @param location_id The ID of the location to list cash drawer shifts for. @param [Hash] opts the optional parameters @option opts [String] :order The order in w...
[ "ListCashDrawerShifts", "Provides", "the", "details", "for", "all", "of", "a", "location", "s", "cash", "drawer", "shifts", "during", "a", "date", "range", ".", "The", "date", "range", "you", "specify", "cannot", "exceed", "90", "days", "." ]
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/api/v1_employees_api.rb#L248-L251
train
List all cash drawer shifts
[ 30522, 13366, 2862, 1035, 5356, 1035, 13065, 1035, 12363, 1006, 3295, 1035, 8909, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 2951, 1010, 1035, 3570, 1035, 3642, 1010, 1035, 20346, 2015, 1027, 2862, 1035, 5356, 1035, 13065, 1035, 12363, 1035...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_machine_learning/lib/2017-01-01/generated/azure_mgmt_machine_learning/web_services.rb
Azure::MachineLearning::Mgmt::V2017_01_01.WebServices.create_or_update_async
def create_or_update_async(resource_group_name, web_service_name, create_or_update_payload, custom_headers:nil) # Send request promise = begin_create_or_update_async(resource_group_name, web_service_name, create_or_update_payload, custom_headers:custom_headers) promise = promise.then do |response| ...
ruby
def create_or_update_async(resource_group_name, web_service_name, create_or_update_payload, custom_headers:nil) # Send request promise = begin_create_or_update_async(resource_group_name, web_service_name, create_or_update_payload, custom_headers:custom_headers) promise = promise.then do |response| ...
[ "def", "create_or_update_async", "(", "resource_group_name", ",", "web_service_name", ",", "create_or_update_payload", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_create_or_update_async", "(", "resource_group_name", ",", "web_service_name"...
@param resource_group_name [String] Name of the resource group in which the web service is located. @param web_service_name [String] The name of the web service. @param create_or_update_payload [WebService] The payload that is used to create or update the web service. @param custom_headers [Hash{String => String}]...
[ "@param", "resource_group_name", "[", "String", "]", "Name", "of", "the", "resource", "group", "in", "which", "the", "web", "service", "is", "located", ".", "@param", "web_service_name", "[", "String", "]", "The", "name", "of", "the", "web", "service", ".", ...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_machine_learning/lib/2017-01-01/generated/azure_mgmt_machine_learning/web_services.rb#L62-L78
train
Creates or updates a web service.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 4773, 1035, 2326, 1035, 2171, 1010, 3443, 30524, 1035, 2030, 1035, 10651, 1035, 18093, 1010, 7661, 1035, 20346, 2015, 1024, 7661,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
haml/haml
lib/haml/helpers.rb
Haml.Helpers.haml_tag
def haml_tag(name, *rest, &block) ret = ErrorReturn.new("haml_tag") text = rest.shift.to_s unless [Symbol, Hash, NilClass].any? {|t| rest.first.is_a? t} flags = [] flags << rest.shift while rest.first.is_a? Symbol attrs = (rest.shift || {}) attrs.keys.each {|key| attrs[key.to_s] = a...
ruby
def haml_tag(name, *rest, &block) ret = ErrorReturn.new("haml_tag") text = rest.shift.to_s unless [Symbol, Hash, NilClass].any? {|t| rest.first.is_a? t} flags = [] flags << rest.shift while rest.first.is_a? Symbol attrs = (rest.shift || {}) attrs.keys.each {|key| attrs[key.to_s] = a...
[ "def", "haml_tag", "(", "name", ",", "*", "rest", ",", "&", "block", ")", "ret", "=", "ErrorReturn", ".", "new", "(", "\"haml_tag\"", ")", "text", "=", "rest", ".", "shift", ".", "to_s", "unless", "[", "Symbol", ",", "Hash", ",", "NilClass", "]", "...
Creates an HTML tag with the given name and optionally text and attributes. Can take a block that will run between the opening and closing tags. If the block is a Haml block or outputs text using \{#haml\_concat}, the text will be properly indented. `name` can be a string using the standard Haml class/id shorthand...
[ "Creates", "an", "HTML", "tag", "with", "the", "given", "name", "and", "optionally", "text", "and", "attributes", ".", "Can", "take", "a", "block", "that", "will", "run", "between", "the", "opening", "and", "closing", "tags", ".", "If", "the", "block", "...
9aa0fbe4a91b999978927be569d2ad0cd39076f1
https://github.com/haml/haml/blob/9aa0fbe4a91b999978927be569d2ad0cd39076f1/lib/haml/helpers.rb#L487-L549
train
Creates a new instance of the HamlTag class.
[ 30522, 13366, 10654, 2140, 1035, 6415, 1006, 2171, 1010, 1008, 2717, 1010, 1004, 3796, 1007, 2128, 2102, 1027, 7561, 13465, 14287, 1012, 2047, 1006, 1000, 10654, 2140, 1035, 6415, 1000, 1007, 3793, 1027, 2717, 1012, 5670, 1012, 2000, 1035, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
rails/sprockets
lib/sprockets/context.rb
Sprockets.Context.load
def load(uri) asset = environment.load(uri) @dependencies.merge(asset.metadata[:dependencies]) asset end
ruby
def load(uri) asset = environment.load(uri) @dependencies.merge(asset.metadata[:dependencies]) asset end
[ "def", "load", "(", "uri", ")", "asset", "=", "environment", ".", "load", "(", "uri", ")", "@dependencies", ".", "merge", "(", "asset", ".", "metadata", "[", ":dependencies", "]", ")", "asset", "end" ]
Public: Load Asset by AssetURI and track it as a dependency. uri - AssetURI Returns Asset.
[ "Public", ":", "Load", "Asset", "by", "AssetURI", "and", "track", "it", "as", "a", "dependency", "." ]
9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd
https://github.com/rails/sprockets/blob/9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd/lib/sprockets/context.rb#L115-L119
train
Load an asset from the given URI
[ 30522, 13366, 7170, 1006, 24471, 2072, 1007, 11412, 1027, 4044, 1012, 7170, 1006, 24471, 2072, 1007, 1030, 12530, 15266, 1012, 13590, 1006, 11412, 1012, 27425, 1031, 1024, 12530, 15266, 1033, 1007, 11412, 2203, 102, 0, 0, 0, 0, 0, 0, 0,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_sql/lib/2014-04-01/generated/azure_mgmt_sql/databases.rb
Azure::SQL::Mgmt::V2014_04_01.Databases.export_async
def export_async(resource_group_name, server_name, database_name, parameters, custom_headers:nil) # Send request promise = begin_export_async(resource_group_name, server_name, database_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserializa...
ruby
def export_async(resource_group_name, server_name, database_name, parameters, custom_headers:nil) # Send request promise = begin_export_async(resource_group_name, server_name, database_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserializa...
[ "def", "export_async", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_export_async", "(", "resource_group_name", ",", "server_name", ",", "databa...
@param resource_group_name [String] The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. @param server_name [String] The name of the server. @param database_name [String] The name of the database to be exported. @param parameters [E...
[ "@param", "resource_group_name", "[", "String", "]", "The", "name", "of", "the", "resource", "group", "that", "contains", "the", "resource", ".", "You", "can", "obtain", "this", "value", "from", "the", "Azure", "Resource", "Manager", "API", "or", "the", "por...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_sql/lib/2014-04-01/generated/azure_mgmt_sql/databases.rb#L1101-L1117
train
Export a database to a SQL server.
[ 30522, 13366, 9167, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8241, 1035, 2171, 1010, 7809, 1035, 2171, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 1001, 4604, 5227, 4872, 1027, 4088, 1035, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
magnusvk/counter_culture
lib/counter_culture/counter.rb
CounterCulture.Counter.relation_primary_key
def relation_primary_key(relation, source: nil, was: false) reflect = relation_reflect(relation) klass = nil if reflect.options.key?(:polymorphic) raise "can't handle multiple keys with polymorphic associations" unless (relation.is_a?(Symbol) || relation.length == 1) raise "must specif...
ruby
def relation_primary_key(relation, source: nil, was: false) reflect = relation_reflect(relation) klass = nil if reflect.options.key?(:polymorphic) raise "can't handle multiple keys with polymorphic associations" unless (relation.is_a?(Symbol) || relation.length == 1) raise "must specif...
[ "def", "relation_primary_key", "(", "relation", ",", "source", ":", "nil", ",", "was", ":", "false", ")", "reflect", "=", "relation_reflect", "(", "relation", ")", "klass", "=", "nil", "if", "reflect", ".", "options", ".", "key?", "(", ":polymorphic", ")",...
gets the primary key name of the given relation relation: a symbol or array of symbols; specifies the relation that has the counter cache column source[optional]: the model instance that the relationship is linked from, only needed for polymorphic associations, probably only works with a single relation (sy...
[ "gets", "the", "primary", "key", "name", "of", "the", "given", "relation" ]
6b5bd4d6e1ee4f10f262ace7cfed5776af9520ba
https://github.com/magnusvk/counter_culture/blob/6b5bd4d6e1ee4f10f262ace7cfed5776af9520ba/lib/counter_culture/counter.rb#L247-L256
train
Returns the primary key for the given relation
[ 30522, 13366, 30524, 3145, 1006, 7189, 1010, 3120, 1024, 9152, 2140, 1010, 2001, 1024, 6270, 1007, 8339, 1027, 7189, 1035, 8339, 1006, 7189, 1007, 1047, 27102, 1027, 9152, 2140, 2065, 8339, 1012, 7047, 1012, 3145, 1029, 1006, 1024, 26572, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
jekyll/jekyll
lib/jekyll/document.rb
Jekyll.Document.merge_data!
def merge_data!(other, source: "YAML front matter") merge_categories!(other) Utils.deep_merge_hashes!(data, other) merge_date!(source) data end
ruby
def merge_data!(other, source: "YAML front matter") merge_categories!(other) Utils.deep_merge_hashes!(data, other) merge_date!(source) data end
[ "def", "merge_data!", "(", "other", ",", "source", ":", "\"YAML front matter\"", ")", "merge_categories!", "(", "other", ")", "Utils", ".", "deep_merge_hashes!", "(", "data", ",", "other", ")", "merge_date!", "(", "source", ")", "data", "end" ]
Merge some data in with this document's data. Returns the merged data.
[ "Merge", "some", "data", "in", "with", "this", "document", "s", "data", "." ]
fd74fe3e93a1fb506fa6621a2e271d7b9c5c3e3b
https://github.com/jekyll/jekyll/blob/fd74fe3e93a1fb506fa6621a2e271d7b9c5c3e3b/lib/jekyll/document.rb#L59-L64
train
Merge two data structures into one.
[ 30522, 13366, 13590, 1035, 2951, 999, 1006, 2060, 1010, 3120, 1024, 1000, 8038, 19968, 2392, 3043, 1000, 1007, 13590, 1035, 7236, 999, 1006, 2060, 1007, 21183, 12146, 1012, 2784, 1035, 13590, 1035, 23325, 2229, 999, 1006, 2951, 1010, 2060, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
googleapis/google-cloud-ruby
google-cloud-logging/lib/google-cloud-logging.rb
Google.Cloud.logging
def logging scope: nil, timeout: nil, client_config: nil timeout ||= @timeout Google::Cloud.logging @project, @keyfile, scope: scope, timeout: timeout, client_config: client_config end
ruby
def logging scope: nil, timeout: nil, client_config: nil timeout ||= @timeout Google::Cloud.logging @project, @keyfile, scope: scope, timeout: timeout, client_config: client_config end
[ "def", "logging", "scope", ":", "nil", ",", "timeout", ":", "nil", ",", "client_config", ":", "nil", "timeout", "||=", "@timeout", "Google", "::", "Cloud", ".", "logging", "@project", ",", "@keyfile", ",", "scope", ":", "scope", ",", "timeout", ":", "tim...
Creates a new object for connecting to the Stackdriver Logging service. Each call creates a new connection. For more information on connecting to Google Cloud see the {file:AUTHENTICATION.md Authentication Guide}. @param [String, Array<String>] scope The OAuth 2.0 scopes controlling the set of resources and op...
[ "Creates", "a", "new", "object", "for", "connecting", "to", "the", "Stackdriver", "Logging", "service", ".", "Each", "call", "creates", "a", "new", "connection", "." ]
846c1a57250ac860ef4de1b54853a480ab2ff702
https://github.com/googleapis/google-cloud-ruby/blob/846c1a57250ac860ef4de1b54853a480ab2ff702/google-cloud-logging/lib/google-cloud-logging.rb#L69-L74
train
Creates a logging client.
[ 30522, 13366, 15899, 9531, 1024, 9152, 2140, 1010, 2051, 5833, 1024, 9152, 2140, 1010, 7396, 1035, 9530, 8873, 2290, 1024, 9152, 2140, 2051, 5833, 1064, 1064, 1027, 1030, 2051, 5833, 8224, 1024, 1024, 6112, 1012, 15899, 1030, 2622, 1010, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_sql/lib/2014-04-01/generated/azure_mgmt_sql/firewall_rules.rb
Azure::SQL::Mgmt::V2014_04_01.FirewallRules.get_with_http_info
def get_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers:nil) get_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value! end
ruby
def get_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers:nil) get_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value! end
[ "def", "get_with_http_info", "(", "resource_group_name", ",", "server_name", ",", "firewall_rule_name", ",", "custom_headers", ":", "nil", ")", "get_async", "(", "resource_group_name", ",", "server_name", ",", "firewall_rule_name", ",", "custom_headers", ":custom_headers"...
Gets a firewall rule. @param resource_group_name [String] The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. @param server_name [String] The name of the server. @param firewall_rule_name [String] The name of the firewall rule. @...
[ "Gets", "a", "firewall", "rule", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_sql/lib/2014-04-01/generated/azure_mgmt_sql/firewall_rules.rb#L275-L277
train
Gets the specified firewall rule.
[ 30522, 13366, 2131, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8241, 1035, 2171, 1010, 2543, 9628, 1035, 3627, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2131, 1035, 2004, 6038, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
troessner/reek
samples/smelly_source/inline.rb
Inline.C.add_type_converter
def add_type_converter(type, r2c, c2r) warn "WAR\NING: overridding #{type} on #{caller[0]}" if @@type_map.has_key? type @@type_map[type] = [r2c, c2r] end
ruby
def add_type_converter(type, r2c, c2r) warn "WAR\NING: overridding #{type} on #{caller[0]}" if @@type_map.has_key? type @@type_map[type] = [r2c, c2r] end
[ "def", "add_type_converter", "(", "type", ",", "r2c", ",", "c2r", ")", "warn", "\"WAR\\NING: overridding #{type} on #{caller[0]}\"", "if", "@@type_map", ".", "has_key?", "type", "@@type_map", "[", "type", "]", "=", "[", "r2c", ",", "c2r", "]", "end" ]
Registers C type-casts +r2c+ and +c2r+ for +type+.
[ "Registers", "C", "type", "-", "casts", "+", "r2c", "+", "and", "+", "c2r", "+", "for", "+", "type", "+", "." ]
8c6b5c0c6228a6981ab48543457889f9ea984054
https://github.com/troessner/reek/blob/8c6b5c0c6228a6981ab48543457889f9ea984054/samples/smelly_source/inline.rb#L520-L523
train
Add a type converter to the current object.
[ 30522, 13366, 5587, 1035, 2828, 1035, 10463, 2121, 1006, 2828, 1010, 1054, 2475, 2278, 1010, 29248, 2099, 1007, 11582, 1000, 2162, 30524, 2006, 1001, 1063, 20587, 1031, 1014, 1033, 1065, 1000, 2065, 1030, 1030, 2828, 1035, 4949, 1012, 2038,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
square/connect-ruby-sdk
lib/square_connect/models/shift_workday.rb
SquareConnect.ShiftWorkday.match_shifts_by=
def match_shifts_by=(match_shifts_by) validator = EnumAttributeValidator.new('String', ["START_AT", "END_AT", "INTERSECTION"]) unless validator.valid?(match_shifts_by) fail ArgumentError, "invalid value for 'match_shifts_by', must be one of #{validator.allowable_values}." end @match_shif...
ruby
def match_shifts_by=(match_shifts_by) validator = EnumAttributeValidator.new('String', ["START_AT", "END_AT", "INTERSECTION"]) unless validator.valid?(match_shifts_by) fail ArgumentError, "invalid value for 'match_shifts_by', must be one of #{validator.allowable_values}." end @match_shif...
[ "def", "match_shifts_by", "=", "(", "match_shifts_by", ")", "validator", "=", "EnumAttributeValidator", ".", "new", "(", "'String'", ",", "[", "\"START_AT\"", ",", "\"END_AT\"", ",", "\"INTERSECTION\"", "]", ")", "unless", "validator", ".", "valid?", "(", "match...
Custom attribute writer method checking allowed values (enum). @param [Object] match_shifts_by Object to be assigned
[ "Custom", "attribute", "writer", "method", "checking", "allowed", "values", "(", "enum", ")", "." ]
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/models/shift_workday.rb#L103-L109
train
Sets the match_shifts_by attribute for this selector.
[ 30522, 13366, 2674, 1035, 12363, 1035, 2011, 1027, 1006, 2674, 1035, 12363, 1035, 2011, 1007, 9398, 8844, 1027, 4372, 12248, 4779, 3089, 8569, 2618, 10175, 8524, 4263, 1012, 2047, 1006, 1005, 5164, 1005, 1010, 1031, 1000, 2707, 1035, 2012, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
grodowski/undercover
lib/undercover.rb
Undercover.Report.build_warnings
def build_warnings flagged_results = Set.new changeset.each_changed_line do |filepath, line_no| dist_from_line_no = lambda do |res| return BigDecimal::INFINITY if line_no < res.first_line res_lines = res.first_line..res.last_line return BigDecimal::INFINITY unless res...
ruby
def build_warnings flagged_results = Set.new changeset.each_changed_line do |filepath, line_no| dist_from_line_no = lambda do |res| return BigDecimal::INFINITY if line_no < res.first_line res_lines = res.first_line..res.last_line return BigDecimal::INFINITY unless res...
[ "def", "build_warnings", "flagged_results", "=", "Set", ".", "new", "changeset", ".", "each_changed_line", "do", "|", "filepath", ",", "line_no", "|", "dist_from_line_no", "=", "lambda", "do", "|", "res", "|", "return", "BigDecimal", "::", "INFINITY", "if", "l...
TODO: this is experimental and might be incorrect! rubocop:disable Metrics/MethodLength, Metrics/AbcSize
[ "TODO", ":", "this", "is", "experimental", "and", "might", "be", "incorrect!", "rubocop", ":", "disable", "Metrics", "/", "MethodLength", "Metrics", "/", "AbcSize" ]
8f9cb32094d1669d67ff957337f95243c4d15ff2
https://github.com/grodowski/undercover/blob/8f9cb32094d1669d67ff957337f95243c4d15ff2/lib/undercover.rb#L51-L72
train
Build warnings from the changeset
[ 30522, 13366, 3857, 1035, 16234, 5210, 5999, 1035, 3463, 1027, 2275, 1012, 2047, 3431, 3388, 1012, 2169, 1035, 2904, 1035, 2240, 2079, 1064, 5371, 15069, 1010, 2240, 1035, 2053, 1064, 4487, 3367, 1035, 2013, 1035, 2240, 1035, 2053, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
seejohnrun/ice_cube
lib/ice_cube/rules/weekly_rule.rb
IceCube.WeeklyRule.realign
def realign(step_time, start_time) time = TimeUtil::TimeWrapper.new(start_time) offset = wday_offset(step_time, start_time) time.add(:day, offset) super step_time, time.to_time end
ruby
def realign(step_time, start_time) time = TimeUtil::TimeWrapper.new(start_time) offset = wday_offset(step_time, start_time) time.add(:day, offset) super step_time, time.to_time end
[ "def", "realign", "(", "step_time", ",", "start_time", ")", "time", "=", "TimeUtil", "::", "TimeWrapper", ".", "new", "(", "start_time", ")", "offset", "=", "wday_offset", "(", "step_time", ",", "start_time", ")", "time", ".", "add", "(", ":day", ",", "o...
Move the effective start time to correct for when the schedule has validations earlier in the week than the selected start time, e.g. Schedule.new(wednesday).weekly(2).day(:monday) The effective start time gets realigned to the second next Monday, jumping over the gap week for the interval (2). Without realig...
[ "Move", "the", "effective", "start", "time", "to", "correct", "for", "when", "the", "schedule", "has", "validations", "earlier", "in", "the", "week", "than", "the", "selected", "start", "time", "e", ".", "g", "." ]
fb6c657bdc4f87dfda2bf83f15c5f487b78ccabd
https://github.com/seejohnrun/ice_cube/blob/fb6c657bdc4f87dfda2bf83f15c5f487b78ccabd/lib/ice_cube/rules/weekly_rule.rb#L36-L41
train
realigns the step_time to the start_time
[ 30522, 13366, 2613, 23773, 1006, 3357, 1035, 2051, 1010, 2707, 1035, 2051, 1007, 2051, 1027, 2051, 21823, 2140, 1024, 1024, 2051, 13088, 29098, 2121, 1012, 2047, 1006, 2707, 30524, 1012, 2000, 1035, 2051, 2203, 102, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
decidim/decidim
decidim-core/app/helpers/decidim/traceability_helper.rb
Decidim.TraceabilityHelper.render_resource_editor
def render_resource_editor(version) render partial: "decidim/shared/version_author", locals: { author: Decidim.traceability.version_editor(version) } end
ruby
def render_resource_editor(version) render partial: "decidim/shared/version_author", locals: { author: Decidim.traceability.version_editor(version) } end
[ "def", "render_resource_editor", "(", "version", ")", "render", "partial", ":", "\"decidim/shared/version_author\"", ",", "locals", ":", "{", "author", ":", "Decidim", ".", "traceability", ".", "version_editor", "(", "version", ")", "}", "end" ]
Renders the avatar and author name of the author of the given version. version - an object that responds to `whodunnit` and returns a String. Returns an HTML-safe String representing the HTML to render the author.
[ "Renders", "the", "avatar", "and", "author", "name", "of", "the", "author", "of", "the", "given", "version", "." ]
6e2b14e559a63088669904e3c5c49a5180700cf7
https://github.com/decidim/decidim/blob/6e2b14e559a63088669904e3c5c49a5180700cf7/decidim-core/app/helpers/decidim/traceability_helper.rb#L25-L30
train
Render the version author
[ 30522, 13366, 17552, 1035, 7692, 1035, 3559, 1006, 2544, 1007, 17552, 7704, 1024, 1000, 11703, 28173, 30524, 1063, 3166, 1024, 11703, 28173, 2213, 1012, 7637, 8010, 1012, 2544, 1035, 3559, 1006, 2544, 1007, 1065, 2203, 102, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
alexreisner/geocoder
lib/geocoder/lookups/latlon.rb
Geocoder::Lookup.Latlon.query_url_params
def query_url_params(query) if query.reverse_geocode? { :token => configuration.api_key, :lat => query.coordinates[0], :lon => query.coordinates[1] }.merge(super) else { :token => configuration.api_key, :address => query.sanitized_tex...
ruby
def query_url_params(query) if query.reverse_geocode? { :token => configuration.api_key, :lat => query.coordinates[0], :lon => query.coordinates[1] }.merge(super) else { :token => configuration.api_key, :address => query.sanitized_tex...
[ "def", "query_url_params", "(", "query", ")", "if", "query", ".", "reverse_geocode?", "{", ":token", "=>", "configuration", ".", "api_key", ",", ":lat", "=>", "query", ".", "coordinates", "[", "0", "]", ",", ":lon", "=>", "query", ".", "coordinates", "[", ...
---------------------------------------------------------------
[ "---------------------------------------------------------------" ]
e087dc2759264ee6f307b926bb2de4ec2406859e
https://github.com/alexreisner/geocoder/blob/e087dc2759264ee6f307b926bb2de4ec2406859e/lib/geocoder/lookups/latlon.rb#L43-L56
train
Returns the url params for the given query
[ 30522, 13366, 23032, 1035, 24471, 2140, 1035, 11498, 5244, 1006, 23032, 1007, 2065, 23032, 1012, 7901, 1035, 20248, 16044, 1029, 1063, 1024, 19204, 1027, 1028, 9563, 1012, 17928, 1035, 3145, 1010, 1024, 2474, 2102, 1027, 1028, 23032, 1012, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
meew0/discordrb
lib/discordrb/commands/command_bot.rb
Discordrb::Commands.CommandBot.arg_check
def arg_check(args, types = nil, server = nil) return args unless types args.each_with_index.map do |arg, i| next arg if types[i].nil? || types[i] == String if types[i] == Integer begin Integer(arg) rescue ArgumentError nil end ...
ruby
def arg_check(args, types = nil, server = nil) return args unless types args.each_with_index.map do |arg, i| next arg if types[i].nil? || types[i] == String if types[i] == Integer begin Integer(arg) rescue ArgumentError nil end ...
[ "def", "arg_check", "(", "args", ",", "types", "=", "nil", ",", "server", "=", "nil", ")", "return", "args", "unless", "types", "args", ".", "each_with_index", ".", "map", "do", "|", "arg", ",", "i", "|", "next", "arg", "if", "types", "[", "i", "]"...
Transforms an array of string arguments based on types array. For example, `['1', '10..14']` with types `[Integer, Range]` would turn into `[1, 10..14]`.
[ "Transforms", "an", "array", "of", "string", "arguments", "based", "on", "types", "array", ".", "For", "example", "[", "1", "10", "..", "14", "]", "with", "types", "[", "Integer", "Range", "]", "would", "turn", "into", "[", "1", "10", "..", "14", "]"...
764298a1ff0be69a1853b510d736f21c2b91a2fe
https://github.com/meew0/discordrb/blob/764298a1ff0be69a1853b510d736f21c2b91a2fe/lib/discordrb/commands/command_bot.rb#L244-L321
train
Check arguments for types
[ 30522, 13366, 12098, 2290, 1035, 4638, 1006, 12098, 5620, 1010, 4127, 1027, 9152, 2140, 1010, 8241, 1027, 9152, 2140, 1007, 2709, 12098, 5620, 4983, 4127, 12098, 5620, 1012, 2169, 1035, 2007, 1035, 5950, 1012, 4949, 2079, 1064, 12098, 2290,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
CocoaPods/Xcodeproj
lib/xcodeproj/scheme.rb
Xcodeproj.XCScheme.to_s
def to_s formatter = XMLFormatter.new(2) formatter.compact = false out = '' formatter.write(@doc, out) out.gsub!("<?xml version='1.0' encoding='UTF-8'?>", '<?xml version="1.0" encoding="UTF-8"?>') out << "\n" out end
ruby
def to_s formatter = XMLFormatter.new(2) formatter.compact = false out = '' formatter.write(@doc, out) out.gsub!("<?xml version='1.0' encoding='UTF-8'?>", '<?xml version="1.0" encoding="UTF-8"?>') out << "\n" out end
[ "def", "to_s", "formatter", "=", "XMLFormatter", ".", "new", "(", "2", ")", "formatter", ".", "compact", "=", "false", "out", "=", "''", "formatter", ".", "write", "(", "@doc", ",", "out", ")", "out", ".", "gsub!", "(", "\"<?xml version='1.0' encoding='UTF...
@!group Serialization ------------------------------------------------------------------------- Serializes the current state of the object to a String. @note The goal of the string representation is to match Xcode output as close as possible to aide comparison. @return [String] the XML string value of t...
[ "@!group", "Serialization", "-------------------------------------------------------------------------", "Serializes", "the", "current", "state", "of", "the", "object", "to", "a", "String", "." ]
3be1684437a6f8e69c7836ad4c85a2b78663272f
https://github.com/CocoaPods/Xcodeproj/blob/3be1684437a6f8e69c7836ad4c85a2b78663272f/lib/xcodeproj/scheme.rb#L283-L291
train
Convert the XML document to a string.
[ 30522, 13366, 2000, 1035, 1055, 4289, 3334, 1027, 20950, 14192, 20097, 1012, 2047, 1006, 1016, 1007, 4289, 3334, 1012, 9233, 1027, 6270, 2041, 1027, 1005, 1005, 4289, 3334, 1012, 4339, 1006, 1030, 9986, 1010, 2041, 1007, 2041, 1012, 28177, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
samvera/hyrax
app/models/concerns/hyrax/ability.rb
Hyrax.Ability.download_permissions
def download_permissions can :download, String do |id| test_download(id) end can :download, SolrDocument do |obj| cache.put(obj.id, obj) test_download(obj.id) end end
ruby
def download_permissions can :download, String do |id| test_download(id) end can :download, SolrDocument do |obj| cache.put(obj.id, obj) test_download(obj.id) end end
[ "def", "download_permissions", "can", ":download", ",", "String", "do", "|", "id", "|", "test_download", "(", "id", ")", "end", "can", ":download", ",", "SolrDocument", "do", "|", "obj", "|", "cache", ".", "put", "(", "obj", ".", "id", ",", "obj", ")",...
This overrides hydra-head, (and restores the method from blacklight-access-controls)
[ "This", "overrides", "hydra", "-", "head", "(", "and", "restores", "the", "method", "from", "blacklight", "-", "access", "-", "controls", ")" ]
e2b4f56e829a53b1f11296324736e9d5b8c9ee5f
https://github.com/samvera/hyrax/blob/e2b4f56e829a53b1f11296324736e9d5b8c9ee5f/app/models/concerns/hyrax/ability.rb#L82-L91
train
download permissions
[ 30522, 13366, 8816, 1035, 6656, 2015, 2064, 1024, 8816, 1010, 5164, 2079, 1064, 8909, 1064, 3231, 1035, 8816, 1006, 8909, 1007, 2203, 2064, 1024, 8816, 1010, 14017, 20683, 24894, 4765, 2079, 1064, 27885, 3501, 1064, 17053, 1012, 2404, 1006,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_machine_learning_services/lib/2018-03-01-preview/generated/azure_mgmt_machine_learning_services/machine_learning_compute.rb
Azure::MachineLearningServices::Mgmt::V2018_03_01_preview.MachineLearningCompute.list_by_workspace_with_http_info
def list_by_workspace_with_http_info(resource_group_name, workspace_name, skiptoken:nil, custom_headers:nil) list_by_workspace_async(resource_group_name, workspace_name, skiptoken:skiptoken, custom_headers:custom_headers).value! end
ruby
def list_by_workspace_with_http_info(resource_group_name, workspace_name, skiptoken:nil, custom_headers:nil) list_by_workspace_async(resource_group_name, workspace_name, skiptoken:skiptoken, custom_headers:custom_headers).value! end
[ "def", "list_by_workspace_with_http_info", "(", "resource_group_name", ",", "workspace_name", ",", "skiptoken", ":", "nil", ",", "custom_headers", ":", "nil", ")", "list_by_workspace_async", "(", "resource_group_name", ",", "workspace_name", ",", "skiptoken", ":", "skip...
Gets computes in specified workspace. @param resource_group_name [String] Name of the resource group in which workspace is located. @param workspace_name [String] Name of Azure Machine Learning workspace. @param skiptoken [String] Continuation token for pagination. @param custom_headers [Hash{String => String}] A...
[ "Gets", "computes", "in", "specified", "workspace", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_machine_learning_services/lib/2018-03-01-preview/generated/azure_mgmt_machine_learning_services/machine_learning_compute.rb#L54-L56
train
Gets the list of all the segmentation of the specified workspace.
[ 30522, 13366, 2862, 1035, 2011, 1035, 2573, 15327, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2573, 15327, 1035, 2171, 1010, 13558, 18715, 2368, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ruby/rake
lib/rake/task_manager.rb
Rake.TaskManager.tasks_in_scope
def tasks_in_scope(scope) prefix = scope.path tasks.select { |t| /^#{prefix}:/ =~ t.name } end
ruby
def tasks_in_scope(scope) prefix = scope.path tasks.select { |t| /^#{prefix}:/ =~ t.name } end
[ "def", "tasks_in_scope", "(", "scope", ")", "prefix", "=", "scope", ".", "path", "tasks", ".", "select", "{", "|", "t", "|", "/", "#{", "prefix", "}", "/", "=~", "t", ".", "name", "}", "end" ]
List of all the tasks defined in the given scope (and its sub-scopes).
[ "List", "of", "all", "the", "tasks", "defined", "in", "the", "given", "scope", "(", "and", "its", "sub", "-", "scopes", ")", "." ]
1c22b490ee6cb8bd614fa8d0d6145f671466206b
https://github.com/ruby/rake/blob/1c22b490ee6cb8bd614fa8d0d6145f671466206b/lib/rake/task_manager.rb#L167-L172
train
Returns the tasks in the given scope
[ 30522, 13366, 8518, 1035, 1999, 1035, 9531, 1006, 9531, 1007, 17576, 1027, 9531, 1012, 4130, 8518, 1012, 7276, 1063, 1064, 1056, 1064, 1013, 1034, 1001, 1063, 17576, 1065, 1024, 1013, 1027, 1066, 1056, 1012, 2171, 1065, 2203, 102, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
appium/ruby_lib
lib/appium_lib/ios/common/helper.rb
Appium.Ios._by_json
def _by_json(opts) valid_keys = %i(typeArray onlyFirst onlyVisible name label value) unknown_keys = opts.keys - valid_keys raise "Unknown keys: #{unknown_keys}" unless unknown_keys.empty? type_array = opts[:typeArray] raise 'typeArray must be an array' unless type_array.is_a? Array ...
ruby
def _by_json(opts) valid_keys = %i(typeArray onlyFirst onlyVisible name label value) unknown_keys = opts.keys - valid_keys raise "Unknown keys: #{unknown_keys}" unless unknown_keys.empty? type_array = opts[:typeArray] raise 'typeArray must be an array' unless type_array.is_a? Array ...
[ "def", "_by_json", "(", "opts", ")", "valid_keys", "=", "%i(", "typeArray", "onlyFirst", "onlyVisible", "name", "label", "value", ")", "unknown_keys", "=", "opts", ".", "keys", "-", "valid_keys", "raise", "\"Unknown keys: #{unknown_keys}\"", "unless", "unknown_keys"...
For Appium(automation name), not XCUITest typeArray - array of string types to search for. Example: ["UIAStaticText"] onlyFirst - boolean. returns only the first result if true. Example: true onlyVisible - boolean. returns only visible elements if true. Example: true target - string. the target value to search for....
[ "For", "Appium", "(", "automation", "name", ")", "not", "XCUITest", "typeArray", "-", "array", "of", "string", "types", "to", "search", "for", ".", "Example", ":", "[", "UIAStaticText", "]", "onlyFirst", "-", "boolean", ".", "returns", "only", "the", "firs...
1f5898400dd1928bfe42ddd5f842d1f8738f2f76
https://github.com/appium/ruby_lib/blob/1f5898400dd1928bfe42ddd5f842d1f8738f2f76/lib/appium_lib/ios/common/helper.rb#L455-L491
train
Returns an array of elements that are of the specified type.
[ 30522, 13366, 1035, 2011, 1035, 1046, 3385, 1006, 23569, 2015, 1007, 9398, 1035, 6309, 1027, 1003, 1045, 1006, 2828, 2906, 9447, 2069, 8873, 12096, 2069, 11365, 7028, 2171, 3830, 3643, 1007, 4242, 1035, 6309, 1027, 23569, 2015, 1012, 6309, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/features.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Features.list_application_version_pattern_features
def list_application_version_pattern_features(app_id, version_id, skip:0, take:100, custom_headers:nil) response = list_application_version_pattern_features_async(app_id, version_id, skip:skip, take:take, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_application_version_pattern_features(app_id, version_id, skip:0, take:100, custom_headers:nil) response = list_application_version_pattern_features_async(app_id, version_id, skip:skip, take:take, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_application_version_pattern_features", "(", "app_id", ",", "version_id", ",", "skip", ":", "0", ",", "take", ":", "100", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_application_version_pattern_features_async", "(", "app_id", ",", "ver...
[DEPRECATED NOTICE: This operation will soon be removed] Gets all the pattern features. @param app_id The application ID. @param version_id [String] The version ID. @param skip [Integer] The number of entries to skip. Default value is 0. @param take [Integer] The number of entries to return. Maximum page size is ...
[ "[", "DEPRECATED", "NOTICE", ":", "This", "operation", "will", "soon", "be", "removed", "]", "Gets", "all", "the", "pattern", "features", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/features.rb#L38-L41
train
Gets the list of pattern features for the application version.
[ 30522, 13366, 2862, 1035, 4646, 1035, 2544, 1035, 5418, 1035, 2838, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 13558, 1024, 1014, 1010, 2202, 1024, 2531, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
fastlane/fastlane
deliver/lib/deliver/runner.rb
Deliver.Runner.precheck_app
def precheck_app return true unless options[:run_precheck_before_submit] UI.message("Running precheck before submitting to review, if you'd like to disable this check you can set run_precheck_before_submit to false") if options[:submit_for_review] UI.message("Making sure we pass precheck 👮‍♀...
ruby
def precheck_app return true unless options[:run_precheck_before_submit] UI.message("Running precheck before submitting to review, if you'd like to disable this check you can set run_precheck_before_submit to false") if options[:submit_for_review] UI.message("Making sure we pass precheck 👮‍♀...
[ "def", "precheck_app", "return", "true", "unless", "options", "[", ":run_precheck_before_submit", "]", "UI", ".", "message", "(", "\"Running precheck before submitting to review, if you'd like to disable this check you can set run_precheck_before_submit to false\"", ")", "if", "optio...
Make sure we pass precheck before uploading
[ "Make", "sure", "we", "pass", "precheck", "before", "uploading" ]
457c5d647c77f0e078dafa5129da616914e002c5
https://github.com/fastlane/fastlane/blob/457c5d647c77f0e078dafa5129da616914e002c5/deliver/lib/deliver/runner.rb#L54-L84
train
This method is called by the precheck_app method.
[ 30522, 13366, 3653, 5403, 3600, 1035, 10439, 2709, 2995, 4983, 7047, 1031, 1024, 2448, 1035, 3653, 5403, 3600, 1035, 2077, 1035, 12040, 1033, 21318, 1012, 4471, 1006, 1000, 2770, 3653, 5403, 3600, 2077, 12040, 3436, 2000, 3319, 1010, 2065, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_policy_insights/lib/2018-07-01-preview/generated/azure_mgmt_policy_insights/remediations.rb
Azure::PolicyInsights::Mgmt::V2018_07_01_preview.Remediations.create_or_update_at_subscription
def create_or_update_at_subscription(remediation_name, parameters, custom_headers:nil) response = create_or_update_at_subscription_async(remediation_name, parameters, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def create_or_update_at_subscription(remediation_name, parameters, custom_headers:nil) response = create_or_update_at_subscription_async(remediation_name, parameters, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "create_or_update_at_subscription", "(", "remediation_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_or_update_at_subscription_async", "(", "remediation_name", ",", "parameters", ",", "custom_headers", ":custom_headers", ")...
Creates or updates a remediation at subscription scope. @param remediation_name [String] The name of the remediation. @param parameters [Remediation] The remediation parameters. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [Remediation] o...
[ "Creates", "or", "updates", "a", "remediation", "at", "subscription", "scope", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_policy_insights/lib/2018-07-01-preview/generated/azure_mgmt_policy_insights/remediations.rb#L899-L902
train
Creates or updates a remediation at subscription scope.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1035, 2012, 1035, 15002, 1006, 2128, 16969, 3508, 1035, 2171, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3443, 1035, 2030, 1035, 10651, 1035, 2012, 1035, 1500...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_contentmoderator/lib/1.0/generated/azure_cognitiveservices_contentmoderator/list_management_term_lists.rb
Azure::CognitiveServices::ContentModerator::V1_0.ListManagementTermLists.delete
def delete(list_id, custom_headers:nil) response = delete_async(list_id, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def delete(list_id, custom_headers:nil) response = delete_async(list_id, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "delete", "(", "list_id", ",", "custom_headers", ":", "nil", ")", "response", "=", "delete_async", "(", "list_id", ",", "custom_headers", ":custom_headers", ")", ".", "value!", "response", ".", "body", "unless", "response", ".", "nil?", "end" ]
Deletes term list with the list Id equal to list Id passed. @param list_id [String] List Id of the image list. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [String] operation results.
[ "Deletes", "term", "list", "with", "the", "list", "Id", "equal", "to", "list", "Id", "passed", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_contentmoderator/lib/1.0/generated/azure_cognitiveservices_contentmoderator/list_management_term_lists.rb#L133-L136
train
Deletes a list.
[ 30522, 13366, 3972, 12870, 1006, 2862, 1035, 8909, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3972, 12870, 1035, 2004, 6038, 2278, 1006, 2862, 1035, 8909, 1010, 7661, 1035, 20346, 2015, 1024, 7661, 1035, 20346, 2015,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_resources_management/lib/2017-11-01-preview/generated/azure_mgmt_resources_management/management_groups.rb
Azure::ResourcesManagement::Mgmt::V2017_11_01_preview.ManagementGroups.create_or_update_with_http_info
def create_or_update_with_http_info(group_id, create_management_group_request, cache_control:'no-cache', custom_headers:nil) create_or_update_async(group_id, create_management_group_request, cache_control:cache_control, custom_headers:custom_headers).value! end
ruby
def create_or_update_with_http_info(group_id, create_management_group_request, cache_control:'no-cache', custom_headers:nil) create_or_update_async(group_id, create_management_group_request, cache_control:cache_control, custom_headers:custom_headers).value! end
[ "def", "create_or_update_with_http_info", "(", "group_id", ",", "create_management_group_request", ",", "cache_control", ":", "'no-cache'", ",", "custom_headers", ":", "nil", ")", "create_or_update_async", "(", "group_id", ",", "create_management_group_request", ",", "cache...
Create or update a management group. If a management group is already created and a subsequent create request is issued with different properties, the management group properties will be updated. @param group_id [String] Management Group ID. @param create_management_group_request [CreateManagementGroupRequest] ...
[ "Create", "or", "update", "a", "management", "group", ".", "If", "a", "management", "group", "is", "already", "created", "and", "a", "subsequent", "create", "request", "is", "issued", "with", "different", "properties", "the", "management", "group", "properties",...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_resources_management/lib/2017-11-01-preview/generated/azure_mgmt_resources_management/management_groups.rb#L289-L291
train
Creates or updates a management group.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 2177, 1035, 8909, 1010, 3443, 1035, 2968, 1035, 2177, 1035, 5227, 1010, 17053, 1035, 2491, 1024, 1005, 2053, 1011, 17053, 1005, 1010, 7661, 1035, 20346,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
collectiveidea/audited
lib/audited/audit.rb
Audited.Audit.revision
def revision clazz = auditable_type.constantize (clazz.find_by_id(auditable_id) || clazz.new).tap do |m| self.class.assign_revision_attributes(m, self.class.reconstruct_attributes(ancestors).merge(audit_version: version)) end end
ruby
def revision clazz = auditable_type.constantize (clazz.find_by_id(auditable_id) || clazz.new).tap do |m| self.class.assign_revision_attributes(m, self.class.reconstruct_attributes(ancestors).merge(audit_version: version)) end end
[ "def", "revision", "clazz", "=", "auditable_type", ".", "constantize", "(", "clazz", ".", "find_by_id", "(", "auditable_id", ")", "||", "clazz", ".", "new", ")", ".", "tap", "do", "|", "m", "|", "self", ".", "class", ".", "assign_revision_attributes", "(",...
Return an instance of what the object looked like at this revision. If the object has been destroyed, this will be a new record.
[ "Return", "an", "instance", "of", "what", "the", "object", "looked", "like", "at", "this", "revision", ".", "If", "the", "object", "has", "been", "destroyed", "this", "will", "be", "a", "new", "record", "." ]
af5d51b45368eabb0e727d064faf29f4af6e1458
https://github.com/collectiveidea/audited/blob/af5d51b45368eabb0e727d064faf29f4af6e1458/lib/audited/audit.rb#L65-L70
train
Returns the unique ID for the revision
[ 30522, 13366, 13921, 18856, 10936, 2480, 1027, 15727, 3085, 1035, 2828, 1012, 5377, 4697, 1006, 18856, 10936, 2480, 1012, 2424, 1035, 2011, 1035, 8909, 1006, 15727, 3085, 1035, 8909, 1007, 1064, 1064, 18856, 10936, 2480, 1012, 2047, 1007, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
kmuto/review
lib/epubmaker/epubv2.rb
EPUBMaker.EPUBv2.opf
def opf @opf_metainfo = opf_metainfo @opf_coverimage = opf_coverimage @opf_manifest = opf_manifest @opf_toc = opf_tocx tmplfile = File.expand_path('./opf/epubv2.opf.erb', ReVIEW::Template::TEMPLATE_DIR) tmpl = ReVIEW::Template.load(tmplfile) tmpl.result(binding) end
ruby
def opf @opf_metainfo = opf_metainfo @opf_coverimage = opf_coverimage @opf_manifest = opf_manifest @opf_toc = opf_tocx tmplfile = File.expand_path('./opf/epubv2.opf.erb', ReVIEW::Template::TEMPLATE_DIR) tmpl = ReVIEW::Template.load(tmplfile) tmpl.result(binding) end
[ "def", "opf", "@opf_metainfo", "=", "opf_metainfo", "@opf_coverimage", "=", "opf_coverimage", "@opf_manifest", "=", "opf_manifest", "@opf_toc", "=", "opf_tocx", "tmplfile", "=", "File", ".", "expand_path", "(", "'./opf/epubv2.opf.erb'", ",", "ReVIEW", "::", "Template"...
Construct object with parameter hash +config+ and message resource hash +res+. Return opf file content.
[ "Construct", "object", "with", "parameter", "hash", "+", "config", "+", "and", "message", "resource", "hash", "+", "res", "+", ".", "Return", "opf", "file", "content", "." ]
77d1273e671663f05db2992281fd891b776badf0
https://github.com/kmuto/review/blob/77d1273e671663f05db2992281fd891b776badf0/lib/epubmaker/epubv2.rb#L24-L33
train
Get the opf object from the file
[ 30522, 13366, 6728, 2546, 1030, 6728, 2546, 1035, 18804, 2378, 14876, 1027, 6728, 2546, 1035, 18804, 2378, 14876, 1030, 6728, 2546, 1035, 3104, 9581, 3351, 1027, 6728, 2546, 1035, 3104, 9581, 3351, 1030, 6728, 2546, 1035, 19676, 1027, 6728,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
castwide/solargraph
lib/solargraph/workspace.rb
Solargraph.Workspace.merge
def merge source unless directory == '*' || source_hash.key?(source.filename) # Reload the config to determine if a new source should be included @config = Solargraph::Workspace::Config.new(directory) return false unless config.calculated.include?(source.filename) end source_ha...
ruby
def merge source unless directory == '*' || source_hash.key?(source.filename) # Reload the config to determine if a new source should be included @config = Solargraph::Workspace::Config.new(directory) return false unless config.calculated.include?(source.filename) end source_ha...
[ "def", "merge", "source", "unless", "directory", "==", "'*'", "||", "source_hash", ".", "key?", "(", "source", ".", "filename", ")", "# Reload the config to determine if a new source should be included", "@config", "=", "Solargraph", "::", "Workspace", "::", "Config", ...
Merge the source. A merge will update the existing source for the file or add it to the sources if the workspace is configured to include it. The source is ignored if the configuration excludes it. @param source [Solargraph::Source] @return [Boolean] True if the source was added to the workspace
[ "Merge", "the", "source", ".", "A", "merge", "will", "update", "the", "existing", "source", "for", "the", "file", "or", "add", "it", "to", "the", "sources", "if", "the", "workspace", "is", "configured", "to", "include", "it", ".", "The", "source", "is", ...
47badb5d151aca775ccbe6c470236089eae7839d
https://github.com/castwide/solargraph/blob/47badb5d151aca775ccbe6c470236089eae7839d/lib/solargraph/workspace.rb#L31-L39
train
Merge the source file with the current one
[ 30522, 13366, 13590, 3120, 4983, 14176, 1027, 1027, 1005, 1008, 1005, 1064, 1064, 3120, 1035, 23325, 1012, 3145, 1029, 1006, 3120, 1012, 5371, 18442, 1007, 1001, 2128, 11066, 1996, 9530, 8873, 2290, 2000, 5646, 2065, 1037, 2047, 3120, 2323,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_sql/lib/2015-05-01-preview/generated/azure_mgmt_sql/sync_groups.rb
Azure::SQL::Mgmt::V2015_05_01_preview.SyncGroups.cancel_sync
def cancel_sync(resource_group_name, server_name, database_name, sync_group_name, custom_headers:nil) response = cancel_sync_async(resource_group_name, server_name, database_name, sync_group_name, custom_headers:custom_headers).value! nil end
ruby
def cancel_sync(resource_group_name, server_name, database_name, sync_group_name, custom_headers:nil) response = cancel_sync_async(resource_group_name, server_name, database_name, sync_group_name, custom_headers:custom_headers).value! nil end
[ "def", "cancel_sync", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",", "sync_group_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "cancel_sync_async", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",",...
Cancels a sync group synchronization. @param resource_group_name [String] The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. @param server_name [String] The name of the server. @param database_name [String] The name of the databa...
[ "Cancels", "a", "sync", "group", "synchronization", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_sql/lib/2015-05-01-preview/generated/azure_mgmt_sql/sync_groups.rb#L416-L419
train
Cancels a sync group.
[ 30522, 13366, 17542, 1035, 26351, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8241, 1035, 2171, 1010, 7809, 1035, 2171, 1010, 26351, 1035, 2177, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 17542, 1035, 26351...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
sds/haml-lint
lib/haml_lint/utils.rb
HamlLint.Utils.extract_interpolated_values
def extract_interpolated_values(text) # rubocop:disable Metrics/AbcSize dumped_text = text.dump newline_positions = extract_substring_positions(dumped_text, '\\\n') Haml::Util.handle_interpolation(dumped_text) do |scan| line = (newline_positions.find_index { |marker| scan.pos <= marker } || ...
ruby
def extract_interpolated_values(text) # rubocop:disable Metrics/AbcSize dumped_text = text.dump newline_positions = extract_substring_positions(dumped_text, '\\\n') Haml::Util.handle_interpolation(dumped_text) do |scan| line = (newline_positions.find_index { |marker| scan.pos <= marker } || ...
[ "def", "extract_interpolated_values", "(", "text", ")", "# rubocop:disable Metrics/AbcSize", "dumped_text", "=", "text", ".", "dump", "newline_positions", "=", "extract_substring_positions", "(", "dumped_text", ",", "'\\\\\\n'", ")", "Haml", "::", "Util", ".", "handle_i...
Yields interpolated values within a block of text. @param text [String] @yield Passes interpolated code and line number that code appears on in the text. @yieldparam interpolated_code [String] code that was interpolated @yieldparam line [Integer] line number code appears on in text
[ "Yields", "interpolated", "values", "within", "a", "block", "of", "text", "." ]
024c773667e54cf88db938c2b368977005d70ee8
https://github.com/sds/haml-lint/blob/024c773667e54cf88db938c2b368977005d70ee8/lib/haml_lint/utils.rb#L55-L71
train
Extract interpolated values from a text
[ 30522, 13366, 14817, 1035, 6970, 18155, 4383, 1035, 5300, 1006, 3793, 1007, 1001, 14548, 24163, 2361, 1024, 4487, 19150, 12046, 2015, 1013, 5925, 5332, 4371, 14019, 1035, 3793, 1027, 3793, 1012, 15653, 2047, 4179, 1035, 4460, 1027, 14817, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
rmagick/rmagick
lib/rvg/rvg.rb
Magick.RVG.ref
def ref(x, y, rw, rh) #:nodoc: translate(x, y) if x != 0 || y != 0 @width = rw if rw @height = rh if rh end
ruby
def ref(x, y, rw, rh) #:nodoc: translate(x, y) if x != 0 || y != 0 @width = rw if rw @height = rh if rh end
[ "def", "ref", "(", "x", ",", "y", ",", "rw", ",", "rh", ")", "#:nodoc:", "translate", "(", "x", ",", "y", ")", "if", "x", "!=", "0", "||", "y", "!=", "0", "@width", "=", "rw", "if", "rw", "@height", "=", "rh", "if", "rh", "end" ]
Accept #use arguments. Use (x,y) to generate an additional translate. Override @width and @height if new values are supplied.
[ "Accept", "#use", "arguments", ".", "Use", "(", "x", "y", ")", "to", "generate", "an", "additional", "translate", ".", "Override" ]
ef6688ed9d76bf123c2ea1a483eff8635051adb7
https://github.com/rmagick/rmagick/blob/ef6688ed9d76bf123c2ea1a483eff8635051adb7/lib/rvg/rvg.rb#L245-L249
train
Sets the reference to the given coordinates.
[ 30522, 13366, 25416, 1006, 1060, 1010, 1061, 1010, 1054, 2860, 1010, 1054, 2232, 1007, 1001, 1024, 7293, 10085, 1024, 17637, 1006, 1060, 1010, 1061, 1007, 2065, 1060, 999, 1027, 1014, 1064, 1064, 1061, 999, 1027, 1014, 1030, 9381, 1027, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
heroku/legacy-cli
lib/heroku/command/addons.rb
Heroku::Command.Addons.index
def index validate_arguments! requires_preauth # Filters are mutually exclusive error("Can not use --all with --app") if options[:app] && options[:all] error("Can not use --all with --resource") if options[:resource] && options[:all] error("Can not use --app with --resource") i...
ruby
def index validate_arguments! requires_preauth # Filters are mutually exclusive error("Can not use --all with --app") if options[:app] && options[:all] error("Can not use --all with --resource") if options[:resource] && options[:all] error("Can not use --app with --resource") i...
[ "def", "index", "validate_arguments!", "requires_preauth", "# Filters are mutually exclusive", "error", "(", "\"Can not use --all with --app\"", ")", "if", "options", "[", ":app", "]", "&&", "options", "[", ":all", "]", "error", "(", "\"Can not use --all with --resource\"",...
addons [{--all,--app APP_NAME,--resource ADDON_NAME}] list installed add-ons NOTE: --all is the default unless in an application repository directory, in which case --all is inferred. --all # list add-ons across all apps in account --app APP_NAME # list add-ons associated with a given a...
[ "addons", "[", "{", "--", "all", "--", "app", "APP_NAME", "--", "resource", "ADDON_NAME", "}", "]" ]
6f18521a258394bfb79e6b36f7160ad8559a8e16
https://github.com/heroku/legacy-cli/blob/6f18521a258394bfb79e6b36f7160ad8559a8e16/lib/heroku/command/addons.rb#L35-L52
train
Returns the number of objects in the index.
[ 30522, 13366, 5950, 9398, 3686, 1035, 9918, 999, 5942, 1035, 3653, 4887, 2705, 1001, 17736, 2024, 20271, 7262, 7561, 1006, 1000, 2064, 2025, 2224, 1011, 1011, 2035, 2007, 1011, 1011, 10439, 1000, 1007, 2065, 7047, 1031, 1024, 10439, 1033, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Model.add_sub_list_with_http_info
def add_sub_list_with_http_info(app_id, version_id, cl_entity_id, word_list_create_object, custom_headers:nil) add_sub_list_async(app_id, version_id, cl_entity_id, word_list_create_object, custom_headers:custom_headers).value! end
ruby
def add_sub_list_with_http_info(app_id, version_id, cl_entity_id, word_list_create_object, custom_headers:nil) add_sub_list_async(app_id, version_id, cl_entity_id, word_list_create_object, custom_headers:custom_headers).value! end
[ "def", "add_sub_list_with_http_info", "(", "app_id", ",", "version_id", ",", "cl_entity_id", ",", "word_list_create_object", ",", "custom_headers", ":", "nil", ")", "add_sub_list_async", "(", "app_id", ",", "version_id", ",", "cl_entity_id", ",", "word_list_create_objec...
Adds a sublist to an existing list entity in a version of the application. @param app_id The application ID. @param version_id [String] The version ID. @param cl_entity_id The list entity extractor ID. @param word_list_create_object [WordListObject] Words list. @param custom_headers [Hash{String => String}] A has...
[ "Adds", "a", "sublist", "to", "an", "existing", "list", "entity", "in", "a", "version", "of", "the", "application", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb#L4115-L4117
train
Adds a list of words to the list of words.
[ 30522, 13366, 5587, 1035, 4942, 1035, 2862, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 18856, 1035, 9178, 1035, 8909, 1010, 2773, 1035, 2862, 1035, 3443, 1035, 4874, 1010, 7661, 1035, 20346, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
piotrmurach/github
lib/github_api/client/projects/cards.rb
Github.Client::Projects::Cards.update
def update(*args) arguments(args, required: [:card_id]) params = arguments.params params["accept"] ||= ::Github::Client::Projects::PREVIEW_MEDIA patch_request("/projects/columns/cards/#{arguments.card_id}", params) end
ruby
def update(*args) arguments(args, required: [:card_id]) params = arguments.params params["accept"] ||= ::Github::Client::Projects::PREVIEW_MEDIA patch_request("/projects/columns/cards/#{arguments.card_id}", params) end
[ "def", "update", "(", "*", "args", ")", "arguments", "(", "args", ",", "required", ":", "[", ":card_id", "]", ")", "params", "=", "arguments", ".", "params", "params", "[", "\"accept\"", "]", "||=", "::", "Github", "::", "Client", "::", "Projects", "::...
Update a project card @param [Hash] params @option params [String] :note The card's note content. Only valid for cards without another type of content, so this cannot be specified if the card already has a content_id and content_type. @example github = Github.new github.projects.cards.update :card_i...
[ "Update", "a", "project", "card" ]
8702452c66bea33c9388550aed9e9974f76aaef1
https://github.com/piotrmurach/github/blob/8702452c66bea33c9388550aed9e9974f76aaef1/lib/github_api/client/projects/cards.rb#L99-L106
train
Update a card
[ 30522, 13366, 10651, 1006, 1008, 12098, 5620, 1007, 9918, 1006, 12098, 5620, 1010, 3223, 1024, 1031, 1024, 4003, 1035, 8909, 1033, 1007, 11498, 5244, 1027, 9918, 1012, 11498, 5244, 11498, 5244, 1031, 1000, 5138, 1000, 1033, 1064, 1064, 1027...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
capistrano/capistrano
lib/capistrano/dsl.rb
Capistrano.DSL.on
def on(hosts, options={}, &block) subset_copy = Marshal.dump(Configuration.env.filter(hosts)) SSHKit::Coordinator.new(Marshal.load(subset_copy)).each(options, &block) end
ruby
def on(hosts, options={}, &block) subset_copy = Marshal.dump(Configuration.env.filter(hosts)) SSHKit::Coordinator.new(Marshal.load(subset_copy)).each(options, &block) end
[ "def", "on", "(", "hosts", ",", "options", "=", "{", "}", ",", "&", "block", ")", "subset_copy", "=", "Marshal", ".", "dump", "(", "Configuration", ".", "env", ".", "filter", "(", "hosts", ")", ")", "SSHKit", "::", "Coordinator", ".", "new", "(", "...
rubocop:disable Security/MarshalLoad
[ "rubocop", ":", "disable", "Security", "/", "MarshalLoad" ]
7a14ddb47d64187c8a7ee14c7d78e874f30f08ef
https://github.com/capistrano/capistrano/blob/7a14ddb47d64187c8a7ee14c7d78e874f30f08ef/lib/capistrano/dsl.rb#L69-L72
train
Initialize a new coordinator
[ 30522, 13366, 2006, 1006, 6184, 1010, 7047, 1027, 1063, 1065, 1010, 1004, 3796, 1007, 16745, 1035, 6100, 1027, 8610, 1012, 15653, 1006, 9563, 1012, 4372, 2615, 1012, 11307, 1006, 6184, 1007, 1007, 7020, 2232, 23615, 1024, 1024, 10669, 1012,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
mongodb/mongo-ruby-driver
lib/mongo/session.rb
Mongo.Session.end_session
def end_session if !ended? && @client if within_states?(TRANSACTION_IN_PROGRESS_STATE) begin abort_transaction rescue Mongo::Error end end @client.cluster.session_pool.checkin(@server_session) end ensure @server_session = nil en...
ruby
def end_session if !ended? && @client if within_states?(TRANSACTION_IN_PROGRESS_STATE) begin abort_transaction rescue Mongo::Error end end @client.cluster.session_pool.checkin(@server_session) end ensure @server_session = nil en...
[ "def", "end_session", "if", "!", "ended?", "&&", "@client", "if", "within_states?", "(", "TRANSACTION_IN_PROGRESS_STATE", ")", "begin", "abort_transaction", "rescue", "Mongo", "::", "Error", "end", "end", "@client", ".", "cluster", ".", "session_pool", ".", "check...
End this session. @example session.end_session @return [ nil ] Always nil. @since 2.5.0
[ "End", "this", "session", "." ]
dca26d0870cb3386fad9ccc1d17228097c1fe1c8
https://github.com/mongodb/mongo-ruby-driver/blob/dca26d0870cb3386fad9ccc1d17228097c1fe1c8/lib/mongo/session.rb#L168-L180
train
End the session
[ 30522, 13366, 2203, 1035, 5219, 2065, 999, 3092, 1029, 1004, 1004, 1030, 7396, 2065, 2306, 1035, 2163, 1029, 1006, 12598, 1035, 1999, 1035, 5082, 1035, 2110, 1007, 4088, 11113, 11589, 1035, 12598, 5343, 12256, 3995, 1024, 1024, 7561, 2203, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_datalake_analytics/lib/2015-10-01-preview/generated/azure_mgmt_datalake_analytics/account.rb
Azure::DataLakeAnalytics::Mgmt::V2015_10_01_preview.Account.delete_storage_account
def delete_storage_account(resource_group_name, account_name, storage_account_name, custom_headers:nil) response = delete_storage_account_async(resource_group_name, account_name, storage_account_name, custom_headers:custom_headers).value! nil end
ruby
def delete_storage_account(resource_group_name, account_name, storage_account_name, custom_headers:nil) response = delete_storage_account_async(resource_group_name, account_name, storage_account_name, custom_headers:custom_headers).value! nil end
[ "def", "delete_storage_account", "(", "resource_group_name", ",", "account_name", ",", "storage_account_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "delete_storage_account_async", "(", "resource_group_name", ",", "account_name", ",", "storage_account_nam...
Updates the specified Data Lake Analytics account to remove an Azure Storage account. @param resource_group_name [String] The name of the Azure resource group that contains the Data Lake Analytics account. @param account_name [String] The name of the Data Lake Analytics account from which to remove the Azure Stor...
[ "Updates", "the", "specified", "Data", "Lake", "Analytics", "account", "to", "remove", "an", "Azure", "Storage", "account", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_datalake_analytics/lib/2015-10-01-preview/generated/azure_mgmt_datalake_analytics/account.rb#L146-L149
train
Deletes the specified storage account.
[ 30522, 13366, 3972, 12870, 1035, 5527, 1035, 4070, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 4070, 1035, 2171, 1010, 5527, 1035, 4070, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3972, 12870, 1035, 5527, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
mojombo/chronic
lib/chronic/repeaters/repeater_day.rb
Chronic.RepeaterDay.next
def next(pointer) super unless @current_day_start @current_day_start = Chronic.time_class.local(@now.year, @now.month, @now.day) end direction = pointer == :future ? 1 : -1 @current_day_start += direction * DAY_SECONDS Span.new(@current_day_start, @current_day_start + DAY_...
ruby
def next(pointer) super unless @current_day_start @current_day_start = Chronic.time_class.local(@now.year, @now.month, @now.day) end direction = pointer == :future ? 1 : -1 @current_day_start += direction * DAY_SECONDS Span.new(@current_day_start, @current_day_start + DAY_...
[ "def", "next", "(", "pointer", ")", "super", "unless", "@current_day_start", "@current_day_start", "=", "Chronic", ".", "time_class", ".", "local", "(", "@now", ".", "year", ",", "@now", ".", "month", ",", "@now", ".", "day", ")", "end", "direction", "=", ...
(24 * 60 * 60)
[ "(", "24", "*", "60", "*", "60", ")" ]
2b1eae7ec440d767c09e0b1a7f0e9bcf30ce1d6c
https://github.com/mojombo/chronic/blob/2b1eae7ec440d767c09e0b1a7f0e9bcf30ce1d6c/lib/chronic/repeaters/repeater_day.rb#L10-L21
train
Returns the next segment of the segment
[ 30522, 13366, 2279, 1006, 20884, 1007, 3565, 4983, 1030, 2783, 1035, 2154, 1035, 2707, 1030, 2783, 1035, 2154, 1035, 2707, 1027, 11888, 1012, 2051, 1035, 2465, 1012, 2334, 1006, 1030, 2085, 1012, 2095, 1010, 30524, 1015, 1024, 1011, 1015, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
puppetlabs/puppet
lib/puppet/util/windows/sid.rb
Puppet::Util::Windows.SID.sid_to_name
def sid_to_name(value) sid_bytes = [] begin string_to_sid_ptr(value) do |ptr| sid_bytes = ptr.read_array_of_uchar(get_length_sid(ptr)) end rescue Puppet::Util::Windows::Error => e raise if e.code != ERROR_INVALID_SID_STRUCTURE end Principal.lookup_accoun...
ruby
def sid_to_name(value) sid_bytes = [] begin string_to_sid_ptr(value) do |ptr| sid_bytes = ptr.read_array_of_uchar(get_length_sid(ptr)) end rescue Puppet::Util::Windows::Error => e raise if e.code != ERROR_INVALID_SID_STRUCTURE end Principal.lookup_accoun...
[ "def", "sid_to_name", "(", "value", ")", "sid_bytes", "=", "[", "]", "begin", "string_to_sid_ptr", "(", "value", ")", "do", "|", "ptr", "|", "sid_bytes", "=", "ptr", ".", "read_array_of_uchar", "(", "get_length_sid", "(", "ptr", ")", ")", "end", "rescue", ...
Convert a SID string, e.g. "S-1-5-32-544" to a name, e.g. 'BUILTIN\Administrators'. Returns nil if an account for that SID does not exist.
[ "Convert", "a", "SID", "string", "e", ".", "g", ".", "S", "-", "1", "-", "5", "-", "32", "-", "544", "to", "a", "name", "e", ".", "g", ".", "BUILTIN", "\\", "Administrators", ".", "Returns", "nil", "if", "an", "account", "for", "that", "SID", "...
4baeed97cbb7571ddc6635f0a24debe2e8b22cd3
https://github.com/puppetlabs/puppet/blob/4baeed97cbb7571ddc6635f0a24debe2e8b22cd3/lib/puppet/util/windows/sid.rb#L131-L145
train
Convert a string to a name
[ 30522, 13366, 15765, 1035, 2000, 1035, 2171, 1006, 3643, 1007, 15765, 1035, 27507, 1027, 1031, 1033, 4088, 5164, 1035, 2000, 1035, 15765, 1035, 13866, 2099, 1006, 3643, 1007, 2079, 1064, 13866, 2099, 1064, 15765, 1035, 27507, 1027, 13866, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
sds/haml-lint
lib/haml_lint/configuration.rb
HamlLint.Configuration.resolve_requires
def resolve_requires relative_require_dir = @config_dir || Dir.pwd Array(@hash['require']).each do |r| if r.start_with?('.') require File.join(relative_require_dir, r) else require r end end end
ruby
def resolve_requires relative_require_dir = @config_dir || Dir.pwd Array(@hash['require']).each do |r| if r.start_with?('.') require File.join(relative_require_dir, r) else require r end end end
[ "def", "resolve_requires", "relative_require_dir", "=", "@config_dir", "||", "Dir", ".", "pwd", "Array", "(", "@hash", "[", "'require'", "]", ")", ".", "each", "do", "|", "r", "|", "if", "r", ".", "start_with?", "(", "'.'", ")", "require", "File", ".", ...
Requires any extra linters / files specified in the configuration. String starting with a . are treated as relative paths
[ "Requires", "any", "extra", "linters", "/", "files", "specified", "in", "the", "configuration", ".", "String", "starting", "with", "a", ".", "are", "treated", "as", "relative", "paths" ]
024c773667e54cf88db938c2b368977005d70ee8
https://github.com/sds/haml-lint/blob/024c773667e54cf88db938c2b368977005d70ee8/lib/haml_lint/configuration.rb#L84-L93
train
Resolve the requires array
[ 30522, 13366, 10663, 1035, 5942, 5816, 1035, 5478, 1035, 16101, 1027, 1030, 9530, 8873, 2290, 1035, 16101, 1064, 1064, 16101, 1012, 1052, 21724, 9140, 1006, 1030, 23325, 1031, 1005, 5478, 1005, 1033, 1007, 1012, 2169, 2079, 1064, 1054, 1064...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_api_management/lib/2018-01-01/generated/azure_mgmt_api_management/tag.rb
Azure::ApiManagement::Mgmt::V2018_01_01.Tag.get_entity_state_by_product_with_http_info
def get_entity_state_by_product_with_http_info(resource_group_name, service_name, product_id, tag_id, custom_headers:nil) get_entity_state_by_product_async(resource_group_name, service_name, product_id, tag_id, custom_headers:custom_headers).value! end
ruby
def get_entity_state_by_product_with_http_info(resource_group_name, service_name, product_id, tag_id, custom_headers:nil) get_entity_state_by_product_async(resource_group_name, service_name, product_id, tag_id, custom_headers:custom_headers).value! end
[ "def", "get_entity_state_by_product_with_http_info", "(", "resource_group_name", ",", "service_name", ",", "product_id", ",", "tag_id", ",", "custom_headers", ":", "nil", ")", "get_entity_state_by_product_async", "(", "resource_group_name", ",", "service_name", ",", "produc...
Gets the entity state version of the tag specified by its identifier. @param resource_group_name [String] The name of the resource group. @param service_name [String] The name of the API Management service. @param product_id [String] Product identifier. Must be unique in the current API Management service instance...
[ "Gets", "the", "entity", "state", "version", "of", "the", "tag", "specified", "by", "its", "identifier", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_api_management/lib/2018-01-01/generated/azure_mgmt_api_management/tag.rb#L2158-L2160
train
Gets the entity state of the specified product.
[ 30522, 13366, 2131, 1035, 9178, 1035, 2110, 1035, 2011, 1035, 4031, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2326, 1035, 2171, 1010, 4031, 1035, 8909, 1010, 6415, 1035, 8909, 1010, 7661, 1035, 20346, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_compute/lib/2016-04-30-preview/generated/azure_mgmt_compute/virtual_machines.rb
Azure::Compute::Mgmt::V2016_04_30_preview.VirtualMachines.restart
def restart(resource_group_name, vm_name, custom_headers:nil) response = restart_async(resource_group_name, vm_name, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def restart(resource_group_name, vm_name, custom_headers:nil) response = restart_async(resource_group_name, vm_name, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "restart", "(", "resource_group_name", ",", "vm_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "restart_async", "(", "resource_group_name", ",", "vm_name", ",", "custom_headers", ":custom_headers", ")", ".", "value!", "response", ".", "body...
The operation to restart a virtual machine. @param resource_group_name [String] The name of the resource group. @param vm_name [String] The name of the virtual machine. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [OperationStatusResponse...
[ "The", "operation", "to", "restart", "a", "virtual", "machine", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_compute/lib/2016-04-30-preview/generated/azure_mgmt_compute/virtual_machines.rb#L863-L866
train
Restarts a virtual machine.
[ 30522, 13366, 23818, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 1058, 2213, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 23818, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 1058, 2213, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_service_fabric/lib/6.2.0.9/generated/azure_service_fabric/service_fabric_client_apis.rb
Azure::ServiceFabric::V6_2_0_9.ServiceFabricClientAPIs.create_name_with_http_info
def create_name_with_http_info(name_description, timeout:60, custom_headers:nil) create_name_async(name_description, timeout:timeout, custom_headers:custom_headers).value! end
ruby
def create_name_with_http_info(name_description, timeout:60, custom_headers:nil) create_name_async(name_description, timeout:timeout, custom_headers:custom_headers).value! end
[ "def", "create_name_with_http_info", "(", "name_description", ",", "timeout", ":", "60", ",", "custom_headers", ":", "nil", ")", "create_name_async", "(", "name_description", ",", "timeout", ":", "timeout", ",", "custom_headers", ":custom_headers", ")", ".", "value!...
Creates a Service Fabric name. Creates the specified Service Fabric name. @param name_description [NameDescription] Describes the Service Fabric name to be created. @param timeout [Integer] The server timeout for performing the operation in seconds. This timeout specifies the time duration that the client is wil...
[ "Creates", "a", "Service", "Fabric", "name", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_service_fabric/lib/6.2.0.9/generated/azure_service_fabric/service_fabric_client_apis.rb#L26144-L26146
train
Creates a name for a given App Service Environment.
[ 30522, 13366, 3443, 1035, 2171, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 2171, 1035, 6412, 1010, 2051, 5833, 1024, 3438, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3443, 1035, 2171, 1035, 2004, 6038, 2278, 1006, 2171, 1035, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Model.add_composite_entity_with_http_info
def add_composite_entity_with_http_info(app_id, version_id, composite_model_create_object, custom_headers:nil) add_composite_entity_async(app_id, version_id, composite_model_create_object, custom_headers:custom_headers).value! end
ruby
def add_composite_entity_with_http_info(app_id, version_id, composite_model_create_object, custom_headers:nil) add_composite_entity_async(app_id, version_id, composite_model_create_object, custom_headers:custom_headers).value! end
[ "def", "add_composite_entity_with_http_info", "(", "app_id", ",", "version_id", ",", "composite_model_create_object", ",", "custom_headers", ":", "nil", ")", "add_composite_entity_async", "(", "app_id", ",", "version_id", ",", "composite_model_create_object", ",", "custom_h...
Adds a composite entity extractor to a version of the application. @param app_id The application ID. @param version_id [String] The version ID. @param composite_model_create_object [CompositeEntityModel] A model containing the name and children of the new entity extractor. @param custom_headers [Hash{String => St...
[ "Adds", "a", "composite", "entity", "extractor", "to", "a", "version", "of", "the", "application", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb#L755-L757
train
Adds a composite entity to the application version.
[ 30522, 13366, 5587, 1035, 12490, 1035, 9178, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 12490, 1035, 2944, 1035, 3443, 1035, 4874, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 5587,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
rails/rails
activemodel/lib/active_model/errors.rb
ActiveModel.Errors.full_message
def full_message(attribute, message) return message if attribute == :base attribute = attribute.to_s if self.class.i18n_customize_full_message && @base.class.respond_to?(:i18n_scope) attribute = attribute.remove(/\[\d\]/) parts = attribute.split(".") attribute_name = parts.pop...
ruby
def full_message(attribute, message) return message if attribute == :base attribute = attribute.to_s if self.class.i18n_customize_full_message && @base.class.respond_to?(:i18n_scope) attribute = attribute.remove(/\[\d\]/) parts = attribute.split(".") attribute_name = parts.pop...
[ "def", "full_message", "(", "attribute", ",", "message", ")", "return", "message", "if", "attribute", "==", ":base", "attribute", "=", "attribute", ".", "to_s", "if", "self", ".", "class", ".", "i18n_customize_full_message", "&&", "@base", ".", "class", ".", ...
Returns a full message for a given attribute. person.errors.full_message(:name, 'is invalid') # => "Name is invalid"
[ "Returns", "a", "full", "message", "for", "a", "given", "attribute", "." ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activemodel/lib/active_model/errors.rb#L470-L512
train
Returns the full message for the given attribute.
[ 30522, 13366, 2440, 1035, 4471, 1006, 17961, 1010, 4471, 1007, 2709, 4471, 2065, 17961, 1027, 1027, 1024, 2918, 17961, 1027, 17961, 1012, 2000, 1035, 30524, 1045, 15136, 2078, 1035, 7661, 4697, 1035, 2440, 1035, 4471, 1004, 1004, 1030, 2918...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
sensu/sensu
lib/sensu/utilities.rb
Sensu.Utilities.eval_attribute_value
def eval_attribute_value(object, raw_eval_string, raw_value) eval_string = process_eval_string(object, raw_eval_string) unless eval_string.nil? begin value = Marshal.load(Marshal.dump(raw_value)) !!Sandbox.eval(eval_string, value) rescue StandardError, SyntaxError => erro...
ruby
def eval_attribute_value(object, raw_eval_string, raw_value) eval_string = process_eval_string(object, raw_eval_string) unless eval_string.nil? begin value = Marshal.load(Marshal.dump(raw_value)) !!Sandbox.eval(eval_string, value) rescue StandardError, SyntaxError => erro...
[ "def", "eval_attribute_value", "(", "object", ",", "raw_eval_string", ",", "raw_value", ")", "eval_string", "=", "process_eval_string", "(", "object", ",", "raw_eval_string", ")", "unless", "eval_string", ".", "nil?", "begin", "value", "=", "Marshal", ".", "load",...
Ruby `eval()` a string containing an expression, within the scope/context of a sandbox. This method is for attribute values starting with "eval:", with the Ruby expression following the colon. A single variable is provided to the expression, `value`, equal to the corresponding object attribute value. Dot notation ...
[ "Ruby", "eval", "()", "a", "string", "containing", "an", "expression", "within", "the", "scope", "/", "context", "of", "a", "sandbox", ".", "This", "method", "is", "for", "attribute", "values", "starting", "with", "eval", ":", "with", "the", "Ruby", "expre...
51319e4b58c8d9986f101ad71ff729aa3e51e951
https://github.com/sensu/sensu/blob/51319e4b58c8d9986f101ad71ff729aa3e51e951/lib/sensu/utilities.rb#L273-L291
train
eval attribute value
[ 30522, 13366, 9345, 2140, 1035, 17961, 1035, 3643, 1006, 4874, 1010, 6315, 1035, 9345, 2140, 1035, 5164, 1010, 6315, 1035, 3643, 1007, 9345, 2140, 1035, 5164, 1027, 2832, 1035, 9345, 2140, 1035, 5164, 1006, 4874, 1010, 6315, 1035, 9345, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
watir/watir
lib/watir/adjacent.rb
Watir.Adjacent.children
def children(opt = {}) raise ArgumentError, '#children can not take an index value' if opt[:index] xpath_adjacent(opt.merge(adjacent: :child, plural: true)) end
ruby
def children(opt = {}) raise ArgumentError, '#children can not take an index value' if opt[:index] xpath_adjacent(opt.merge(adjacent: :child, plural: true)) end
[ "def", "children", "(", "opt", "=", "{", "}", ")", "raise", "ArgumentError", ",", "'#children can not take an index value'", "if", "opt", "[", ":index", "]", "xpath_adjacent", "(", "opt", ".", "merge", "(", "adjacent", ":", ":child", ",", "plural", ":", "tru...
Returns collection of elements of direct children of current element. @example children = browser.select_list(id: "new_user_languages").children children == browser.select_list(id: "new_user_languages").options.to_a #=> true
[ "Returns", "collection", "of", "elements", "of", "direct", "children", "of", "current", "element", "." ]
2d8db09811c6221ae401b85b2f61f5fa66e463a3
https://github.com/watir/watir/blob/2d8db09811c6221ae401b85b2f61f5fa66e463a3/lib/watir/adjacent.rb#L105-L109
train
Returns the children of this node
[ 30522, 13366, 2336, 1006, 23569, 1027, 1063, 1065, 1007, 5333, 6685, 2121, 29165, 1010, 1005, 1001, 2336, 2064, 2025, 2202, 2019, 5950, 3643, 1005, 2065, 23569, 1031, 1024, 5950, 1033, 26726, 8988, 1035, 5516, 1006, 23569, 1012, 13590, 1006...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
fastlane/fastlane
spaceship/lib/spaceship/du/utilities.rb
Spaceship.Utilities.content_type
def content_type(path) path = path.downcase return 'image/jpeg' if path.end_with?('.jpg') return 'image/jpeg' if path.end_with?('.jpeg') return 'image/png' if path.end_with?('.png') return 'application/json' if path.end_with?('.geojson') return 'video/quicktime' if path.end_with?('.m...
ruby
def content_type(path) path = path.downcase return 'image/jpeg' if path.end_with?('.jpg') return 'image/jpeg' if path.end_with?('.jpeg') return 'image/png' if path.end_with?('.png') return 'application/json' if path.end_with?('.geojson') return 'video/quicktime' if path.end_with?('.m...
[ "def", "content_type", "(", "path", ")", "path", "=", "path", ".", "downcase", "return", "'image/jpeg'", "if", "path", ".", "end_with?", "(", "'.jpg'", ")", "return", "'image/jpeg'", "if", "path", ".", "end_with?", "(", "'.jpeg'", ")", "return", "'image/png'...
:nodoc: Identifies the content_type of a file based on its file name extension. Supports all formats required by DU-UTC right now (video, images and json) @param path (String) the path to the file
[ ":", "nodoc", ":", "Identifies", "the", "content_type", "of", "a", "file", "based", "on", "its", "file", "name", "extension", ".", "Supports", "all", "formats", "required", "by", "DU", "-", "UTC", "right", "now", "(", "video", "images", "and", "json", ")...
457c5d647c77f0e078dafa5129da616914e002c5
https://github.com/fastlane/fastlane/blob/457c5d647c77f0e078dafa5129da616914e002c5/spaceship/lib/spaceship/du/utilities.rb#L10-L20
train
Returns the content - type of the file
[ 30522, 13366, 4180, 1035, 2828, 1006, 4130, 1007, 4130, 1027, 4130, 1012, 2091, 18382, 2709, 1005, 3746, 1013, 16545, 13910, 1005, 2065, 4130, 1012, 2203, 1035, 2007, 1029, 1006, 1005, 1012, 16545, 2290, 1005, 1007, 2709, 1005, 3746, 1013, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_storagesync/lib/2018-07-01/generated/azure_mgmt_storagesync/cloud_endpoints.rb
Azure::StorageSync::Mgmt::V2018_07_01.CloudEndpoints.pre_backup_async
def pre_backup_async(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:nil) # Send request promise = begin_pre_backup_async(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:custom_h...
ruby
def pre_backup_async(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:nil) # Send request promise = begin_pre_backup_async(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:custom_h...
[ "def", "pre_backup_async", "(", "resource_group_name", ",", "storage_sync_service_name", ",", "sync_group_name", ",", "cloud_endpoint_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_pre_backup_async", "(", "resour...
@param resource_group_name [String] The name of the resource group. The name is case insensitive. @param storage_sync_service_name [String] Name of Storage Sync Service resource. @param sync_group_name [String] Name of Sync Group resource. @param cloud_endpoint_name [String] Name of Cloud Endpoint object. @param ...
[ "@param", "resource_group_name", "[", "String", "]", "The", "name", "of", "the", "resource", "group", ".", "The", "name", "is", "case", "insensitive", ".", "@param", "storage_sync_service_name", "[", "String", "]", "Name", "of", "Storage", "Sync", "Service", "...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_storagesync/lib/2018-07-01/generated/azure_mgmt_storagesync/cloud_endpoints.rb#L374-L388
train
Pre - backup a CloudEndpoint.
[ 30522, 13366, 3653, 1035, 10200, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 5527, 1035, 26351, 1035, 2326, 30524, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 5527, 1035, 26351, 1035, 2326, 1035, 2171, 1010, 26351, 1035,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_network/lib/2018-07-01/generated/azure_mgmt_network/public_ipprefixes.rb
Azure::Network::Mgmt::V2018_07_01.PublicIPPrefixes.begin_create_or_update_with_http_info
def begin_create_or_update_with_http_info(resource_group_name, public_ip_prefix_name, parameters, custom_headers:nil) begin_create_or_update_async(resource_group_name, public_ip_prefix_name, parameters, custom_headers:custom_headers).value! end
ruby
def begin_create_or_update_with_http_info(resource_group_name, public_ip_prefix_name, parameters, custom_headers:nil) begin_create_or_update_async(resource_group_name, public_ip_prefix_name, parameters, custom_headers:custom_headers).value! end
[ "def", "begin_create_or_update_with_http_info", "(", "resource_group_name", ",", "public_ip_prefix_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "begin_create_or_update_async", "(", "resource_group_name", ",", "public_ip_prefix_name", ",", "parameters", ",...
Creates or updates a static or dynamic public IP prefix. @param resource_group_name [String] The name of the resource group. @param public_ip_prefix_name [String] The name of the public IP prefix. @param parameters [PublicIPPrefix] Parameters supplied to the create or update public IP prefix operation. @param cus...
[ "Creates", "or", "updates", "a", "static", "or", "dynamic", "public", "IP", "prefix", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-07-01/generated/azure_mgmt_network/public_ipprefixes.rb#L531-L533
train
Creates or updates an existing public IP prefix.
[ 30522, 13366, 4088, 1035, 3443, 1035, 2030, 1035, 10651, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2270, 1035, 12997, 1035, 17576, 1035, 2171, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-ruby
gems/aws-sdk-autoscaling/lib/aws-sdk-autoscaling/auto_scaling_group.rb
Aws::AutoScaling.AutoScalingGroup.update
def update(options = {}) options = options.merge(auto_scaling_group_name: @name) resp = @client.update_auto_scaling_group(options) AutoScalingGroup.new( name: options[:auto_scaling_group_name], client: @client ) end
ruby
def update(options = {}) options = options.merge(auto_scaling_group_name: @name) resp = @client.update_auto_scaling_group(options) AutoScalingGroup.new( name: options[:auto_scaling_group_name], client: @client ) end
[ "def", "update", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "auto_scaling_group_name", ":", "@name", ")", "resp", "=", "@client", ".", "update_auto_scaling_group", "(", "options", ")", "AutoScalingGroup", ".", "new", "(...
@example Request syntax with placeholder values autoscalinggroup = auto_scaling_group.update({ launch_configuration_name: "ResourceName", launch_template: { launch_template_id: "XmlStringMaxLen255", launch_template_name: "LaunchTemplateName", version: "XmlStringMaxLen255", }, ...
[ "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-autoscaling/lib/aws-sdk-autoscaling/auto_scaling_group.rb#L923-L930
train
Update the Auto Scaling Group
[ 30522, 13366, 10651, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 8285, 1035, 25169, 1035, 2177, 1035, 2171, 1024, 1030, 2171, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 10651, 1035, 8285, 1035, 25169, 1035, 2177...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_event_grid/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/topics.rb
Azure::EventGrid::Mgmt::V2019_02_01_preview.Topics.list_by_subscription_as_lazy
def list_by_subscription_as_lazy(filter:nil, top:nil, custom_headers:nil) response = list_by_subscription_async(filter:filter, top:top, custom_headers:custom_headers).value! unless response.nil? page = response.body page.next_method = Proc.new do |next_page_link| list_by_subscripti...
ruby
def list_by_subscription_as_lazy(filter:nil, top:nil, custom_headers:nil) response = list_by_subscription_async(filter:filter, top:top, custom_headers:custom_headers).value! unless response.nil? page = response.body page.next_method = Proc.new do |next_page_link| list_by_subscripti...
[ "def", "list_by_subscription_as_lazy", "(", "filter", ":", "nil", ",", "top", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_by_subscription_async", "(", "filter", ":", "filter", ",", "top", ":", "top", ",", "custom_headers", ":cust...
List topics under an Azure subscription List all the topics under an Azure subscription @param filter [String] Filter the results using OData syntax. @param top [Integer] The number of results to return. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP reques...
[ "List", "topics", "under", "an", "Azure", "subscription" ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_event_grid/lib/2019-02-01-preview/generated/azure_mgmt_event_grid/topics.rb#L1307-L1316
train
Gets a list of all the available CDN terms.
[ 30522, 13366, 2862, 1035, 2011, 1035, 15002, 1035, 2004, 1035, 13971, 1006, 11307, 1024, 9152, 2140, 1010, 2327, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 2011, 1035, 15002, 1035, 2004,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_service_fabric/lib/6.2.0.9/generated/azure_service_fabric/service_fabric_client_apis.rb
Azure::ServiceFabric::V6_2_0_9.ServiceFabricClientAPIs.get_deployed_code_package_info_list_with_http_info
def get_deployed_code_package_info_list_with_http_info(node_name, application_id, service_manifest_name:nil, code_package_name:nil, timeout:60, custom_headers:nil) get_deployed_code_package_info_list_async(node_name, application_id, service_manifest_name:service_manifest_name, code_package_name:code_package_name,...
ruby
def get_deployed_code_package_info_list_with_http_info(node_name, application_id, service_manifest_name:nil, code_package_name:nil, timeout:60, custom_headers:nil) get_deployed_code_package_info_list_async(node_name, application_id, service_manifest_name:service_manifest_name, code_package_name:code_package_name,...
[ "def", "get_deployed_code_package_info_list_with_http_info", "(", "node_name", ",", "application_id", ",", "service_manifest_name", ":", "nil", ",", "code_package_name", ":", "nil", ",", "timeout", ":", "60", ",", "custom_headers", ":", "nil", ")", "get_deployed_code_pa...
Gets the list of code packages deployed on a Service Fabric node. Gets the list of code packages deployed on a Service Fabric node for the given application. @param node_name [String] The name of the node. @param application_id [String] The identity of the application. This is typically the full name of the appl...
[ "Gets", "the", "list", "of", "code", "packages", "deployed", "on", "a", "Service", "Fabric", "node", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_service_fabric/lib/6.2.0.9/generated/azure_service_fabric/service_fabric_client_apis.rb#L17124-L17126
train
Gets the list of code package deployments for a node.
[ 30522, 13366, 2131, 1035, 7333, 1035, 3642, 1035, 7427, 1035, 18558, 1035, 2862, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 13045, 1035, 2171, 1010, 4646, 1035, 8909, 1010, 2326, 1035, 19676, 1035, 2171, 1024, 9152, 2140, 1010, 3642, 30524,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
mikker/passwordless
app/mailers/passwordless/mailer.rb
Passwordless.Mailer.magic_link
def magic_link(session) @session = session @magic_link = send(Passwordless.mounted_as) .token_sign_in_url(session.token) email_field = @session.authenticatable.class.passwordless_email_field mail( to: @session.authenticatable.send(email_field), subject: I18n.t("password...
ruby
def magic_link(session) @session = session @magic_link = send(Passwordless.mounted_as) .token_sign_in_url(session.token) email_field = @session.authenticatable.class.passwordless_email_field mail( to: @session.authenticatable.send(email_field), subject: I18n.t("password...
[ "def", "magic_link", "(", "session", ")", "@session", "=", "session", "@magic_link", "=", "send", "(", "Passwordless", ".", "mounted_as", ")", ".", "token_sign_in_url", "(", "session", ".", "token", ")", "email_field", "=", "@session", ".", "authenticatable", ...
Sends a magic link (secret token) email. @param session [Session] A Passwordless Session
[ "Sends", "a", "magic", "link", "(", "secret", "token", ")", "email", "." ]
80d3e00c78114aed01f336514a236dfc17d0a91a
https://github.com/mikker/passwordless/blob/80d3e00c78114aed01f336514a236dfc17d0a91a/app/mailers/passwordless/mailer.rb#L10-L21
train
send magic link to the session
[ 30522, 13366, 3894, 1035, 4957, 1006, 5219, 1007, 1030, 5219, 1027, 5219, 1030, 3894, 1035, 4957, 1027, 4604, 1006, 20786, 3238, 1012, 5614, 1035, 2004, 1007, 1012, 19204, 1035, 3696, 1035, 1999, 1035, 24471, 2140, 1006, 5219, 1012, 19204, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-ruby
gems/aws-sdk-iam/lib/aws-sdk-iam/role_policy.rb
Aws::IAM.RolePolicy.delete
def delete(options = {}) options = options.merge( role_name: @role_name, policy_name: @name ) resp = @client.delete_role_policy(options) resp.data end
ruby
def delete(options = {}) options = options.merge( role_name: @role_name, policy_name: @name ) resp = @client.delete_role_policy(options) resp.data end
[ "def", "delete", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "role_name", ":", "@role_name", ",", "policy_name", ":", "@name", ")", "resp", "=", "@client", ".", "delete_role_policy", "(", "options", ")", "resp", ".",...
@!group Actions @example Request syntax with placeholder values role_policy.delete() @param [Hash] options ({}) @return [EmptyStructure]
[ "@!group", "Actions", "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-iam/lib/aws-sdk-iam/role_policy.rb#L188-L195
train
Delete a policy from the role
[ 30522, 13366, 3972, 12870, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 2535, 1035, 2171, 1024, 1030, 2535, 1035, 2171, 1010, 3343, 1035, 2171, 1024, 1030, 2171, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 3972, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_contentmoderator/lib/1.0/generated/azure_cognitiveservices_contentmoderator/reviews.rb
Azure::CognitiveServices::ContentModerator::V1_0.Reviews.create_reviews
def create_reviews(url_content_type, team_name, create_review_body, sub_team:nil, custom_headers:nil) response = create_reviews_async(url_content_type, team_name, create_review_body, sub_team:sub_team, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def create_reviews(url_content_type, team_name, create_review_body, sub_team:nil, custom_headers:nil) response = create_reviews_async(url_content_type, team_name, create_review_body, sub_team:sub_team, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "create_reviews", "(", "url_content_type", ",", "team_name", ",", "create_review_body", ",", "sub_team", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_reviews_async", "(", "url_content_type", ",", "team_name", ",", "create_revie...
The reviews created would show up for Reviewers on your team. As Reviewers complete reviewing, results of the Review would be POSTED (i.e. HTTP POST) on the specified CallBackEndpoint. <h3>CallBack Schemas </h3> <h4>Review Completion CallBack Sample</h4> <p> {<br/> "ReviewId": "<Review Id>",<br/> "ModifiedOn":...
[ "The", "reviews", "created", "would", "show", "up", "for", "Reviewers", "on", "your", "team", ".", "As", "Reviewers", "complete", "reviewing", "results", "of", "the", "Review", "would", "be", "POSTED", "(", "i", ".", "e", ".", "HTTP", "POST", ")", "on", ...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_contentmoderator/lib/1.0/generated/azure_cognitiveservices_contentmoderator/reviews.rb#L255-L258
train
Creates a review for a given URL content type.
[ 30522, 13366, 3443, 1035, 4391, 1006, 24471, 2140, 1035, 4180, 1035, 2828, 1010, 2136, 1035, 2171, 1010, 3443, 1035, 3319, 1035, 2303, 1010, 4942, 1035, 2136, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 30524, 1007, 3433, 1027, 3443, 1035, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
rails/rails
activerecord/lib/active_record/relation.rb
ActiveRecord.Relation.create
def create(attributes = nil, &block) if attributes.is_a?(Array) attributes.collect { |attr| create(attr, &block) } else block = _deprecated_scope_block("create", &block) scoping { klass.create(attributes, &block) } end end
ruby
def create(attributes = nil, &block) if attributes.is_a?(Array) attributes.collect { |attr| create(attr, &block) } else block = _deprecated_scope_block("create", &block) scoping { klass.create(attributes, &block) } end end
[ "def", "create", "(", "attributes", "=", "nil", ",", "&", "block", ")", "if", "attributes", ".", "is_a?", "(", "Array", ")", "attributes", ".", "collect", "{", "|", "attr", "|", "create", "(", "attr", ",", "block", ")", "}", "else", "block", "=", "...
Tries to create a new record with the same scoped attributes defined in the relation. Returns the initialized object if validation fails. Expects arguments in the same format as {ActiveRecord::Base.create}[rdoc-ref:Persistence::ClassMethods#create]. ==== Examples users = User.where(name: 'Oscar') users.cre...
[ "Tries", "to", "create", "a", "new", "record", "with", "the", "same", "scoped", "attributes", "defined", "in", "the", "relation", ".", "Returns", "the", "initialized", "object", "if", "validation", "fails", "." ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activerecord/lib/active_record/relation.rb#L95-L102
train
Creates a new object in the current namespace.
[ 30522, 13366, 3443, 1006, 12332, 1027, 9152, 2140, 1010, 1004, 3796, 1007, 2065, 12332, 1012, 2003, 1035, 1037, 1029, 1006, 9140, 1007, 12332, 1012, 8145, 1063, 1064, 2012, 16344, 1064, 3443, 1006, 2012, 16344, 1010, 1004, 3796, 1007, 1065,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
randym/axlsx
lib/axlsx/drawing/two_cell_anchor.rb
Axlsx.TwoCellAnchor.to_xml_string
def to_xml_string(str = '') str << '<xdr:twoCellAnchor>' str << '<xdr:from>' from.to_xml_string str str << '</xdr:from>' str << '<xdr:to>' to.to_xml_string str str << '</xdr:to>' object.to_xml_string(str) str << '<xdr:clientData/>' str << '</xdr:twoCellAnchor>...
ruby
def to_xml_string(str = '') str << '<xdr:twoCellAnchor>' str << '<xdr:from>' from.to_xml_string str str << '</xdr:from>' str << '<xdr:to>' to.to_xml_string str str << '</xdr:to>' object.to_xml_string(str) str << '<xdr:clientData/>' str << '</xdr:twoCellAnchor>...
[ "def", "to_xml_string", "(", "str", "=", "''", ")", "str", "<<", "'<xdr:twoCellAnchor>'", "str", "<<", "'<xdr:from>'", "from", ".", "to_xml_string", "str", "str", "<<", "'</xdr:from>'", "str", "<<", "'<xdr:to>'", "to", ".", "to_xml_string", "str", "str", "<<",...
Serializes the object @param [String] str @return [String]
[ "Serializes", "the", "object" ]
c593a08b2a929dac7aa8dc418b55e26b4c49dc34
https://github.com/randym/axlsx/blob/c593a08b2a929dac7aa8dc418b55e26b4c49dc34/lib/axlsx/drawing/two_cell_anchor.rb#L84-L95
train
Return the object as an XML string.
[ 30522, 13366, 2000, 1035, 20950, 1035, 5164, 1006, 2358, 2099, 1027, 1005, 1005, 1007, 2358, 2099, 1026, 1026, 1005, 1026, 1060, 13626, 1024, 2048, 29109, 5802, 9905, 2099, 1028, 1005, 2358, 2099, 1026, 1026, 1005, 1026, 1060, 13626, 1024, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_sql/lib/2015-05-01-preview/generated/azure_mgmt_sql/sync_groups.rb
Azure::SQL::Mgmt::V2015_05_01_preview.SyncGroups.begin_refresh_hub_schema_with_http_info
def begin_refresh_hub_schema_with_http_info(resource_group_name, server_name, database_name, sync_group_name, custom_headers:nil) begin_refresh_hub_schema_async(resource_group_name, server_name, database_name, sync_group_name, custom_headers:custom_headers).value! end
ruby
def begin_refresh_hub_schema_with_http_info(resource_group_name, server_name, database_name, sync_group_name, custom_headers:nil) begin_refresh_hub_schema_async(resource_group_name, server_name, database_name, sync_group_name, custom_headers:custom_headers).value! end
[ "def", "begin_refresh_hub_schema_with_http_info", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",", "sync_group_name", ",", "custom_headers", ":", "nil", ")", "begin_refresh_hub_schema_async", "(", "resource_group_name", ",", "server_name", ",", "da...
Refreshes a hub database schema. @param resource_group_name [String] The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. @param server_name [String] The name of the server. @param database_name [String] The name of the database on...
[ "Refreshes", "a", "hub", "database", "schema", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_sql/lib/2015-05-01-preview/generated/azure_mgmt_sql/sync_groups.rb#L1002-L1004
train
Refresh hub schema.
[ 30522, 13366, 4088, 1035, 25416, 21898, 1035, 9594, 1035, 8040, 28433, 1035, 2007, 30524, 8241, 1035, 2171, 1010, 7809, 1035, 2171, 1010, 26351, 1035, 2177, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 4088, 1035, 2541...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-ruby
gems/aws-sdk-rds/lib/aws-sdk-rds/resource.rb
Aws::RDS.Resource.event_subscriptions
def event_subscriptions(options = {}) batches = Enumerator.new do |y| resp = @client.describe_event_subscriptions(options) resp.each_page do |page| batch = [] page.data.event_subscriptions_list.each do |e| batch << EventSubscription.new( name: e.cust_s...
ruby
def event_subscriptions(options = {}) batches = Enumerator.new do |y| resp = @client.describe_event_subscriptions(options) resp.each_page do |page| batch = [] page.data.event_subscriptions_list.each do |e| batch << EventSubscription.new( name: e.cust_s...
[ "def", "event_subscriptions", "(", "options", "=", "{", "}", ")", "batches", "=", "Enumerator", ".", "new", "do", "|", "y", "|", "resp", "=", "@client", ".", "describe_event_subscriptions", "(", "options", ")", "resp", ".", "each_page", "do", "|", "page", ...
@example Request syntax with placeholder values event_subscriptions = rds.event_subscriptions({ subscription_name: "String", filters: [ { name: "String", # required values: ["String"], # required }, ], }) @param [Hash] options ({}) @option options [String] :subscr...
[ "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-rds/lib/aws-sdk-rds/resource.rb#L2222-L2238
train
Returns an array of EventSubscription objects
[ 30522, 13366, 2724, 1035, 15002, 2015, 1006, 7047, 1027, 1063, 1065, 1007, 14108, 2229, 1027, 4372, 17897, 16259, 1012, 2047, 2079, 1064, 1061, 1064, 24501, 2361, 1027, 1030, 7396, 1012, 6235, 1035, 2724, 1035, 15002, 2015, 1006, 7047, 1007...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_web/lib/2018-02-01/generated/azure_mgmt_web/diagnostics.rb
Azure::Web::Mgmt::V2018_02_01.Diagnostics.get_site_detector_response_slot_with_http_info
def get_site_detector_response_slot_with_http_info(resource_group_name, site_name, detector_name, slot, start_time:nil, end_time:nil, time_grain:nil, custom_headers:nil) get_site_detector_response_slot_async(resource_group_name, site_name, detector_name, slot, start_time:start_time, end_time:end_time, time_grain:...
ruby
def get_site_detector_response_slot_with_http_info(resource_group_name, site_name, detector_name, slot, start_time:nil, end_time:nil, time_grain:nil, custom_headers:nil) get_site_detector_response_slot_async(resource_group_name, site_name, detector_name, slot, start_time:start_time, end_time:end_time, time_grain:...
[ "def", "get_site_detector_response_slot_with_http_info", "(", "resource_group_name", ",", "site_name", ",", "detector_name", ",", "slot", ",", "start_time", ":", "nil", ",", "end_time", ":", "nil", ",", "time_grain", ":", "nil", ",", "custom_headers", ":", "nil", ...
Get site detector response Get site detector response @param resource_group_name [String] Name of the resource group to which the resource belongs. @param site_name [String] Site Name @param detector_name [String] Detector Resource Name @param slot [String] Slot Name @param start_time [DateTime] Start Time @p...
[ "Get", "site", "detector", "response" ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_web/lib/2018-02-01/generated/azure_mgmt_web/diagnostics.rb#L1513-L1515
train
Gets the response of a site detector.
[ 30522, 13366, 2131, 1035, 2609, 1035, 19034, 1035, 3433, 1035, 10453, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2609, 1035, 2171, 1010, 19034, 1035, 2171, 1010, 10453, 1010, 2707, 1035, 2051, 1024, 9152,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
rocketjob/symmetric-encryption
lib/symmetric_encryption/cipher.rb
SymmetricEncryption.Cipher.binary_decrypt
def binary_decrypt(encrypted_string, header: Header.new) return if encrypted_string.nil? str = encrypted_string.to_s str.force_encoding(SymmetricEncryption::BINARY_ENCODING) return str if str.empty? offset = header.parse(str) data = offset.positive? ? str[offset..-1] : str ...
ruby
def binary_decrypt(encrypted_string, header: Header.new) return if encrypted_string.nil? str = encrypted_string.to_s str.force_encoding(SymmetricEncryption::BINARY_ENCODING) return str if str.empty? offset = header.parse(str) data = offset.positive? ? str[offset..-1] : str ...
[ "def", "binary_decrypt", "(", "encrypted_string", ",", "header", ":", "Header", ".", "new", ")", "return", "if", "encrypted_string", ".", "nil?", "str", "=", "encrypted_string", ".", "to_s", "str", ".", "force_encoding", "(", "SymmetricEncryption", "::", "BINARY...
Advanced use only See #decrypt to decrypt encoded strings Returns a Binary decrypted string without decoding the string first The returned string has BINARY encoding Decryption of supplied string Returns the decrypted string Returns nil if encrypted_string is nil Returns '' if encrypted_string == '' Pa...
[ "Advanced", "use", "only", "See", "#decrypt", "to", "decrypt", "encoded", "strings" ]
064ba8d57ffac44a3ed80f5e76fa1a54d660ff98
https://github.com/rocketjob/symmetric-encryption/blob/064ba8d57ffac44a3ed80f5e76fa1a54d660ff98/lib/symmetric_encryption/cipher.rb#L307-L326
train
Decrypts the string using the given header.
[ 30522, 13366, 12441, 1035, 11703, 2854, 13876, 1006, 4372, 26775, 22571, 3064, 1035, 5164, 1010, 20346, 1024, 20346, 1012, 2047, 1007, 2709, 2065, 4372, 26775, 22571, 3064, 1035, 5164, 1012, 9152, 2140, 1029, 2358, 2099, 1027, 4372, 26775, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ruby/racc
lib/racc/state.rb
Racc.States.detailed_transition_graph
def detailed_transition_graph @dtgraph ||= each_with_object(Graph::Labeled.new(size)) do |s, graph| s.gotos.each do |tok, goto| path = if tok.terminal? [tok] else actions_to_reach_reduce(s.ident, tok) end graph.add_vector(s.ident, goto.to_sta...
ruby
def detailed_transition_graph @dtgraph ||= each_with_object(Graph::Labeled.new(size)) do |s, graph| s.gotos.each do |tok, goto| path = if tok.terminal? [tok] else actions_to_reach_reduce(s.ident, tok) end graph.add_vector(s.ident, goto.to_sta...
[ "def", "detailed_transition_graph", "@dtgraph", "||=", "each_with_object", "(", "Graph", "::", "Labeled", ".", "new", "(", "size", ")", ")", "do", "|", "s", ",", "graph", "|", "s", ".", "gotos", ".", "each", "do", "|", "tok", ",", "goto", "|", "path", ...
Like `transition_graph`, but rather than vectors labeled with NTs, we have vectors labeled with the shortest series of terminals and reduce operations which could take us through the same transition
[ "Like", "transition_graph", "but", "rather", "than", "vectors", "labeled", "with", "NTs", "we", "have", "vectors", "labeled", "with", "the", "shortest", "series", "of", "terminals", "and", "reduce", "operations", "which", "could", "take", "us", "through", "the",...
d3244edfa11dd6e86e43f570c6444d41c7e3552a
https://github.com/ruby/racc/blob/d3244edfa11dd6e86e43f570c6444d41c7e3552a/lib/racc/state.rb#L430-L441
train
Returns a graph of detailed transition graph
[ 30522, 13366, 6851, 1035, 6653, 1035, 10629, 1030, 26718, 14413, 1064, 1064, 1027, 2169, 1035, 2007, 1035, 4874, 1006, 10629, 1024, 1024, 12599, 1012, 2047, 1006, 2946, 1007, 1007, 2079, 1064, 1055, 1010, 10629, 1064, 1055, 1012, 2288, 2891...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-ruby
gems/aws-sdk-ec2/lib/aws-sdk-ec2/resource.rb
Aws::EC2.Resource.create_placement_group
def create_placement_group(options = {}) resp = @client.create_placement_group(options) PlacementGroup.new( name: options[:group_name], client: @client ) end
ruby
def create_placement_group(options = {}) resp = @client.create_placement_group(options) PlacementGroup.new( name: options[:group_name], client: @client ) end
[ "def", "create_placement_group", "(", "options", "=", "{", "}", ")", "resp", "=", "@client", ".", "create_placement_group", "(", "options", ")", "PlacementGroup", ".", "new", "(", "name", ":", "options", "[", ":group_name", "]", ",", "client", ":", "@client"...
@example Request syntax with placeholder values placementgroup = ec2.create_placement_group({ dry_run: false, group_name: "String", strategy: "cluster", # accepts cluster, spread, partition partition_count: 1, }) @param [Hash] options ({}) @option options [Boolean] :dry_run Checks whethe...
[ "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-ec2/lib/aws-sdk-ec2/resource.rb#L648-L654
train
Creates a placement group
[ 30522, 13366, 3443, 1035, 11073, 1035, 2177, 1006, 7047, 1027, 1063, 1065, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 3443, 1035, 11073, 1035, 2177, 1006, 7047, 1007, 11073, 17058, 1012, 2047, 1006, 2171, 1024, 7047, 1031, 1024, 2177, 30524...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
geokit/geokit
lib/geokit/lat_lng.rb
Geokit.LatLng.reverse_geocode
def reverse_geocode(options = {using: Geokit::Geocoders::MultiGeocoder}) if options[:using].is_a?(String) || options[:using].is_a?(Symbol) class_name = "#{Geokit::Inflector.camelize(options[:using].to_s)}Geocoder" provider = Geokit::Geocoders.const_get(class_name) elsif options[:us...
ruby
def reverse_geocode(options = {using: Geokit::Geocoders::MultiGeocoder}) if options[:using].is_a?(String) || options[:using].is_a?(Symbol) class_name = "#{Geokit::Inflector.camelize(options[:using].to_s)}Geocoder" provider = Geokit::Geocoders.const_get(class_name) elsif options[:us...
[ "def", "reverse_geocode", "(", "options", "=", "{", "using", ":", "Geokit", "::", "Geocoders", "::", "MultiGeocoder", "}", ")", "if", "options", "[", ":using", "]", ".", "is_a?", "(", "String", ")", "||", "options", "[", ":using", "]", ".", "is_a?", "(...
Reverse geocodes a LatLng object using the MultiGeocoder (default), or optionally using a geocoder of your choosing. Returns a new Geokit::GeoLoc object ==== Options * :using - Specifies the geocoder to use for reverse geocoding. Defaults to MultiGeocoder. Can be either the geocoder class (or any ...
[ "Reverse", "geocodes", "a", "LatLng", "object", "using", "the", "MultiGeocoder", "(", "default", ")", "or", "optionally", "using", "a", "geocoder", "of", "your", "choosing", ".", "Returns", "a", "new", "Geokit", "::", "GeoLoc", "object" ]
b7c13376bd85bf14f9534228ea466d09ac0afbf4
https://github.com/geokit/geokit/blob/b7c13376bd85bf14f9534228ea466d09ac0afbf4/lib/geokit/lat_lng.rb#L151-L163
train
Reverse geocoding
[ 30522, 13366, 7901, 1035, 20248, 16044, 1006, 7047, 1027, 1063, 2478, 1024, 20248, 23615, 1024, 1024, 20248, 16044, 2869, 1024, 1024, 4800, 3351, 24163, 4063, 1065, 1007, 2065, 7047, 1031, 1024, 2478, 1033, 1012, 2003, 1035, 1037, 1029, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
piotrmurach/github
lib/github_api/client/activity/feeds.rb
Github.Client::Activity::Feeds.get
def get(*args) arguments(args, required: [:name]) name = arguments.name response = list.body._links[name] if response params = arguments.params params['accept'] = response.type get_request(response.href, params) end end
ruby
def get(*args) arguments(args, required: [:name]) name = arguments.name response = list.body._links[name] if response params = arguments.params params['accept'] = response.type get_request(response.href, params) end end
[ "def", "get", "(", "*", "args", ")", "arguments", "(", "args", ",", "required", ":", "[", ":name", "]", ")", "name", "=", "arguments", ".", "name", "response", "=", "list", ".", "body", ".", "_links", "[", "name", "]", "if", "response", "params", "...
Get all the items for a named timeline @see https://developer.github.com/v3/activity/feeds/#list-feeds @example github = Github.new github.activity.feeds.get "timeline" @param [String] name the name of the timeline resource @api public
[ "Get", "all", "the", "items", "for", "a", "named", "timeline" ]
8702452c66bea33c9388550aed9e9974f76aaef1
https://github.com/piotrmurach/github/blob/8702452c66bea33c9388550aed9e9974f76aaef1/lib/github_api/client/activity/feeds.rb#L37-L47
train
Get a single resource by name
[ 30522, 13366, 2131, 1006, 1008, 12098, 5620, 1007, 9918, 1006, 12098, 5620, 1010, 3223, 1024, 1031, 1024, 2171, 1033, 1007, 2171, 1027, 9918, 1012, 2171, 3433, 1027, 2862, 1012, 2303, 1012, 1035, 6971, 1031, 2171, 1033, 2065, 3433, 11498, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
backup/backup
lib/backup/model.rb
Backup.Model.sync_with
def sync_with(name, syncer_id = nil, &block) @syncers << get_class_from_scope(Syncer, name).new(syncer_id, &block) end
ruby
def sync_with(name, syncer_id = nil, &block) @syncers << get_class_from_scope(Syncer, name).new(syncer_id, &block) end
[ "def", "sync_with", "(", "name", ",", "syncer_id", "=", "nil", ",", "&", "block", ")", "@syncers", "<<", "get_class_from_scope", "(", "Syncer", ",", "name", ")", ".", "new", "(", "syncer_id", ",", "block", ")", "end" ]
Adds an Syncer. Multiple Syncers may be added to the model.
[ "Adds", "an", "Syncer", ".", "Multiple", "Syncers", "may", "be", "added", "to", "the", "model", "." ]
64370f925e859f858766b674717a3dbee0de7a26
https://github.com/backup/backup/blob/64370f925e859f858766b674717a3dbee0de7a26/lib/backup/model.rb#L156-L158
train
Add a syncer to the list of syncers.
[ 30522, 13366, 26351, 1035, 2007, 1006, 2171, 1010, 26351, 2121, 1035, 8909, 1027, 9152, 2140, 1010, 1004, 3796, 1007, 1030, 26351, 2545, 1026, 1026, 2131, 1035, 2465, 1035, 2013, 1035, 9531, 1006, 26351, 2121, 1010, 2171, 1007, 1012, 2047, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
resque/resque
lib/resque/worker.rb
Resque.Worker.queues
def queues if @has_dynamic_queues current_queues = Resque.queues @queues.map { |queue| glob_match(current_queues, queue) }.flatten.uniq else @queues end end
ruby
def queues if @has_dynamic_queues current_queues = Resque.queues @queues.map { |queue| glob_match(current_queues, queue) }.flatten.uniq else @queues end end
[ "def", "queues", "if", "@has_dynamic_queues", "current_queues", "=", "Resque", ".", "queues", "@queues", ".", "map", "{", "|", "queue", "|", "glob_match", "(", "current_queues", ",", "queue", ")", "}", ".", "flatten", ".", "uniq", "else", "@queues", "end", ...
Returns a list of queues to use when searching for a job. A splat ("*") means you want every queue (in alpha order) - this can be useful for dynamically adding new queues.
[ "Returns", "a", "list", "of", "queues", "to", "use", "when", "searching", "for", "a", "job", ".", "A", "splat", "(", "*", ")", "means", "you", "want", "every", "queue", "(", "in", "alpha", "order", ")", "-", "this", "can", "be", "useful", "for", "d...
adb633a0f6b98b1eb5a5a85bb36ebac9309978fd
https://github.com/resque/resque/blob/adb633a0f6b98b1eb5a5a85bb36ebac9309978fd/lib/resque/worker.rb#L200-L207
train
Returns the unique queues for this resource
[ 30522, 13366, 24240, 2015, 2065, 1030, 2038, 30524, 2015, 1030, 24240, 2015, 1012, 4949, 1063, 1064, 24240, 1064, 1043, 4135, 2497, 1035, 2674, 1006, 2783, 1035, 24240, 2015, 1010, 24240, 1007, 1065, 1012, 4257, 6528, 1012, 4895, 18515, 284...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
pythonicrubyist/creek
lib/creek/sheet.rb
Creek.Creek::Sheet.fill_in_empty_cells
def fill_in_empty_cells(cells, row_number, last_col, use_simple_rows_format) new_cells = Hash.new unless cells.empty? last_col = last_col.gsub(row_number, '') ("A"..last_col).to_a.each do |column| id = use_simple_rows_format ? "#{column}" : "#{column}#{row_number}" new_...
ruby
def fill_in_empty_cells(cells, row_number, last_col, use_simple_rows_format) new_cells = Hash.new unless cells.empty? last_col = last_col.gsub(row_number, '') ("A"..last_col).to_a.each do |column| id = use_simple_rows_format ? "#{column}" : "#{column}#{row_number}" new_...
[ "def", "fill_in_empty_cells", "(", "cells", ",", "row_number", ",", "last_col", ",", "use_simple_rows_format", ")", "new_cells", "=", "Hash", ".", "new", "unless", "cells", ".", "empty?", "last_col", "=", "last_col", ".", "gsub", "(", "row_number", ",", "''", ...
The unzipped XML file does not contain any node for empty cells. Empty cells are being padded in using this function
[ "The", "unzipped", "XML", "file", "does", "not", "contain", "any", "node", "for", "empty", "cells", ".", "Empty", "cells", "are", "being", "padded", "in", "using", "this", "function" ]
1a5c99032ee736e8f24ebd524adffba068d236b4
https://github.com/pythonicrubyist/creek/blob/1a5c99032ee736e8f24ebd524adffba068d236b4/lib/creek/sheet.rb#L144-L157
train
Fill in empty cells with empty cells
[ 30522, 13366, 6039, 1035, 1999, 1035, 4064, 1035, 4442, 1006, 4442, 1010, 5216, 1035, 2193, 1010, 2197, 1035, 8902, 1010, 2224, 1035, 3722, 1035, 10281, 1035, 4289, 1007, 2047, 1035, 4442, 1027, 23325, 1012, 2047, 4983, 4442, 1012, 4064, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
rails/sprockets
lib/sprockets/transformers.rb
Sprockets.Transformers.register_transformer
def register_transformer(from, to, proc) self.config = hash_reassoc(config, :registered_transformers) do |transformers| transformers << Transformer.new(from, to, proc) end compute_transformers!(self.config[:registered_transformers]) end
ruby
def register_transformer(from, to, proc) self.config = hash_reassoc(config, :registered_transformers) do |transformers| transformers << Transformer.new(from, to, proc) end compute_transformers!(self.config[:registered_transformers]) end
[ "def", "register_transformer", "(", "from", ",", "to", ",", "proc", ")", "self", ".", "config", "=", "hash_reassoc", "(", "config", ",", ":registered_transformers", ")", "do", "|", "transformers", "|", "transformers", "<<", "Transformer", ".", "new", "(", "f...
Public: Register a transformer from and to a mime type. from - String mime type to - String mime type proc - Callable block that accepts an input Hash. Examples register_transformer 'text/coffeescript', 'application/javascript', ConvertCoffeeScriptToJavaScript register_transformer 'image/svg+xml', ...
[ "Public", ":", "Register", "a", "transformer", "from", "and", "to", "a", "mime", "type", "." ]
9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd
https://github.com/rails/sprockets/blob/9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd/lib/sprockets/transformers.rb#L38-L43
train
Register a transformer to be used by the application.
[ 30522, 13366, 4236, 1035, 10938, 2121, 1006, 2013, 1010, 2000, 1010, 4013, 2278, 1007, 2969, 1012, 9530, 8873, 2290, 1027, 23325, 1035, 2128, 12054, 10085, 1006, 9530, 8873, 2290, 1010, 1024, 5068, 1035, 19081, 1007, 2079, 1064, 19081, 1064...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
arches/table_print
lib/table_print/row_group.rb
TablePrint.RowGroup.format
def format rows = @children rows = @children[1..-1] if @skip_first_row rows ||= [] rows = rows.collect { |row| row.format }.join("\n") return nil if rows.length == 0 rows end
ruby
def format rows = @children rows = @children[1..-1] if @skip_first_row rows ||= [] rows = rows.collect { |row| row.format }.join("\n") return nil if rows.length == 0 rows end
[ "def", "format", "rows", "=", "@children", "rows", "=", "@children", "[", "1", "..", "-", "1", "]", "if", "@skip_first_row", "rows", "||=", "[", "]", "rows", "=", "rows", ".", "collect", "{", "|", "row", "|", "row", ".", "format", "}", ".", "join",...
TODO: rename this to_s
[ "TODO", ":", "rename", "this", "to_s" ]
a2e80332a74b30b4c23420d8968ccd09a062040d
https://github.com/arches/table_print/blob/a2e80332a74b30b4c23420d8968ccd09a062040d/lib/table_print/row_group.rb#L116-L124
train
Returns the formatted result of this node.
[ 30522, 13366, 4289, 10281, 1027, 1030, 2336, 10281, 1027, 1030, 2336, 1031, 1015, 1012, 1012, 1011, 1015, 1033, 2065, 1030, 13558, 1035, 2034, 1035, 5216, 10281, 1064, 1064, 1027, 1031, 1033, 10281, 1027, 10281, 1012, 8145, 1063, 1064, 5216...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_network/lib/2015-05-01-preview/generated/azure_mgmt_network/network_interfaces.rb
Azure::Network::Mgmt::V2015_05_01_preview.NetworkInterfaces.list_virtual_machine_scale_set_network_interfaces_as_lazy
def list_virtual_machine_scale_set_network_interfaces_as_lazy(resource_group_name, virtual_machine_scale_set_name, custom_headers:nil) response = list_virtual_machine_scale_set_network_interfaces_async(resource_group_name, virtual_machine_scale_set_name, custom_headers:custom_headers).value! unless response...
ruby
def list_virtual_machine_scale_set_network_interfaces_as_lazy(resource_group_name, virtual_machine_scale_set_name, custom_headers:nil) response = list_virtual_machine_scale_set_network_interfaces_async(resource_group_name, virtual_machine_scale_set_name, custom_headers:custom_headers).value! unless response...
[ "def", "list_virtual_machine_scale_set_network_interfaces_as_lazy", "(", "resource_group_name", ",", "virtual_machine_scale_set_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_virtual_machine_scale_set_network_interfaces_async", "(", "resource_group_name", ",", ...
The list network interface operation retrieves information about all network interfaces in a virtual machine scale set. @param resource_group_name [String] The name of the resource group. @param virtual_machine_scale_set_name [String] The name of the virtual machine scale set. @param custom_headers [Hash{String =...
[ "The", "list", "network", "interface", "operation", "retrieves", "information", "about", "all", "network", "interfaces", "in", "a", "virtual", "machine", "scale", "set", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2015-05-01-preview/generated/azure_mgmt_network/network_interfaces.rb#L1286-L1295
train
Gets all network interfaces in a virtual machine scale set.
[ 30522, 13366, 2862, 1035, 7484, 1035, 3698, 1035, 4094, 1035, 2275, 1035, 2897, 1035, 19706, 1035, 2004, 1035, 13971, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 7484, 1035, 3698, 1035, 4094, 1035, 2275, 1035, 2171, 1010, 7661, 1035, 20346, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
strongself/Generamba
lib/generamba/helpers/module_validator.rb
Generamba.ModuleValidator.all_nil_mandatory_fields_for_target_type
def all_nil_mandatory_fields_for_target_type(target_type, code_module) fields = [] variable_name = "#{target_type}_targets" unless code_module.instance_variable_get("@#{variable_name}") target_const_value = Generamba.const_get(target_type.upcase + '_TARGET_KEY') targets_const_value =...
ruby
def all_nil_mandatory_fields_for_target_type(target_type, code_module) fields = [] variable_name = "#{target_type}_targets" unless code_module.instance_variable_get("@#{variable_name}") target_const_value = Generamba.const_get(target_type.upcase + '_TARGET_KEY') targets_const_value =...
[ "def", "all_nil_mandatory_fields_for_target_type", "(", "target_type", ",", "code_module", ")", "fields", "=", "[", "]", "variable_name", "=", "\"#{target_type}_targets\"", "unless", "code_module", ".", "instance_variable_get", "(", "\"@#{variable_name}\"", ")", "target_con...
Method which return all failure fields for target_type @param target_type [String] "project" or "test" @param code_module [CodeModule] The instance of CodeModule @return [Array]
[ "Method", "which", "return", "all", "failure", "fields", "for", "target_type", "@param", "target_type", "[", "String", "]", "project", "or", "test", "@param", "code_module", "[", "CodeModule", "]", "The", "instance", "of", "CodeModule" ]
9ef343805f3a66f58bc36e120e822d5436a4da97
https://github.com/strongself/Generamba/blob/9ef343805f3a66f58bc36e120e822d5436a4da97/lib/generamba/helpers/module_validator.rb#L61-L82
train
Returns all nil mandatory fields for a given target type.
[ 30522, 13366, 2035, 1035, 9152, 2140, 1035, 10915, 1035, 4249, 1035, 2005, 1035, 4539, 1035, 2828, 1006, 4539, 1035, 2828, 1010, 3642, 1035, 11336, 1007, 4249, 1027, 1031, 1033, 8023, 1035, 2171, 1027, 1000, 1001, 1063, 4539, 1035, 2828, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
guard/guard
lib/guard/plugin_util.rb
Guard.PluginUtil._plugin_constant
def _plugin_constant @_plugin_constant ||= Guard.constants.detect do |c| c.to_s.casecmp(_constant_name.downcase).zero? end end
ruby
def _plugin_constant @_plugin_constant ||= Guard.constants.detect do |c| c.to_s.casecmp(_constant_name.downcase).zero? end end
[ "def", "_plugin_constant", "@_plugin_constant", "||=", "Guard", ".", "constants", ".", "detect", "do", "|", "c", "|", "c", ".", "to_s", ".", "casecmp", "(", "_constant_name", ".", "downcase", ")", ".", "zero?", "end", "end" ]
Returns the constant for the current plugin. @example Returns the constant for a plugin > Guard::PluginUtil.new('rspec').send(:_plugin_constant) => Guard::RSpec
[ "Returns", "the", "constant", "for", "the", "current", "plugin", "." ]
e2508cd83badf0d537dbaba35d307adc35d92e4f
https://github.com/guard/guard/blob/e2508cd83badf0d537dbaba35d307adc35d92e4f/lib/guard/plugin_util.rb#L160-L164
train
Find the plugin constant
[ 30522, 13366, 1035, 13354, 2378, 1035, 5377, 1030, 1035, 13354, 2378, 1035, 5377, 1064, 1064, 1027, 3457, 1012, 5377, 2015, 1012, 11487, 2079, 1064, 1039, 1064, 1039, 1012, 2000, 1035, 1055, 1012, 2553, 27487, 2361, 1006, 1035, 5377, 1035, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
piotrmurach/github
lib/github_api/client/repos/contents.rb
Github.Client::Repos::Contents.delete
def delete(*args) arguments(args, required: [:user, :repo, :path]) do assert_required %w[ path message sha ] end delete_request("/repos/#{arguments.user}/#{arguments.repo}/contents/#{arguments.path}", arguments.params) end
ruby
def delete(*args) arguments(args, required: [:user, :repo, :path]) do assert_required %w[ path message sha ] end delete_request("/repos/#{arguments.user}/#{arguments.repo}/contents/#{arguments.path}", arguments.params) end
[ "def", "delete", "(", "*", "args", ")", "arguments", "(", "args", ",", "required", ":", "[", ":user", ",", ":repo", ",", ":path", "]", ")", "do", "assert_required", "%w[", "path", "message", "sha", "]", "end", "delete_request", "(", "\"/repos/#{arguments.u...
Delete a file This method deletes a file in a repository @param [Hash] params @option params [String] :path Requried string. The content path @option params [String] @option params [String] :message Requried string. The commit message. @option params [String] :sha Required string. The blob SHA of the f...
[ "Delete", "a", "file" ]
8702452c66bea33c9388550aed9e9974f76aaef1
https://github.com/piotrmurach/github/blob/8702452c66bea33c9388550aed9e9974f76aaef1/lib/github_api/client/repos/contents.rb#L202-L208
train
Delete a file or directory
[ 30522, 13366, 3972, 12870, 1006, 1008, 12098, 5620, 1007, 9918, 1006, 12098, 5620, 1010, 3223, 1024, 1031, 1024, 5310, 1010, 1024, 16360, 2080, 1010, 1024, 4130, 1033, 1007, 2079, 20865, 1035, 3223, 1003, 1059, 1031, 4130, 4471, 21146, 1033...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_network/lib/2018-10-01/generated/azure_mgmt_network/connection_monitors.rb
Azure::Network::Mgmt::V2018_10_01.ConnectionMonitors.delete
def delete(resource_group_name, network_watcher_name, connection_monitor_name, custom_headers:nil) response = delete_async(resource_group_name, network_watcher_name, connection_monitor_name, custom_headers:custom_headers).value! nil end
ruby
def delete(resource_group_name, network_watcher_name, connection_monitor_name, custom_headers:nil) response = delete_async(resource_group_name, network_watcher_name, connection_monitor_name, custom_headers:custom_headers).value! nil end
[ "def", "delete", "(", "resource_group_name", ",", "network_watcher_name", ",", "connection_monitor_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "delete_async", "(", "resource_group_name", ",", "network_watcher_name", ",", "connection_monitor_name", ",",...
Deletes the specified connection monitor. @param resource_group_name [String] The name of the resource group containing Network Watcher. @param network_watcher_name [String] The name of the Network Watcher resource. @param connection_monitor_name [String] The name of the connection monitor. @param custom_headers...
[ "Deletes", "the", "specified", "connection", "monitor", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-10-01/generated/azure_mgmt_network/connection_monitors.rb#L189-L192
train
Deletes a connection monitor.
[ 30522, 13366, 3972, 12870, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2897, 1035, 3422, 2121, 1035, 2171, 1010, 4434, 1035, 8080, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3972, 12870, 1035, 2004, 6038, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_service_fabric/lib/6.2.0.9/generated/azure_service_fabric/service_fabric_client_apis.rb
Azure::ServiceFabric::V6_2_0_9.ServiceFabricClientAPIs.get_replica_health
def get_replica_health(partition_id, replica_id, events_health_state_filter:0, timeout:60, custom_headers:nil) response = get_replica_health_async(partition_id, replica_id, events_health_state_filter:events_health_state_filter, timeout:timeout, custom_headers:custom_headers).value! response.body unless resp...
ruby
def get_replica_health(partition_id, replica_id, events_health_state_filter:0, timeout:60, custom_headers:nil) response = get_replica_health_async(partition_id, replica_id, events_health_state_filter:events_health_state_filter, timeout:timeout, custom_headers:custom_headers).value! response.body unless resp...
[ "def", "get_replica_health", "(", "partition_id", ",", "replica_id", ",", "events_health_state_filter", ":", "0", ",", "timeout", ":", "60", ",", "custom_headers", ":", "nil", ")", "response", "=", "get_replica_health_async", "(", "partition_id", ",", "replica_id", ...
Gets the health of a Service Fabric stateful service replica or stateless service instance. Gets the health of a Service Fabric replica. Use EventsHealthStateFilter to filter the collection of health events reported on the replica based on the health state. @param partition_id The identity of the partition. @pa...
[ "Gets", "the", "health", "of", "a", "Service", "Fabric", "stateful", "service", "replica", "or", "stateless", "service", "instance", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_service_fabric/lib/6.2.0.9/generated/azure_service_fabric/service_fabric_client_apis.rb#L14712-L14715
train
Gets the health of the replica.
[ 30522, 13366, 2131, 1035, 15059, 1035, 2740, 1006, 13571, 1035, 8909, 1010, 15059, 1035, 8909, 1010, 2824, 1035, 2740, 1035, 2110, 1035, 11307, 1024, 1014, 1010, 2051, 5833, 1024, 3438, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_web/lib/2018-02-01/generated/azure_mgmt_web/app_service_environments.rb
Azure::Web::Mgmt::V2018_02_01.AppServiceEnvironments.list_worker_pool_instance_metrics
def list_worker_pool_instance_metrics(resource_group_name, name, worker_pool_name, instance, details:nil, filter:nil, custom_headers:nil) first_page = list_worker_pool_instance_metrics_as_lazy(resource_group_name, name, worker_pool_name, instance, details:details, filter:filter, custom_headers:custom_headers) ...
ruby
def list_worker_pool_instance_metrics(resource_group_name, name, worker_pool_name, instance, details:nil, filter:nil, custom_headers:nil) first_page = list_worker_pool_instance_metrics_as_lazy(resource_group_name, name, worker_pool_name, instance, details:details, filter:filter, custom_headers:custom_headers) ...
[ "def", "list_worker_pool_instance_metrics", "(", "resource_group_name", ",", "name", ",", "worker_pool_name", ",", "instance", ",", "details", ":", "nil", ",", "filter", ":", "nil", ",", "custom_headers", ":", "nil", ")", "first_page", "=", "list_worker_pool_instanc...
Get metrics for a specific instance of a worker pool of an App Service Environment. Get metrics for a specific instance of a worker pool of an App Service Environment. @param resource_group_name [String] Name of the resource group to which the resource belongs. @param name [String] Name of the App Service Envir...
[ "Get", "metrics", "for", "a", "specific", "instance", "of", "a", "worker", "pool", "of", "an", "App", "Service", "Environment", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_web/lib/2018-02-01/generated/azure_mgmt_web/app_service_environments.rb#L3568-L3571
train
Gets metrics for a worker pool instance.
[ 30522, 13366, 2862, 1035, 7309, 1035, 4770, 1035, 6013, 1035, 12046, 2015, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2171, 1010, 7309, 1035, 4770, 1035, 2171, 1010, 6013, 1010, 4751, 1024, 9152, 2140, 1010, 11307, 1024, 9152, 2140, 1010, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
alexreisner/geocoder
lib/geocoder/cache.rb
Geocoder.Cache.[]=
def []=(url, value) case when store.respond_to?(:[]=) store[key_for(url)] = value when store.respond_to?(:set) store.set key_for(url), value when store.respond_to?(:write) store.write key_for(url), value end end
ruby
def []=(url, value) case when store.respond_to?(:[]=) store[key_for(url)] = value when store.respond_to?(:set) store.set key_for(url), value when store.respond_to?(:write) store.write key_for(url), value end end
[ "def", "[]=", "(", "url", ",", "value", ")", "case", "when", "store", ".", "respond_to?", "(", ":[]=", ")", "store", "[", "key_for", "(", "url", ")", "]", "=", "value", "when", "store", ".", "respond_to?", "(", ":set", ")", "store", ".", "set", "ke...
Write to the Cache.
[ "Write", "to", "the", "Cache", "." ]
e087dc2759264ee6f307b926bb2de4ec2406859e
https://github.com/alexreisner/geocoder/blob/e087dc2759264ee6f307b926bb2de4ec2406859e/lib/geocoder/cache.rb#L26-L35
train
Set the value of the key_for ( url ) in the cache
[ 30522, 13366, 1031, 1033, 1027, 1006, 24471, 2140, 1010, 3643, 1007, 2553, 2043, 3573, 1012, 6869, 1035, 2000, 1029, 1006, 1024, 1031, 1033, 1027, 1007, 3573, 1031, 3145, 1035, 2005, 1006, 24471, 2140, 1007, 1033, 1027, 3643, 2043, 3573, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
stripe/stripe-ruby
lib/stripe/stripe_client.rb
Stripe.StripeClient.request
def request @last_response = nil old_stripe_client = Thread.current[:stripe_client] Thread.current[:stripe_client] = self begin res = yield [res, @last_response] ensure Thread.current[:stripe_client] = old_stripe_client end end
ruby
def request @last_response = nil old_stripe_client = Thread.current[:stripe_client] Thread.current[:stripe_client] = self begin res = yield [res, @last_response] ensure Thread.current[:stripe_client] = old_stripe_client end end
[ "def", "request", "@last_response", "=", "nil", "old_stripe_client", "=", "Thread", ".", "current", "[", ":stripe_client", "]", "Thread", ".", "current", "[", ":stripe_client", "]", "=", "self", "begin", "res", "=", "yield", "[", "res", ",", "@last_response", ...
Executes the API call within the given block. Usage looks like: client = StripeClient.new charge, resp = client.request { Charge.create }
[ "Executes", "the", "API", "call", "within", "the", "given", "block", ".", "Usage", "looks", "like", ":" ]
322a8c60be8a9b9ac8aad8857864680a32176935
https://github.com/stripe/stripe-ruby/blob/322a8c60be8a9b9ac8aad8857864680a32176935/lib/stripe/stripe_client.rb#L111-L122
train
Request an array of objects from the resource
[ 30522, 13366, 5227, 1030, 2197, 1035, 3433, 1027, 9152, 2140, 2214, 1035, 18247, 1035, 7396, 1027, 11689, 1012, 2783, 1031, 1024, 18247, 1035, 7396, 1033, 11689, 1012, 2783, 1031, 1024, 18247, 1035, 7396, 1033, 1027, 2969, 4088, 24501, 1027...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
etewiah/property_web_builder
app/models/pwb/prop.rb
Pwb.Prop.contextual_price_with_currency
def contextual_price_with_currency(rent_or_sale) contextual_price = self.contextual_price rent_or_sale if contextual_price.zero? return nil else return contextual_price.format(no_cents: true) end # return contextual_price.zero? ? nil : contextual_price.format(:no_cents => ...
ruby
def contextual_price_with_currency(rent_or_sale) contextual_price = self.contextual_price rent_or_sale if contextual_price.zero? return nil else return contextual_price.format(no_cents: true) end # return contextual_price.zero? ? nil : contextual_price.format(:no_cents => ...
[ "def", "contextual_price_with_currency", "(", "rent_or_sale", ")", "contextual_price", "=", "self", ".", "contextual_price", "rent_or_sale", "if", "contextual_price", ".", "zero?", "return", "nil", "else", "return", "contextual_price", ".", "format", "(", "no_cents", ...
will return nil if price is 0
[ "will", "return", "nil", "if", "price", "is", "0" ]
fba4e6d4ffa7bc1f4d3b50dfa5a6a9fbfee23f21
https://github.com/etewiah/property_web_builder/blob/fba4e6d4ffa7bc1f4d3b50dfa5a6a9fbfee23f21/app/models/pwb/prop.rb#L211-L220
train
Returns the contextual price with the currency
[ 30522, 13366, 6123, 8787, 1035, 3976, 1035, 2007, 1035, 9598, 1006, 9278, 1035, 2030, 1035, 5096, 1007, 6123, 8787, 1035, 3976, 1027, 2969, 1012, 6123, 8787, 1035, 3976, 9278, 1035, 2030, 1035, 5096, 2065, 6123, 8787, 1035, 3976, 1012, 57...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
fastlane/fastlane
fastlane/lib/fastlane/other_action.rb
Fastlane.OtherAction.method_missing
def method_missing(method_sym, *arguments, &_block) # We have to go inside the fastlane directory # since in the fastlane runner.rb we do the following # custom_dir = ".." # Dir.chdir(custom_dir) do # this goes one folder up, since we're inside the "fastlane" # folder at that poi...
ruby
def method_missing(method_sym, *arguments, &_block) # We have to go inside the fastlane directory # since in the fastlane runner.rb we do the following # custom_dir = ".." # Dir.chdir(custom_dir) do # this goes one folder up, since we're inside the "fastlane" # folder at that poi...
[ "def", "method_missing", "(", "method_sym", ",", "*", "arguments", ",", "&", "_block", ")", "# We have to go inside the fastlane directory", "# since in the fastlane runner.rb we do the following", "# custom_dir = \"..\"", "# Dir.chdir(custom_dir) do", "# this goes one folder up, s...
Allows the user to call an action from an action
[ "Allows", "the", "user", "to", "call", "an", "action", "from", "an", "action" ]
457c5d647c77f0e078dafa5129da616914e002c5
https://github.com/fastlane/fastlane/blob/457c5d647c77f0e078dafa5129da616914e002c5/fastlane/lib/fastlane/other_action.rb#L13-L27
train
This method is called by the FastlaneRunner.
[ 30522, 13366, 4118, 1035, 4394, 1006, 4118, 1035, 25353, 2213, 1010, 1008, 9918, 1010, 1004, 1035, 3796, 1007, 1001, 2057, 2031, 2000, 2175, 2503, 1996, 3435, 20644, 14176, 1001, 2144, 1999, 1996, 3435, 20644, 5479, 1012, 21144, 2057, 2079,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Model.add_closed_list
def add_closed_list(app_id, version_id, closed_list_model_create_object, custom_headers:nil) response = add_closed_list_async(app_id, version_id, closed_list_model_create_object, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def add_closed_list(app_id, version_id, closed_list_model_create_object, custom_headers:nil) response = add_closed_list_async(app_id, version_id, closed_list_model_create_object, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "add_closed_list", "(", "app_id", ",", "version_id", ",", "closed_list_model_create_object", ",", "custom_headers", ":", "nil", ")", "response", "=", "add_closed_list_async", "(", "app_id", ",", "version_id", ",", "closed_list_model_create_object", ",", "custom_h...
Adds a list entity model to a version of the application. @param app_id The application ID. @param version_id [String] The version ID. @param closed_list_model_create_object [ClosedListModelCreateObject] A model containing the name and words for the new list entity extractor. @param custom_headers [Hash{String =>...
[ "Adds", "a", "list", "entity", "model", "to", "a", "version", "of", "the", "application", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb#L1096-L1099
train
Adds a list to a version of the application.
[ 30522, 13366, 5587, 1035, 2701, 1035, 2862, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 2701, 1035, 2862, 1035, 2944, 1035, 3443, 1035, 4874, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 5587, 1035, 2701, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
sds/haml-lint
lib/haml_lint/linter.rb
HamlLint.Linter.inline_node_content
def inline_node_content(node) inline_content = node.script if contains_interpolation?(inline_content) strip_surrounding_quotes(inline_content) else inline_content end end
ruby
def inline_node_content(node) inline_content = node.script if contains_interpolation?(inline_content) strip_surrounding_quotes(inline_content) else inline_content end end
[ "def", "inline_node_content", "(", "node", ")", "inline_content", "=", "node", ".", "script", "if", "contains_interpolation?", "(", "inline_content", ")", "strip_surrounding_quotes", "(", "inline_content", ")", "else", "inline_content", "end", "end" ]
Get the inline content for this node. Inline content is the content that appears inline right after the tag/script. For example, in the code below... %tag Some inline content ..."Some inline content" would be the inline content. @param node [HamlLint::Tree::Node] @return [String]
[ "Get", "the", "inline", "content", "for", "this", "node", "." ]
024c773667e54cf88db938c2b368977005d70ee8
https://github.com/sds/haml-lint/blob/024c773667e54cf88db938c2b368977005d70ee8/lib/haml_lint/linter.rb#L138-L146
train
Returns the inline content of the node
[ 30522, 13366, 23881, 1035, 13045, 1035, 4180, 1006, 13045, 1007, 23881, 1035, 4180, 1027, 13045, 1012, 5896, 2065, 3397, 1035, 6970, 18155, 3370, 1029, 1006, 23881, 1035, 4180, 1007, 6167, 1035, 4193, 1035, 16614, 1006, 23881, 1035, 4180, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
grpc/grpc
src/ruby/lib/grpc/generic/active_call.rb
GRPC.ActiveCall.each_remote_read
def each_remote_read return enum_for(:each_remote_read) unless block_given? begin loop do resp = remote_read break if resp.nil? # the last response was received yield resp end ensure set_input_stream_done end end
ruby
def each_remote_read return enum_for(:each_remote_read) unless block_given? begin loop do resp = remote_read break if resp.nil? # the last response was received yield resp end ensure set_input_stream_done end end
[ "def", "each_remote_read", "return", "enum_for", "(", ":each_remote_read", ")", "unless", "block_given?", "begin", "loop", "do", "resp", "=", "remote_read", "break", "if", "resp", ".", "nil?", "# the last response was received", "yield", "resp", "end", "ensure", "se...
each_remote_read passes each response to the given block or returns an enumerator the responses if no block is given. Used to generate the request enumerable for server-side client-streaming RPC's. == Enumerator == * #next blocks until the remote endpoint sends a READ or FINISHED * for each read, enumerator#nex...
[ "each_remote_read", "passes", "each", "response", "to", "the", "given", "block", "or", "returns", "an", "enumerator", "the", "responses", "if", "no", "block", "is", "given", ".", "Used", "to", "generate", "the", "request", "enumerable", "for", "server", "-", ...
f3937f0e55227a4ef3a23f895d3b204a947610f8
https://github.com/grpc/grpc/blob/f3937f0e55227a4ef3a23f895d3b204a947610f8/src/ruby/lib/grpc/generic/active_call.rb#L290-L301
train
Yields the response from the remote server.
[ 30522, 13366, 2169, 1035, 6556, 1035, 3191, 2709, 4372, 2819, 1035, 2005, 1006, 1024, 2169, 1035, 6556, 1035, 3191, 1007, 4983, 3796, 1035, 2445, 1029, 4088, 7077, 2079, 24501, 2361, 1027, 6556, 1035, 3191, 3338, 2065, 24501, 2361, 1012, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_face/lib/1.0/generated/azure_cognitiveservices_face/person_group_person.rb
Azure::CognitiveServices::Face::V1_0.PersonGroupPerson.delete_face
def delete_face(person_group_id, person_id, persisted_face_id, custom_headers:nil) response = delete_face_async(person_group_id, person_id, persisted_face_id, custom_headers:custom_headers).value! nil end
ruby
def delete_face(person_group_id, person_id, persisted_face_id, custom_headers:nil) response = delete_face_async(person_group_id, person_id, persisted_face_id, custom_headers:custom_headers).value! nil end
[ "def", "delete_face", "(", "person_group_id", ",", "person_id", ",", "persisted_face_id", ",", "custom_headers", ":", "nil", ")", "response", "=", "delete_face_async", "(", "person_group_id", ",", "person_id", ",", "persisted_face_id", ",", "custom_headers", ":custom_...
Delete a face from a person. Relative feature for the persisted face will also be deleted. @param person_group_id [String] Id referencing a particular person group. @param person_id Id referencing a particular person. @param persisted_face_id Id referencing a particular persistedFaceId of an existing face. @para...
[ "Delete", "a", "face", "from", "a", "person", ".", "Relative", "feature", "for", "the", "persisted", "face", "will", "also", "be", "deleted", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_face/lib/1.0/generated/azure_cognitiveservices_face/person_group_person.rb#L554-L557
train
Deletes a persisted face.
[ 30522, 13366, 3972, 12870, 1035, 2227, 1006, 2711, 1035, 2177, 1035, 8909, 1010, 2711, 1035, 8909, 1010, 19035, 1035, 2227, 1035, 8909, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3972, 12870, 1035, 2227, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
daddyz/phonelib
lib/phonelib/data_importer_helper.rb
Phonelib.DataImporterHelper.save_extended_data_file
def save_extended_data_file extended = { Phonelib::Core::EXT_PREFIXES => @prefixes, Phonelib::Core::EXT_GEO_NAMES => @geo_names, Phonelib::Core::EXT_COUNTRY_NAMES => @countries, Phonelib::Core::EXT_TIMEZONES => @timezones, Phonelib::Core::EXT_CARRIERS => @carriers } ...
ruby
def save_extended_data_file extended = { Phonelib::Core::EXT_PREFIXES => @prefixes, Phonelib::Core::EXT_GEO_NAMES => @geo_names, Phonelib::Core::EXT_COUNTRY_NAMES => @countries, Phonelib::Core::EXT_TIMEZONES => @timezones, Phonelib::Core::EXT_CARRIERS => @carriers } ...
[ "def", "save_extended_data_file", "extended", "=", "{", "Phonelib", "::", "Core", "::", "EXT_PREFIXES", "=>", "@prefixes", ",", "Phonelib", "::", "Core", "::", "EXT_GEO_NAMES", "=>", "@geo_names", ",", "Phonelib", "::", "Core", "::", "EXT_COUNTRY_NAMES", "=>", "...
method saves extended data file
[ "method", "saves", "extended", "data", "file" ]
aa0023eab7c896b71275bf342bc7f49735cbdbbf
https://github.com/daddyz/phonelib/blob/aa0023eab7c896b71275bf342bc7f49735cbdbbf/lib/phonelib/data_importer_helper.rb#L21-L33
train
Save the extended data file to disk
[ 30522, 13366, 3828, 1035, 3668, 1035, 2951, 1035, 5371, 3668, 1027, 1063, 3042, 29521, 1024, 1024, 4563, 1024, 1024, 4654, 2102, 1035, 17576, 2229, 1027, 1028, 1030, 17576, 2229, 1010, 3042, 29521, 1024, 1024, 4563, 1024, 1024, 4654, 2102, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_storagesync/lib/2018-07-01/generated/azure_mgmt_storagesync/cloud_endpoints.rb
Azure::StorageSync::Mgmt::V2018_07_01.CloudEndpoints.begin_post_restore_with_http_info
def begin_post_restore_with_http_info(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:nil) begin_post_restore_async(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:custom_headers).valu...
ruby
def begin_post_restore_with_http_info(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:nil) begin_post_restore_async(resource_group_name, storage_sync_service_name, sync_group_name, cloud_endpoint_name, parameters, custom_headers:custom_headers).valu...
[ "def", "begin_post_restore_with_http_info", "(", "resource_group_name", ",", "storage_sync_service_name", ",", "sync_group_name", ",", "cloud_endpoint_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "begin_post_restore_async", "(", "resource_group_name", ","...
Post Restore a given CloudEndpoint. @param resource_group_name [String] The name of the resource group. The name is case insensitive. @param storage_sync_service_name [String] Name of Storage Sync Service resource. @param sync_group_name [String] Name of Sync Group resource. @param cloud_endpoint_name [String] N...
[ "Post", "Restore", "a", "given", "CloudEndpoint", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_storagesync/lib/2018-07-01/generated/azure_mgmt_storagesync/cloud_endpoints.rb#L1241-L1243
train
Restores a CloudEndpoint.
[ 30522, 13366, 4088, 1035, 2695, 1035, 9239, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 5527, 1035, 26351, 1035, 2326, 1035, 2171, 1010, 26351, 1035, 2177, 1035, 2171, 1010, 6112, 1035, 2203, 8400, 1035, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
square/connect-ruby-sdk
lib/square_connect/api/employees_api.rb
SquareConnect.EmployeesApi.retrieve_employee
def retrieve_employee(id, opts = {}) data, _status_code, _headers = retrieve_employee_with_http_info(id, opts) return data end
ruby
def retrieve_employee(id, opts = {}) data, _status_code, _headers = retrieve_employee_with_http_info(id, opts) return data end
[ "def", "retrieve_employee", "(", "id", ",", "opts", "=", "{", "}", ")", "data", ",", "_status_code", ",", "_headers", "=", "retrieve_employee_with_http_info", "(", "id", ",", "opts", ")", "return", "data", "end" ]
RetrieveEmployee Gets an `Employee` by Square-assigned employee `ID` (UUID) @param id UUID for the employee that was requested. @param [Hash] opts the optional parameters @return [RetrieveEmployeeResponse]
[ "RetrieveEmployee", "Gets", "an", "Employee", "by", "Square", "-", "assigned", "employee", "ID", "(", "UUID", ")" ]
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/api/employees_api.rb#L91-L94
train
Retrieve an employee
[ 30522, 13366, 12850, 1035, 7904, 1006, 8909, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 2951, 1010, 1035, 3570, 1035, 3642, 1010, 1035, 20346, 2015, 1027, 12850, 1035, 7904, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 8909, 1010, 23569, 2015...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
octokit/octokit.rb
lib/octokit/enterprise_management_console_client/management_console.rb
Octokit.EnterpriseManagementConsoleClient.faraday_configuration
def faraday_configuration @faraday_configuration ||= Faraday.new(:url => @management_console_endpoint) do |http| http.headers[:user_agent] = user_agent http.request :multipart http.request :url_encoded # Disabling SSL is essential for certain self-hosted Enterprise instances ...
ruby
def faraday_configuration @faraday_configuration ||= Faraday.new(:url => @management_console_endpoint) do |http| http.headers[:user_agent] = user_agent http.request :multipart http.request :url_encoded # Disabling SSL is essential for certain self-hosted Enterprise instances ...
[ "def", "faraday_configuration", "@faraday_configuration", "||=", "Faraday", ".", "new", "(", ":url", "=>", "@management_console_endpoint", ")", "do", "|", "http", "|", "http", ".", "headers", "[", ":user_agent", "]", "=", "user_agent", "http", ".", "request", ":...
We fall back to raw Faraday for handling the licenses because I'm suspicious that Sawyer isn't handling binary POSTs correctly: http://git.io/jMir
[ "We", "fall", "back", "to", "raw", "Faraday", "for", "handling", "the", "licenses", "because", "I", "m", "suspicious", "that", "Sawyer", "isn", "t", "handling", "binary", "POSTs", "correctly", ":", "http", ":", "//", "git", ".", "io", "/", "jMir" ]
ddf750601529a6a7da5fe5293d10031709b8605d
https://github.com/octokit/octokit.rb/blob/ddf750601529a6a7da5fe5293d10031709b8605d/lib/octokit/enterprise_management_console_client/management_console.rb#L160-L174
train
Initializes the Faraday configuration object
[ 30522, 13366, 2521, 28039, 1035, 9563, 1030, 2521, 28039, 1035, 9563, 1064, 1064, 1027, 2521, 28039, 1012, 2047, 1006, 1024, 24471, 2140, 1027, 1028, 1030, 2968, 1035, 10122, 1035, 2203, 8400, 1007, 2079, 1064, 8299, 1064, 8299, 1012, 20346...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
tongueroo/jets
lib/jets/resource/child_stack/shared.rb
Jets::Resource::ChildStack.Shared.shared_logical_id
def shared_logical_id regexp = Regexp.new(".*#{Jets.config.project_namespace}-shared-") # remove the shared shared_name = @path.sub(regexp, '').sub('.yml', '') shared_name.underscore.camelize end
ruby
def shared_logical_id regexp = Regexp.new(".*#{Jets.config.project_namespace}-shared-") # remove the shared shared_name = @path.sub(regexp, '').sub('.yml', '') shared_name.underscore.camelize end
[ "def", "shared_logical_id", "regexp", "=", "Regexp", ".", "new", "(", "\".*#{Jets.config.project_namespace}-shared-\"", ")", "# remove the shared", "shared_name", "=", "@path", ".", "sub", "(", "regexp", ",", "''", ")", ".", "sub", "(", "'.yml'", ",", "''", ")",...
map the path to a camelized logical_id. Example: /tmp/jets/demo/templates/demo-dev-2-shared-resources.yml to PostsController
[ "map", "the", "path", "to", "a", "camelized", "logical_id", ".", "Example", ":", "/", "tmp", "/", "jets", "/", "demo", "/", "templates", "/", "demo", "-", "dev", "-", "2", "-", "shared", "-", "resources", ".", "yml", "to", "PostsController" ]
46943a519224067e58aa3e2d5656e3ca083150f9
https://github.com/tongueroo/jets/blob/46943a519224067e58aa3e2d5656e3ca083150f9/lib/jets/resource/child_stack/shared.rb#L64-L68
train
Returns the logical ID of the shared project
[ 30522, 13366, 4207, 1035, 11177, 1035, 8909, 19723, 10288, 2361, 1027, 19723, 10288, 2361, 1012, 2047, 1006, 1000, 1012, 1008, 1001, 1063, 9924, 1012, 9530, 8873, 2290, 1012, 2622, 1035, 30524, 4942, 1006, 19723, 10288, 2361, 1010, 1005, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...