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
Azure/azure-sdk-for-ruby
management/azure_mgmt_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/devices.rb
Azure::StorSimple8000Series::Mgmt::V2017_06_01.Devices.begin_scan_for_updates_with_http_info
def begin_scan_for_updates_with_http_info(device_name, resource_group_name, manager_name, custom_headers:nil) begin_scan_for_updates_async(device_name, resource_group_name, manager_name, custom_headers:custom_headers).value! end
ruby
def begin_scan_for_updates_with_http_info(device_name, resource_group_name, manager_name, custom_headers:nil) begin_scan_for_updates_async(device_name, resource_group_name, manager_name, custom_headers:custom_headers).value! end
[ "def", "begin_scan_for_updates_with_http_info", "(", "device_name", ",", "resource_group_name", ",", "manager_name", ",", "custom_headers", ":", "nil", ")", "begin_scan_for_updates_async", "(", "device_name", ",", "resource_group_name", ",", "manager_name", ",", "custom_hea...
Scans for updates on the device. @param device_name [String] The device name @param resource_group_name [String] The resource group name @param manager_name [String] The manager name @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [MsRestAz...
[ "Scans", "for", "updates", "on", "the", "device", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/devices.rb#L1592-L1594
train
Gets the list of documents that are currently being updated.
[ 30522, 13366, 4088, 1035, 13594, 1035, 2005, 1035, 14409, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 5080, 1035, 2171, 1010, 7692, 1035, 2177, 1035, 2171, 1010, 3208, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 4088, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_key_vault/lib/2016-10-01/generated/azure_key_vault/key_vault_client.rb
Azure::KeyVault::V2016_10_01.KeyVaultClient.update_secret_with_http_info
def update_secret_with_http_info(vault_base_url, secret_name, secret_version, content_type:nil, secret_attributes:nil, tags:nil, custom_headers:nil) update_secret_async(vault_base_url, secret_name, secret_version, content_type:content_type, secret_attributes:secret_attributes, tags:tags, custom_headers:custom_hea...
ruby
def update_secret_with_http_info(vault_base_url, secret_name, secret_version, content_type:nil, secret_attributes:nil, tags:nil, custom_headers:nil) update_secret_async(vault_base_url, secret_name, secret_version, content_type:content_type, secret_attributes:secret_attributes, tags:tags, custom_headers:custom_hea...
[ "def", "update_secret_with_http_info", "(", "vault_base_url", ",", "secret_name", ",", "secret_version", ",", "content_type", ":", "nil", ",", "secret_attributes", ":", "nil", ",", "tags", ":", "nil", ",", "custom_headers", ":", "nil", ")", "update_secret_async", ...
Updates the attributes associated with a specified secret in a given key vault. The UPDATE operation changes specified attributes of an existing stored secret. Attributes that are not specified in the request are left unchanged. The value of a secret itself cannot be changed. This operation requires the secrets/s...
[ "Updates", "the", "attributes", "associated", "with", "a", "specified", "secret", "in", "a", "given", "key", "vault", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_key_vault/lib/2016-10-01/generated/azure_key_vault/key_vault_client.rb#L2939-L2941
train
Updates a secret.
[ 30522, 13366, 10651, 1035, 3595, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 11632, 1035, 2918, 1035, 24471, 2140, 1010, 3595, 1035, 2171, 1010, 3595, 1035, 2544, 1010, 4180, 1035, 2828, 1024, 9152, 2140, 1010, 3595, 1035, 12332, 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...
aws/aws-sdk-ruby
gems/aws-sdk-iam/lib/aws-sdk-iam/policy.rb
Aws::IAM.Policy.detach_group
def detach_group(options = {}) options = options.merge(policy_arn: @arn) resp = @client.detach_group_policy(options) resp.data end
ruby
def detach_group(options = {}) options = options.merge(policy_arn: @arn) resp = @client.detach_group_policy(options) resp.data end
[ "def", "detach_group", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "policy_arn", ":", "@arn", ")", "resp", "=", "@client", ".", "detach_group_policy", "(", "options", ")", "resp", ".", "data", "end" ]
@example Request syntax with placeholder values policy.detach_group({ group_name: "groupNameType", # required }) @param [Hash] options ({}) @option options [required, String] :group_name The name (friendly name, not ARN) of the IAM group to detach the policy from. This parameter allows (through ...
[ "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-iam/lib/aws-sdk-iam/policy.rb#L423-L427
train
Detaches the policy from the group
[ 30522, 13366, 20010, 6776, 1035, 2177, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 3343, 1035, 12098, 2078, 1024, 1030, 12098, 2078, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 20010, 6776, 1035, 2177, 1035, 3343...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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-08-01/generated/azure_mgmt_network/network_watchers.rb
Azure::Network::Mgmt::V2018_08_01.NetworkWatchers.get_next_hop_async
def get_next_hop_async(resource_group_name, network_watcher_name, parameters, custom_headers:nil) # Send request promise = begin_get_next_hop_async(resource_group_name, network_watcher_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserializa...
ruby
def get_next_hop_async(resource_group_name, network_watcher_name, parameters, custom_headers:nil) # Send request promise = begin_get_next_hop_async(resource_group_name, network_watcher_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserializa...
[ "def", "get_next_hop_async", "(", "resource_group_name", ",", "network_watcher_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_get_next_hop_async", "(", "resource_group_name", ",", "network_watcher_name", ",", "pa...
@param resource_group_name [String] The name of the resource group. @param network_watcher_name [String] The name of the network watcher. @param parameters [NextHopParameters] Parameters that define the source and destination endpoint. @param custom_headers [Hash{String => String}] A hash of custom headers that wi...
[ "@param", "resource_group_name", "[", "String", "]", "The", "name", "of", "the", "resource", "group", ".", "@param", "network_watcher_name", "[", "String", "]", "The", "name", "of", "the", "network", "watcher", ".", "@param", "parameters", "[", "NextHopParameter...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-08-01/generated/azure_mgmt_network/network_watchers.rb#L729-L745
train
Gets the next hop for a specified resource group.
[ 30522, 13366, 2131, 1035, 2279, 1035, 6154, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2897, 1035, 3422, 2121, 1035, 2171, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 1001, 4604, 5227, 4872, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_automation/lib/2015-10-31/generated/azure_mgmt_automation/hybrid_runbook_worker_group_operations.rb
Azure::Automation::Mgmt::V2015_10_31.HybridRunbookWorkerGroupOperations.delete
def delete(resource_group_name, automation_account_name, hybrid_runbook_worker_group_name, custom_headers:nil) response = delete_async(resource_group_name, automation_account_name, hybrid_runbook_worker_group_name, custom_headers:custom_headers).value! nil end
ruby
def delete(resource_group_name, automation_account_name, hybrid_runbook_worker_group_name, custom_headers:nil) response = delete_async(resource_group_name, automation_account_name, hybrid_runbook_worker_group_name, custom_headers:custom_headers).value! nil end
[ "def", "delete", "(", "resource_group_name", ",", "automation_account_name", ",", "hybrid_runbook_worker_group_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "delete_async", "(", "resource_group_name", ",", "automation_account_name", ",", "hybrid_runbook_wo...
Delete a hybrid runbook worker group. @param resource_group_name [String] Name of an Azure Resource group. @param automation_account_name [String] The name of the automation account. @param hybrid_runbook_worker_group_name [String] The hybrid runbook worker group name @param custom_headers [Hash{String => String}...
[ "Delete", "a", "hybrid", "runbook", "worker", "group", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_automation/lib/2015-10-31/generated/azure_mgmt_automation/hybrid_runbook_worker_group_operations.rb#L35-L38
train
Deletes a hybrid runbook worker group.
[ 30522, 13366, 3972, 12870, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 19309, 1035, 4070, 1035, 2171, 1010, 8893, 1035, 2448, 8654, 1035, 7309, 1035, 2177, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 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...
square/connect-ruby-sdk
lib/square_connect/models/order_fulfillment_pickup_details.rb
SquareConnect.OrderFulfillmentPickupDetails.cancel_reason=
def cancel_reason=(cancel_reason) if !cancel_reason.nil? && cancel_reason.to_s.length > 100 fail ArgumentError, "invalid value for 'cancel_reason', the character length must be smaller than or equal to 100." end @cancel_reason = cancel_reason end
ruby
def cancel_reason=(cancel_reason) if !cancel_reason.nil? && cancel_reason.to_s.length > 100 fail ArgumentError, "invalid value for 'cancel_reason', the character length must be smaller than or equal to 100." end @cancel_reason = cancel_reason end
[ "def", "cancel_reason", "=", "(", "cancel_reason", ")", "if", "!", "cancel_reason", ".", "nil?", "&&", "cancel_reason", ".", "to_s", ".", "length", ">", "100", "fail", "ArgumentError", ",", "\"invalid value for 'cancel_reason', the character length must be smaller than or...
Custom attribute writer method with validation @param [Object] cancel_reason Value to be assigned
[ "Custom", "attribute", "writer", "method", "with", "validation" ]
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/models/order_fulfillment_pickup_details.rb#L251-L258
train
Set the cancel reason for this session.
[ 30522, 13366, 17542, 1035, 3114, 1027, 1006, 17542, 1035, 3114, 1007, 2065, 999, 17542, 1035, 3114, 1012, 9152, 2140, 1029, 1004, 1004, 17542, 1035, 3114, 1012, 2000, 1035, 1055, 1012, 3091, 1028, 2531, 8246, 6685, 2121, 29165, 1010, 1000, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_scheduler/lib/2016-03-01/generated/azure_mgmt_scheduler/jobs.rb
Azure::Scheduler::Mgmt::V2016_03_01.Jobs.create_or_update
def create_or_update(resource_group_name, job_collection_name, job_name, job, custom_headers:nil) response = create_or_update_async(resource_group_name, job_collection_name, job_name, job, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def create_or_update(resource_group_name, job_collection_name, job_name, job, custom_headers:nil) response = create_or_update_async(resource_group_name, job_collection_name, job_name, job, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "create_or_update", "(", "resource_group_name", ",", "job_collection_name", ",", "job_name", ",", "job", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_or_update_async", "(", "resource_group_name", ",", "job_collection_name", ",", "job_name", ...
Provisions a new job or updates an existing job. @param resource_group_name [String] The resource group name. @param job_collection_name [String] The job collection name. @param job_name [String] The job name. @param job [JobDefinition] The job definition. @param custom_headers [Hash{String => String}] A hash of ...
[ "Provisions", "a", "new", "job", "or", "updates", "an", "existing", "job", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_scheduler/lib/2016-03-01/generated/azure_mgmt_scheduler/jobs.rb#L132-L135
train
Creates or updates a job in the specified job collection.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3105, 1035, 3074, 1035, 2171, 1010, 3105, 1035, 2171, 1010, 3105, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3443, 1035, 2030, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/stylesheet/gradient_fill.rb
Axlsx.GradientFill.validate_format_percentage
def validate_format_percentage(name, value) DataTypeValidator.validate name, Float, value, lambda { |arg| arg >= 0.0 && arg <= 1.0} end
ruby
def validate_format_percentage(name, value) DataTypeValidator.validate name, Float, value, lambda { |arg| arg >= 0.0 && arg <= 1.0} end
[ "def", "validate_format_percentage", "(", "name", ",", "value", ")", "DataTypeValidator", ".", "validate", "name", ",", "Float", ",", "value", ",", "lambda", "{", "|", "arg", "|", "arg", ">=", "0.0", "&&", "arg", "<=", "1.0", "}", "end" ]
validates that the value provided is between 0.0 and 1.0
[ "validates", "that", "the", "value", "provided", "is", "between", "0", ".", "0", "and", "1", ".", "0" ]
c593a08b2a929dac7aa8dc418b55e26b4c49dc34
https://github.com/randym/axlsx/blob/c593a08b2a929dac7aa8dc418b55e26b4c49dc34/lib/axlsx/stylesheet/gradient_fill.rb#L88-L90
train
Validate the format percentage value
[ 30522, 13366, 9398, 3686, 1035, 4289, 1035, 7017, 1006, 2171, 1010, 3643, 1007, 2951, 13874, 10175, 8524, 4263, 1012, 9398, 3686, 2171, 1010, 14257, 1010, 3643, 1010, 23375, 1063, 1064, 12098, 2290, 1064, 12098, 2290, 1028, 1027, 1014, 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...
etewiah/property_web_builder
app/controllers/pwb/search_controller.rb
Pwb.SearchController.rent
def rent @page = Pwb::Page.find_by_slug "rent" @page_title = @current_agency.company_name # @content_to_show = [] if @page.present? @page_title = @page.page_title + ' - ' + @current_agency.company_name # TODO: - allow addition of custom content # @page.ordered_visible_pag...
ruby
def rent @page = Pwb::Page.find_by_slug "rent" @page_title = @current_agency.company_name # @content_to_show = [] if @page.present? @page_title = @page.page_title + ' - ' + @current_agency.company_name # TODO: - allow addition of custom content # @page.ordered_visible_pag...
[ "def", "rent", "@page", "=", "Pwb", "::", "Page", ".", "find_by_slug", "\"rent\"", "@page_title", "=", "@current_agency", ".", "company_name", "# @content_to_show = []", "if", "@page", ".", "present?", "@page_title", "=", "@page", ".", "page_title", "+", "' - '", ...
TODO: - avoid duplication b/n rent and buy
[ "TODO", ":", "-", "avoid", "duplication", "b", "/", "n", "rent", "and", "buy" ]
fba4e6d4ffa7bc1f4d3b50dfa5a6a9fbfee23f21
https://github.com/etewiah/property_web_builder/blob/fba4e6d4ffa7bc1f4d3b50dfa5a6a9fbfee23f21/app/controllers/pwb/search_controller.rb#L78-L111
train
Returns the result of the search
[ 30522, 13366, 9278, 1030, 3931, 1027, 1052, 2860, 2497, 1024, 1024, 3931, 1012, 2424, 1035, 2011, 1035, 23667, 1000, 9278, 1000, 1030, 3931, 1035, 2516, 1027, 1030, 2783, 1035, 4034, 1012, 2194, 1035, 2171, 1001, 1030, 4180, 1035, 2000, 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...
colszowka/simplecov
lib/simplecov/configuration.rb
SimpleCov.Configuration.parse_filter
def parse_filter(filter_argument = nil, &filter_proc) filter = filter_argument || filter_proc if filter SimpleCov::Filter.build_filter(filter) else raise ArgumentError, "Please specify either a filter or a block to filter with" end end
ruby
def parse_filter(filter_argument = nil, &filter_proc) filter = filter_argument || filter_proc if filter SimpleCov::Filter.build_filter(filter) else raise ArgumentError, "Please specify either a filter or a block to filter with" end end
[ "def", "parse_filter", "(", "filter_argument", "=", "nil", ",", "&", "filter_proc", ")", "filter", "=", "filter_argument", "||", "filter_proc", "if", "filter", "SimpleCov", "::", "Filter", ".", "build_filter", "(", "filter", ")", "else", "raise", "ArgumentError"...
The actual filter processor. Not meant for direct use
[ "The", "actual", "filter", "processor", ".", "Not", "meant", "for", "direct", "use" ]
8f6978a2513f10c4dd8d7dd7eed666fe3f2b55c2
https://github.com/colszowka/simplecov/blob/8f6978a2513f10c4dd8d7dd7eed666fe3f2b55c2/lib/simplecov/configuration.rb#L295-L303
train
Parse a filter
[ 30522, 13366, 11968, 3366, 1035, 11307, 1006, 11307, 1035, 6685, 1027, 9152, 2140, 1010, 1004, 11307, 1035, 4013, 2278, 1007, 11307, 1027, 11307, 1035, 6685, 1064, 1064, 11307, 1035, 4013, 2278, 2065, 11307, 3722, 3597, 2615, 1024, 1024, 11...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
hanami/hanami
lib/hanami/app.rb
Hanami.App.middleware
def middleware(configuration, environment) builder.use Hanami::CommonLogger, Hanami.logger unless Hanami.logger.nil? builder.use Rack::ContentLength configuration.middleware.each do |m, args, blk| builder.use(m, *args, &blk) end if configuration.early_hints require 'hanam...
ruby
def middleware(configuration, environment) builder.use Hanami::CommonLogger, Hanami.logger unless Hanami.logger.nil? builder.use Rack::ContentLength configuration.middleware.each do |m, args, blk| builder.use(m, *args, &blk) end if configuration.early_hints require 'hanam...
[ "def", "middleware", "(", "configuration", ",", "environment", ")", "builder", ".", "use", "Hanami", "::", "CommonLogger", ",", "Hanami", ".", "logger", "unless", "Hanami", ".", "logger", ".", "nil?", "builder", ".", "use", "Rack", "::", "ContentLength", "co...
@since 0.9.0 @api private rubocop:disable Metrics/AbcSize rubocop:disable Metrics/MethodLength
[ "@since", "0", ".", "9", ".", "0", "@api", "private" ]
8c6e5147e92ef869b25379448572da3698eacfdc
https://github.com/hanami/hanami/blob/8c6e5147e92ef869b25379448572da3698eacfdc/lib/hanami/app.rb#L74-L92
train
Create a new middleware instance.
[ 30522, 13366, 2690, 8059, 1006, 9563, 1010, 4044, 1007, 12508, 1012, 2224, 26048, 4328, 1024, 1024, 2691, 21197, 4590, 1010, 26048, 4328, 1012, 8833, 4590, 4983, 26048, 4328, 1012, 8833, 4590, 1012, 9152, 2140, 1029, 12508, 1012, 2224, 1451...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/directive_processor.rb
Sprockets.DirectiveProcessor.compile_header_pattern
def compile_header_pattern(comments) re = comments.map { |c| case c when String "(?:#{Regexp.escape(c)}.*\\n?)+" when Array "(?:#{Regexp.escape(c[0])}(?m:.*?)#{Regexp.escape(c[1])})" else raise TypeError, "unknown comment type: #{c.clas...
ruby
def compile_header_pattern(comments) re = comments.map { |c| case c when String "(?:#{Regexp.escape(c)}.*\\n?)+" when Array "(?:#{Regexp.escape(c[0])}(?m:.*?)#{Regexp.escape(c[1])})" else raise TypeError, "unknown comment type: #{c.clas...
[ "def", "compile_header_pattern", "(", "comments", ")", "re", "=", "comments", ".", "map", "{", "|", "c", "|", "case", "c", "when", "String", "\"(?:#{Regexp.escape(c)}.*\\\\n?)+\"", "when", "Array", "\"(?:#{Regexp.escape(c[0])}(?m:.*?)#{Regexp.escape(c[1])})\"", "else", ...
Directives will only be picked up if they are in the header of the source file. C style (/* */), JavaScript (//), and Ruby (#) comments are supported. Directives in comments after the first non-whitespace line of code will not be processed.
[ "Directives", "will", "only", "be", "picked", "up", "if", "they", "are", "in", "the", "header", "of", "the", "source", "file", ".", "C", "style", "(", "/", "*", "*", "/", ")", "JavaScript", "(", "//", ")", "and", "Ruby", "(", "#", ")", "comments", ...
9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd
https://github.com/rails/sprockets/blob/9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd/lib/sprockets/directive_processor.rb#L104-L116
train
compile header pattern
[ 30522, 13366, 4012, 22090, 1035, 20346, 1035, 5418, 1006, 7928, 1007, 2128, 1027, 7928, 1012, 4949, 1063, 1064, 1039, 1064, 2553, 1039, 2043, 5164, 1000, 1006, 1029, 1024, 1001, 1063, 19723, 10288, 2361, 1012, 4019, 1006, 1039, 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...
zendesk/ruby-kafka
lib/kafka/client.rb
Kafka.Client.deliver_message
def deliver_message(value, key: nil, headers: {}, topic:, partition: nil, partition_key: nil, retries: 1) create_time = Time.now message = PendingMessage.new( value: value, key: key, headers: headers, topic: topic, partition: partition, partition_key: partiti...
ruby
def deliver_message(value, key: nil, headers: {}, topic:, partition: nil, partition_key: nil, retries: 1) create_time = Time.now message = PendingMessage.new( value: value, key: key, headers: headers, topic: topic, partition: partition, partition_key: partiti...
[ "def", "deliver_message", "(", "value", ",", "key", ":", "nil", ",", "headers", ":", "{", "}", ",", "topic", ":", ",", "partition", ":", "nil", ",", "partition_key", ":", "nil", ",", "retries", ":", "1", ")", "create_time", "=", "Time", ".", "now", ...
Initializes a new Kafka client. @param seed_brokers [Array<String>, String] the list of brokers used to initialize the client. Either an Array of connections, or a comma separated string of connections. A connection can either be a string of "host:port" or a full URI with a scheme. If there's a scheme it's i...
[ "Initializes", "a", "new", "Kafka", "client", "." ]
2a73471b6a607a52dc85c79301ba522acb4566b5
https://github.com/zendesk/ruby-kafka/blob/2a73471b6a607a52dc85c79301ba522acb4566b5/lib/kafka/client.rb#L137-L212
train
Deliver a message to a topic.
[ 30522, 13366, 8116, 1035, 4471, 1006, 3643, 1010, 3145, 1024, 9152, 2140, 1010, 20346, 2015, 1024, 1063, 1065, 1010, 8476, 1024, 1010, 13571, 1024, 9152, 2140, 1010, 13571, 1035, 3145, 1024, 9152, 2140, 1010, 2128, 21011, 1024, 1015, 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...
rails/rails
activerecord/lib/active_record/database_configurations.rb
ActiveRecord.DatabaseConfigurations.default_hash
def default_hash(env = ActiveRecord::ConnectionHandling::DEFAULT_ENV.call.to_s) default = find_db_config(env) default.config if default end
ruby
def default_hash(env = ActiveRecord::ConnectionHandling::DEFAULT_ENV.call.to_s) default = find_db_config(env) default.config if default end
[ "def", "default_hash", "(", "env", "=", "ActiveRecord", "::", "ConnectionHandling", "::", "DEFAULT_ENV", ".", "call", ".", "to_s", ")", "default", "=", "find_db_config", "(", "env", ")", "default", ".", "config", "if", "default", "end" ]
Returns the config hash that corresponds with the environment If the application has multiple databases +default_hash+ will return the first config hash for the environment. { database: "my_db", adapter: "mysql2" }
[ "Returns", "the", "config", "hash", "that", "corresponds", "with", "the", "environment" ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activerecord/lib/active_record/database_configurations.rb#L60-L63
train
Returns the default hash for the database
[ 30522, 13366, 12398, 1035, 23325, 1006, 4372, 2615, 1027, 3161, 2890, 27108, 2094, 1024, 1024, 4434, 11774, 2989, 1024, 1024, 12398, 1035, 4372, 2615, 1012, 2655, 1012, 2000, 1035, 1055, 1007, 12398, 1027, 2424, 1035, 16962, 1035, 9530, 887...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.grab_video_preview
def grab_video_preview(video_path, timestamp, dimensions) width, height = dimensions require 'tempfile' tmp = Tempfile.new(['video_preview', ".jpg"]) file = tmp.path command = "ffmpeg -y -i \"#{video_path}\" -s #{width}x#{height} -ss \"#{timestamp}\" -vframes 1 \"#{file}\" 2>&1 >/dev/null"...
ruby
def grab_video_preview(video_path, timestamp, dimensions) width, height = dimensions require 'tempfile' tmp = Tempfile.new(['video_preview', ".jpg"]) file = tmp.path command = "ffmpeg -y -i \"#{video_path}\" -s #{width}x#{height} -ss \"#{timestamp}\" -vframes 1 \"#{file}\" 2>&1 >/dev/null"...
[ "def", "grab_video_preview", "(", "video_path", ",", "timestamp", ",", "dimensions", ")", "width", ",", "height", "=", "dimensions", "require", "'tempfile'", "tmp", "=", "Tempfile", ".", "new", "(", "[", "'video_preview'", ",", "\".jpg\"", "]", ")", "file", ...
Grabs a screenshot from the specified video at the specified timestamp using `ffmpeg` @param video_path (String) the path to the video file @param timestamp (String) the `ffmpeg` timestamp format (e.g. 00.00) @param dimensions (Array) the dimension of the screenshot to generate @return the TempFile containing the g...
[ "Grabs", "a", "screenshot", "from", "the", "specified", "video", "at", "the", "specified", "timestamp", "using", "ffmpeg" ]
457c5d647c77f0e078dafa5129da616914e002c5
https://github.com/fastlane/fastlane/blob/457c5d647c77f0e078dafa5129da616914e002c5/spaceship/lib/spaceship/du/utilities.rb#L44-L54
train
Grab a video preview
[ 30522, 13366, 6723, 1035, 2678, 1035, 19236, 1006, 2678, 1035, 4130, 1010, 2335, 15464, 2361, 1010, 9646, 1007, 9381, 1010, 4578, 1027, 9646, 5478, 1005, 8915, 8737, 8873, 2571, 1005, 1056, 8737, 1027, 8915, 8737, 8873, 2571, 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...
appium/ruby_lib
lib/appium_lib/ios/common/helper.rb
Appium.Ios._all_pred
def _all_pred(opts) predicate = opts[:predicate] raise 'predicate must be provided' unless predicate visible = opts.fetch :visible, true %($.mainApp().getAllWithPredicate("#{predicate}", #{visible});) end
ruby
def _all_pred(opts) predicate = opts[:predicate] raise 'predicate must be provided' unless predicate visible = opts.fetch :visible, true %($.mainApp().getAllWithPredicate("#{predicate}", #{visible});) end
[ "def", "_all_pred", "(", "opts", ")", "predicate", "=", "opts", "[", ":predicate", "]", "raise", "'predicate must be provided'", "unless", "predicate", "visible", "=", "opts", ".", "fetch", ":visible", ",", "true", "%($.mainApp().getAllWithPredicate(\"#{predicate}\", #{...
predicate - the predicate to evaluate on the main app visible - if true, only visible elements are returned. default true
[ "predicate", "-", "the", "predicate", "to", "evaluate", "on", "the", "main", "app" ]
1f5898400dd1928bfe42ddd5f842d1f8738f2f76
https://github.com/appium/ruby_lib/blob/1f5898400dd1928bfe42ddd5f842d1f8738f2f76/lib/appium_lib/ios/common/helper.rb#L376-L382
train
Returns all the terms that match the predicate
[ 30522, 13366, 1035, 2035, 1035, 3653, 2094, 1006, 23569, 2015, 1007, 3653, 16467, 1027, 23569, 2015, 1031, 1024, 3653, 16467, 1033, 5333, 1005, 3653, 16467, 2442, 2022, 3024, 1005, 4983, 3653, 16467, 5710, 1027, 23569, 2015, 1012, 18584, 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...
meew0/discordrb
lib/discordrb/data/server.rb
Discordrb.Server.move
def move(user, channel) API::Server.update_member(@bot.token, @id, user.resolve_id, channel_id: channel.resolve_id) end
ruby
def move(user, channel) API::Server.update_member(@bot.token, @id, user.resolve_id, channel_id: channel.resolve_id) end
[ "def", "move", "(", "user", ",", "channel", ")", "API", "::", "Server", ".", "update_member", "(", "@bot", ".", "token", ",", "@id", ",", "user", ".", "resolve_id", ",", "channel_id", ":", "channel", ".", "resolve_id", ")", "end" ]
Forcibly moves a user into a different voice channel. Only works if the bot has the permission needed. @param user [User, #resolve_id] The user to move. @param channel [Channel, #resolve_id] The voice channel to move into.
[ "Forcibly", "moves", "a", "user", "into", "a", "different", "voice", "channel", ".", "Only", "works", "if", "the", "bot", "has", "the", "permission", "needed", "." ]
764298a1ff0be69a1853b510d736f21c2b91a2fe
https://github.com/meew0/discordrb/blob/764298a1ff0be69a1853b510d736f21c2b91a2fe/lib/discordrb/data/server.rb#L573-L575
train
Move the server to another channel
[ 30522, 13366, 2693, 1006, 5310, 1010, 3149, 1007, 17928, 1024, 1024, 8241, 1012, 10651, 1035, 2266, 1006, 1030, 28516, 1012, 19204, 1010, 1030, 8909, 1010, 5310, 1012, 10663, 1035, 8909, 1010, 3149, 1035, 8909, 1024, 3149, 1012, 10663, 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...
aws/aws-sdk-ruby
gems/aws-sdk-rds/lib/aws-sdk-rds/resource.rb
Aws::RDS.Resource.create_db_instance
def create_db_instance(options = {}) resp = @client.create_db_instance(options) DBInstance.new( id: resp.data.db_instance.db_instance_identifier, data: resp.data.db_instance, client: @client ) end
ruby
def create_db_instance(options = {}) resp = @client.create_db_instance(options) DBInstance.new( id: resp.data.db_instance.db_instance_identifier, data: resp.data.db_instance, client: @client ) end
[ "def", "create_db_instance", "(", "options", "=", "{", "}", ")", "resp", "=", "@client", ".", "create_db_instance", "(", "options", ")", "DBInstance", ".", "new", "(", "id", ":", "resp", ".", "data", ".", "db_instance", ".", "db_instance_identifier", ",", ...
@example Request syntax with placeholder values dbinstance = rds.create_db_instance({ db_name: "String", db_instance_identifier: "String", # required allocated_storage: 1, db_instance_class: "String", # required engine: "String", # required master_username: "String", master_user_p...
[ "@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#L1226-L1233
train
Create a DB Instance
[ 30522, 13366, 3443, 1035, 16962, 1035, 6013, 1006, 7047, 1027, 1063, 1065, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 3443, 1035, 16962, 1035, 6013, 1006, 7047, 1007, 16962, 7076, 26897, 1012, 2047, 1006, 8909, 1024, 24501, 2361, 1012, 2951...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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
actionview/lib/action_view/layouts.rb
ActionView.Layouts._layout_for_option
def _layout_for_option(name) case name when String then _normalize_layout(name) when Proc then name when true then Proc.new { |lookup_context, formats| _default_layout(lookup_context, formats, true) } when :default then Proc.new { |lookup_context, formats| _default_layou...
ruby
def _layout_for_option(name) case name when String then _normalize_layout(name) when Proc then name when true then Proc.new { |lookup_context, formats| _default_layout(lookup_context, formats, true) } when :default then Proc.new { |lookup_context, formats| _default_layou...
[ "def", "_layout_for_option", "(", "name", ")", "case", "name", "when", "String", "then", "_normalize_layout", "(", "name", ")", "when", "Proc", "then", "name", "when", "true", "then", "Proc", ".", "new", "{", "|", "lookup_context", ",", "formats", "|", "_d...
Determine the layout for a given name, taking into account the name type. ==== Parameters * <tt>name</tt> - The name of the template
[ "Determine", "the", "layout", "for", "a", "given", "name", "taking", "into", "account", "the", "name", "type", "." ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/actionview/lib/action_view/layouts.rb#L387-L398
train
Returns the layout for the given option.
[ 30522, 13366, 1035, 9621, 1035, 2005, 1035, 5724, 1006, 2171, 1007, 2553, 2171, 2043, 5164, 2059, 1035, 3671, 4697, 1035, 9621, 1006, 2171, 1007, 2043, 4013, 2278, 2059, 2171, 2043, 2995, 2059, 4013, 2278, 1012, 2047, 1063, 1064, 2298, 62...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/snapshot.rb
Aws::EC2.Snapshot.delete
def delete(options = {}) options = options.merge(snapshot_id: @id) resp = @client.delete_snapshot(options) resp.data end
ruby
def delete(options = {}) options = options.merge(snapshot_id: @id) resp = @client.delete_snapshot(options) resp.data end
[ "def", "delete", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "snapshot_id", ":", "@id", ")", "resp", "=", "@client", ".", "delete_snapshot", "(", "options", ")", "resp", ".", "data", "end" ]
@example Request syntax with placeholder values snapshot.delete({ dry_run: false, }) @param [Hash] options ({}) @option options [Boolean] :dry_run Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the ...
[ "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-ec2/lib/aws-sdk-ec2/snapshot.rb#L429-L433
train
Delete a snapshot
[ 30522, 13366, 3972, 12870, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 20057, 12326, 1035, 8909, 1024, 1030, 8909, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 3972, 12870, 1035, 20057, 12326, 1006, 7047, 1007, 24...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
hanami/hanami
lib/hanami/routes.rb
Hanami.Routes.url
def url(name, *args) Utils::Escape::SafeString.new(@routes.url(name, *args)) end
ruby
def url(name, *args) Utils::Escape::SafeString.new(@routes.url(name, *args)) end
[ "def", "url", "(", "name", ",", "*", "args", ")", "Utils", "::", "Escape", "::", "SafeString", ".", "new", "(", "@routes", ".", "url", "(", "name", ",", "args", ")", ")", "end" ]
Return an absolute path for the given route name @param name [Symbol] the route name @param args [Array,nil] an optional set of arguments that is passed down to the wrapped route set. @return [Hanami::Utils::Escape::SafeString] the corresponding absolute URL @raise Hanami::Routing::InvalidRouteException @si...
[ "Return", "an", "absolute", "path", "for", "the", "given", "route", "name" ]
8c6e5147e92ef869b25379448572da3698eacfdc
https://github.com/hanami/hanami/blob/8c6e5147e92ef869b25379448572da3698eacfdc/lib/hanami/routes.rb#L136-L138
train
Returns the URL for the given route name.
[ 30522, 13366, 24471, 2140, 1006, 2171, 1010, 1008, 12098, 5620, 1007, 21183, 12146, 1024, 1024, 4019, 1024, 1024, 3647, 3367, 4892, 1012, 2047, 1006, 1030, 5847, 1012, 24471, 2140, 1006, 2171, 1010, 1008, 12098, 5620, 1007, 1007, 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...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
zendesk/ruby-kafka
lib/kafka/offset_manager.rb
Kafka.OffsetManager.seek_to_default
def seek_to_default(topic, partition) # Remove any cached offset, in case things have changed broker-side. clear_resolved_offset(topic) offset = resolve_offset(topic, partition) seek_to(topic, partition, offset) end
ruby
def seek_to_default(topic, partition) # Remove any cached offset, in case things have changed broker-side. clear_resolved_offset(topic) offset = resolve_offset(topic, partition) seek_to(topic, partition, offset) end
[ "def", "seek_to_default", "(", "topic", ",", "partition", ")", "# Remove any cached offset, in case things have changed broker-side.", "clear_resolved_offset", "(", "topic", ")", "offset", "=", "resolve_offset", "(", "topic", ",", "partition", ")", "seek_to", "(", "topic"...
Move the consumer's position in the partition back to the configured default offset, either the first or latest in the partition. @param topic [String] the name of the topic. @param partition [Integer] the partition number. @return [nil]
[ "Move", "the", "consumer", "s", "position", "in", "the", "partition", "back", "to", "the", "configured", "default", "offset", "either", "the", "first", "or", "latest", "in", "the", "partition", "." ]
2a73471b6a607a52dc85c79301ba522acb4566b5
https://github.com/zendesk/ruby-kafka/blob/2a73471b6a607a52dc85c79301ba522acb4566b5/lib/kafka/offset_manager.rb#L68-L75
train
Seek to the default partition.
[ 30522, 13366, 6148, 1035, 2000, 1035, 12398, 1006, 8476, 1010, 13571, 1007, 1001, 6366, 2151, 17053, 2094, 16396, 1010, 1999, 2553, 2477, 2031, 2904, 20138, 1011, 2217, 1012, 3154, 1035, 10395, 1035, 16396, 1006, 8476, 1007, 16396, 1027, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_sql/lib/2014-04-01/generated/azure_mgmt_sql/transparent_data_encryption_activities.rb
Azure::SQL::Mgmt::V2014_04_01.TransparentDataEncryptionActivities.list_by_configuration
def list_by_configuration(resource_group_name, server_name, database_name, custom_headers:nil) response = list_by_configuration_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_by_configuration(resource_group_name, server_name, database_name, custom_headers:nil) response = list_by_configuration_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_by_configuration", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_by_configuration_async", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",", "cust...
Returns a database's transparent data encryption operation result. @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 [S...
[ "Returns", "a", "database", "s", "transparent", "data", "encryption", "operation", "result", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_sql/lib/2014-04-01/generated/azure_mgmt_sql/transparent_data_encryption_activities.rb#L41-L44
train
Gets the list of all the available database documents.
[ 30522, 13366, 2862, 1035, 2011, 1035, 9563, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8241, 1035, 2171, 1010, 7809, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 2011, 1035, 9563, 1035, 2004, 6...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
boazsegev/combine_pdf
lib/combine_pdf/pdf_public.rb
CombinePDF.PDF.insert
def insert(location, data) pages_to_add = nil if data.is_a? PDF @version = [@version, data.version].max pages_to_add = data.pages actual_value(@names ||= {}.dup).update data.names, &HASH_MERGE_NEW_NO_PAGE merge_outlines((@outlines ||= {}.dup), actual_value(data.outlines), loc...
ruby
def insert(location, data) pages_to_add = nil if data.is_a? PDF @version = [@version, data.version].max pages_to_add = data.pages actual_value(@names ||= {}.dup).update data.names, &HASH_MERGE_NEW_NO_PAGE merge_outlines((@outlines ||= {}.dup), actual_value(data.outlines), loc...
[ "def", "insert", "(", "location", ",", "data", ")", "pages_to_add", "=", "nil", "if", "data", ".", "is_a?", "PDF", "@version", "=", "[", "@version", ",", "data", ".", "version", "]", ".", "max", "pages_to_add", "=", "data", ".", "pages", "actual_value", ...
add PDF pages (or PDF files) into a specific location. returns the new pages Array! (unlike `#<<`, doesn't return self!) location:: the location for the added page(s). Could be any number. negative numbers represent a count backwards (-1 being the end of the page array and 0 being the begining). if the location is ...
[ "add", "PDF", "pages", "(", "or", "PDF", "files", ")", "into", "a", "specific", "location", "." ]
09054051019c069f551f3e60be789577c0f93900
https://github.com/boazsegev/combine_pdf/blob/09054051019c069f551f3e60be789577c0f93900/lib/combine_pdf/pdf_public.rb#L304-L337
train
Insert a PDF object at the given location.
[ 30522, 13366, 19274, 1006, 3295, 1010, 2951, 1007, 5530, 1035, 2000, 1035, 5587, 1027, 9152, 2140, 2065, 2951, 1012, 2003, 1035, 1037, 1029, 11135, 1030, 2544, 1027, 1031, 1030, 2544, 1010, 2951, 1012, 2544, 1033, 1012, 4098, 5530, 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_web/lib/2018-02-01/generated/azure_mgmt_web/app_service_environments.rb
Azure::Web::Mgmt::V2018_02_01.AppServiceEnvironments.list_metrics
def list_metrics(resource_group_name, name, details:nil, filter:nil, custom_headers:nil) first_page = list_metrics_as_lazy(resource_group_name, name, details:details, filter:filter, custom_headers:custom_headers) first_page.get_all_items end
ruby
def list_metrics(resource_group_name, name, details:nil, filter:nil, custom_headers:nil) first_page = list_metrics_as_lazy(resource_group_name, name, details:details, filter:filter, custom_headers:custom_headers) first_page.get_all_items end
[ "def", "list_metrics", "(", "resource_group_name", ",", "name", ",", "details", ":", "nil", ",", "filter", ":", "nil", ",", "custom_headers", ":", "nil", ")", "first_page", "=", "list_metrics_as_lazy", "(", "resource_group_name", ",", "name", ",", "details", "...
Get global metrics of an App Service Environment. Get global metrics 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 Environment. @param details [Boolean] Specify <code>true</code> to include...
[ "Get", "global", "metrics", "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#L1181-L1184
train
Gets all metrics for a resource group.
[ 30522, 13366, 2862, 1035, 12046, 2015, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2171, 1010, 4751, 1024, 9152, 2140, 1010, 11307, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2034, 1035, 3931, 1027, 2862, 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...
jeremytregunna/ruby-trello
lib/trello/card.rb
Trello.Card.add_label
def add_label(label) unless label.valid? errors.add(:label, "is not valid.") return Trello.logger.warn "Label is not valid." unless label.valid? end client.post("/cards/#{id}/idLabels", {value: label.id}) end
ruby
def add_label(label) unless label.valid? errors.add(:label, "is not valid.") return Trello.logger.warn "Label is not valid." unless label.valid? end client.post("/cards/#{id}/idLabels", {value: label.id}) end
[ "def", "add_label", "(", "label", ")", "unless", "label", ".", "valid?", "errors", ".", "add", "(", ":label", ",", "\"is not valid.\"", ")", "return", "Trello", ".", "logger", ".", "warn", "\"Label is not valid.\"", "unless", "label", ".", "valid?", "end", "...
Add a label
[ "Add", "a", "label" ]
ad79c9d8152ad5395b3b61c43170908f1912bfb2
https://github.com/jeremytregunna/ruby-trello/blob/ad79c9d8152ad5395b3b61c43170908f1912bfb2/lib/trello/card.rb#L403-L409
train
Add a label to the card
[ 30522, 13366, 5587, 1035, 3830, 1006, 3830, 1007, 4983, 3830, 1012, 9398, 1029, 10697, 1012, 5587, 1006, 1024, 3830, 1010, 1000, 2003, 2025, 9398, 1012, 1000, 1007, 2709, 29461, 7174, 1012, 8833, 4590, 1012, 11582, 1000, 3830, 2003, 2025, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/fileparsing.rb
Puppet::Util::FileParsing.FileRecord.join
def join(details) joinchar = self.joiner fields.collect { |field| # If the field is marked absent, use the appropriate replacement if details[field] == :absent or details[field] == [:absent] or details[field].nil? if self.optional.include?(field) self.absent ...
ruby
def join(details) joinchar = self.joiner fields.collect { |field| # If the field is marked absent, use the appropriate replacement if details[field] == :absent or details[field] == [:absent] or details[field].nil? if self.optional.include?(field) self.absent ...
[ "def", "join", "(", "details", ")", "joinchar", "=", "self", ".", "joiner", "fields", ".", "collect", "{", "|", "field", "|", "# If the field is marked absent, use the appropriate replacement", "if", "details", "[", "field", "]", "==", ":absent", "or", "details", ...
Convert a record into a line by joining the fields together appropriately. This is pulled into a separate method so it can be called by the hooks.
[ "Convert", "a", "record", "into", "a", "line", "by", "joining", "the", "fields", "together", "appropriately", ".", "This", "is", "pulled", "into", "a", "separate", "method", "so", "it", "can", "be", "called", "by", "the", "hooks", "." ]
4baeed97cbb7571ddc6635f0a24debe2e8b22cd3
https://github.com/puppetlabs/puppet/blob/4baeed97cbb7571ddc6635f0a24debe2e8b22cd3/lib/puppet/util/fileparsing.rb#L102-L117
train
Returns a string containing the fields that are required to be joined.
[ 30522, 13366, 3693, 1006, 4751, 1007, 3693, 7507, 2099, 1027, 2969, 1012, 3693, 2121, 4249, 1012, 8145, 1063, 1064, 2492, 1064, 1001, 2065, 1996, 2492, 2003, 4417, 9962, 1010, 2224, 1996, 6413, 6110, 2065, 4751, 1031, 2492, 1033, 1027, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_search/lib/2015-08-19/generated/azure_mgmt_search/services.rb
Azure::Search::Mgmt::V2015_08_19.Services.delete
def delete(resource_group_name, search_service_name, search_management_request_options:nil, custom_headers:nil) response = delete_async(resource_group_name, search_service_name, search_management_request_options:search_management_request_options, custom_headers:custom_headers).value! nil end
ruby
def delete(resource_group_name, search_service_name, search_management_request_options:nil, custom_headers:nil) response = delete_async(resource_group_name, search_service_name, search_management_request_options:search_management_request_options, custom_headers:custom_headers).value! nil end
[ "def", "delete", "(", "resource_group_name", ",", "search_service_name", ",", "search_management_request_options", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "delete_async", "(", "resource_group_name", ",", "search_service_name", ",", "search_m...
Deletes a Search service in the given resource group, along with its associated resources. @param resource_group_name [String] The name of the resource group within the current subscription. You can obtain this value from the Azure Resource Manager API or the portal. @param search_service_name [String] The name o...
[ "Deletes", "a", "Search", "service", "in", "the", "given", "resource", "group", "along", "with", "its", "associated", "resources", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_search/lib/2015-08-19/generated/azure_mgmt_search/services.rb#L345-L348
train
Deletes a search service.
[ 30522, 13366, 3972, 12870, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3945, 1035, 2326, 1035, 2171, 1010, 3945, 1035, 2968, 1035, 5227, 1035, 7047, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 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...
aws/aws-sdk-ruby
gems/aws-sdk-rds/lib/aws-sdk-rds/db_snapshot.rb
Aws::RDS.DBSnapshot.copy
def copy(options = {}) options = options.merge(source_db_snapshot_identifier: @snapshot_id) resp = @client.copy_db_snapshot(options) DBSnapshot.new( instance_id: resp.data.db_snapshot.db_instance_identifier, snapshot_id: resp.data.db_snapshot.db_snapshot_identifier, data: resp....
ruby
def copy(options = {}) options = options.merge(source_db_snapshot_identifier: @snapshot_id) resp = @client.copy_db_snapshot(options) DBSnapshot.new( instance_id: resp.data.db_snapshot.db_instance_identifier, snapshot_id: resp.data.db_snapshot.db_snapshot_identifier, data: resp....
[ "def", "copy", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "source_db_snapshot_identifier", ":", "@snapshot_id", ")", "resp", "=", "@client", ".", "copy_db_snapshot", "(", "options", ")", "DBSnapshot", ".", "new", "(", ...
@example Request syntax with placeholder values dbsnapshot = db_snapshot.copy({ target_db_snapshot_identifier: "String", # required kms_key_id: "String", tags: [ { key: "String", value: "String", }, ], copy_tags: false, pre_signed_url: "String", opt...
[ "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-rds/lib/aws-sdk-rds/db_snapshot.rb#L508-L517
train
Copy the snapshot to the current DB instance
[ 30522, 13366, 6100, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 3120, 1035, 16962, 1035, 20057, 12326, 1035, 8909, 4765, 18095, 1024, 1030, 20057, 12326, 1035, 8909, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 61...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/rpc_server.rb
GRPC.RpcServer.run_till_terminated_or_interrupted
def run_till_terminated_or_interrupted(signals, wait_interval = 60) @stop_server = false @stop_server_mu = Mutex.new @stop_server_cv = ConditionVariable.new @stop_server_thread = Thread.new do loop do break if @stop_server @stop_server_mu.synchronize do @...
ruby
def run_till_terminated_or_interrupted(signals, wait_interval = 60) @stop_server = false @stop_server_mu = Mutex.new @stop_server_cv = ConditionVariable.new @stop_server_thread = Thread.new do loop do break if @stop_server @stop_server_mu.synchronize do @...
[ "def", "run_till_terminated_or_interrupted", "(", "signals", ",", "wait_interval", "=", "60", ")", "@stop_server", "=", "false", "@stop_server_mu", "=", "Mutex", ".", "new", "@stop_server_cv", "=", "ConditionVariable", ".", "new", "@stop_server_thread", "=", "Thread",...
runs the server with signal handlers @param signals List of String, Integer or both representing signals that the user would like to send to the server for graceful shutdown @param wait_interval (optional) Integer seconds that user would like stop_server_thread to poll stop_server
[ "runs", "the", "server", "with", "signal", "handlers" ]
f3937f0e55227a4ef3a23f895d3b204a947610f8
https://github.com/grpc/grpc/blob/f3937f0e55227a4ef3a23f895d3b204a947610f8/src/ruby/lib/grpc/generic/rpc_server.rb#L371-L416
train
run the server until the server is terminated or interrupted or interrupted
[ 30522, 13366, 2448, 1035, 6229, 1035, 12527, 1035, 2030, 1035, 7153, 1006, 7755, 1010, 3524, 1035, 13483, 1027, 3438, 1007, 1030, 2644, 1035, 8241, 1027, 6270, 1030, 2644, 1035, 8241, 1035, 14163, 1027, 20101, 2595, 1012, 2047, 1030, 2644, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/rdoc/generators/puppet_generator.rb
Generators.PuppetGenerator.generate_class_list
def generate_class_list(classes, modules, from, html_file, class_dir) if from.is_module? and !@modules.has_key?(from.name) k = HTMLPuppetModule.new(from, html_file, class_dir, @options) classes << k @modules[from.name] = k modules << @modules[from.name] elsif from.is_module? ...
ruby
def generate_class_list(classes, modules, from, html_file, class_dir) if from.is_module? and !@modules.has_key?(from.name) k = HTMLPuppetModule.new(from, html_file, class_dir, @options) classes << k @modules[from.name] = k modules << @modules[from.name] elsif from.is_module? ...
[ "def", "generate_class_list", "(", "classes", ",", "modules", ",", "from", ",", "html_file", ",", "class_dir", ")", "if", "from", ".", "is_module?", "and", "!", "@modules", ".", "has_key?", "(", "from", ".", "name", ")", "k", "=", "HTMLPuppetModule", ".", ...
produce a class/module list of HTMLPuppetModule/HTMLPuppetClass based on the code object traversal.
[ "produce", "a", "class", "/", "module", "list", "of", "HTMLPuppetModule", "/", "HTMLPuppetClass", "based", "on", "the", "code", "object", "traversal", "." ]
4baeed97cbb7571ddc6635f0a24debe2e8b22cd3
https://github.com/puppetlabs/puppet/blob/4baeed97cbb7571ddc6635f0a24debe2e8b22cd3/lib/puppet/util/rdoc/generators/puppet_generator.rb#L177-L192
train
Generate the class list for the given class from the given module.
[ 30522, 13366, 9699, 1035, 2465, 1035, 2862, 1006, 4280, 1010, 14184, 1010, 2013, 1010, 16129, 1035, 5371, 1010, 2465, 1035, 16101, 1007, 2065, 2013, 1012, 2003, 1035, 11336, 1029, 1998, 999, 1030, 14184, 1012, 2038, 1035, 3145, 1029, 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_compute/lib/2018-04-01/generated/azure_mgmt_compute/virtual_machine_extension_images.rb
Azure::Compute::Mgmt::V2018_04_01.VirtualMachineExtensionImages.list_versions
def list_versions(location, publisher_name, type, filter:nil, top:nil, orderby:nil, custom_headers:nil) response = list_versions_async(location, publisher_name, type, filter:filter, top:top, orderby:orderby, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_versions(location, publisher_name, type, filter:nil, top:nil, orderby:nil, custom_headers:nil) response = list_versions_async(location, publisher_name, type, filter:filter, top:top, orderby:orderby, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_versions", "(", "location", ",", "publisher_name", ",", "type", ",", "filter", ":", "nil", ",", "top", ":", "nil", ",", "orderby", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_versions_async", "(", "location", ","...
Gets a list of virtual machine extension image versions. @param location [String] The name of a supported Azure region. @param publisher_name [String] @param type [String] @param filter [String] The filter to apply on the operation. @param top [Integer] @param orderby [String] @param custom_headers [Hash{String...
[ "Gets", "a", "list", "of", "virtual", "machine", "extension", "image", "versions", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_compute/lib/2018-04-01/generated/azure_mgmt_compute/virtual_machine_extension_images.rb#L246-L249
train
Gets the list of versions of the specified type.
[ 30522, 13366, 2862, 1035, 4617, 1006, 3295, 1010, 6674, 1035, 2171, 1010, 2828, 1010, 11307, 1024, 9152, 2140, 1010, 2327, 1024, 9152, 2140, 1010, 2344, 3762, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/load_balancer_probes.rb
Azure::Network::Mgmt::V2018_07_01.LoadBalancerProbes.get_with_http_info
def get_with_http_info(resource_group_name, load_balancer_name, probe_name, custom_headers:nil) get_async(resource_group_name, load_balancer_name, probe_name, custom_headers:custom_headers).value! end
ruby
def get_with_http_info(resource_group_name, load_balancer_name, probe_name, custom_headers:nil) get_async(resource_group_name, load_balancer_name, probe_name, custom_headers:custom_headers).value! end
[ "def", "get_with_http_info", "(", "resource_group_name", ",", "load_balancer_name", ",", "probe_name", ",", "custom_headers", ":", "nil", ")", "get_async", "(", "resource_group_name", ",", "load_balancer_name", ",", "probe_name", ",", "custom_headers", ":custom_headers", ...
Gets load balancer probe. @param resource_group_name [String] The name of the resource group. @param load_balancer_name [String] The name of the load balancer. @param probe_name [String] The name of the probe. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP r...
[ "Gets", "load", "balancer", "probe", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-07-01/generated/azure_mgmt_network/load_balancer_probes.rb#L143-L145
train
Gets the specified load balancer probe.
[ 30522, 13366, 2131, 1035, 30524, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 7170, 1035, 5703, 2099, 1035, 2171, 1010, 15113, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 7661, 1035, 20346, 2015, 1007, 1012, 3643, 999, 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...
github-changelog-generator/github-changelog-generator
lib/github_changelog_generator/octo_fetcher.rb
GitHubChangelogGenerator.OctoFetcher.fetch_events_async
def fetch_events_async(issues) i = 0 threads = [] issues.each_slice(MAX_THREAD_NUMBER) do |issues_slice| issues_slice.each do |issue| threads << Thread.new do issue["events"] = [] iterate_pages(@client, "issue_events", issue["number"]) do |new_event| ...
ruby
def fetch_events_async(issues) i = 0 threads = [] issues.each_slice(MAX_THREAD_NUMBER) do |issues_slice| issues_slice.each do |issue| threads << Thread.new do issue["events"] = [] iterate_pages(@client, "issue_events", issue["number"]) do |new_event| ...
[ "def", "fetch_events_async", "(", "issues", ")", "i", "=", "0", "threads", "=", "[", "]", "issues", ".", "each_slice", "(", "MAX_THREAD_NUMBER", ")", "do", "|", "issues_slice", "|", "issues_slice", ".", "each", "do", "|", "issue", "|", "threads", "<<", "...
Fetch event for all issues and add them to 'events' @param [Array] issues @return [Void]
[ "Fetch", "event", "for", "all", "issues", "and", "add", "them", "to", "events" ]
f18c64b5cc0d7473b059275b88385ac11ca8b564
https://github.com/github-changelog-generator/github-changelog-generator/blob/f18c64b5cc0d7473b059275b88385ac11ca8b564/lib/github_changelog_generator/octo_fetcher.rb#L187-L211
train
Fetch events for issues and PR
[ 30522, 13366, 18584, 1035, 2824, 1035, 2004, 6038, 2278, 1006, 3314, 1007, 1045, 1027, 1014, 16457, 1027, 1031, 1033, 3314, 1012, 2169, 1035, 14704, 1006, 4098, 1035, 11689, 1035, 2193, 1007, 2079, 1064, 3314, 1035, 14704, 1064, 3314, 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...
sds/overcommit
lib/overcommit/hook_context/pre_commit.rb
Overcommit::HookContext.PreCommit.restore_working_tree
def restore_working_tree result = Overcommit::Utils.execute(%w[git stash pop --index --quiet]) unless result.success? raise Overcommit::Exceptions::HookCleanupFailed, "Unable to restore working tree after #{hook_script_name} hooks run:" \ "\nSTDOUT:#{result.stdout}\nSTDER...
ruby
def restore_working_tree result = Overcommit::Utils.execute(%w[git stash pop --index --quiet]) unless result.success? raise Overcommit::Exceptions::HookCleanupFailed, "Unable to restore working tree after #{hook_script_name} hooks run:" \ "\nSTDOUT:#{result.stdout}\nSTDER...
[ "def", "restore_working_tree", "result", "=", "Overcommit", "::", "Utils", ".", "execute", "(", "%w[", "git", "stash", "pop", "--index", "--quiet", "]", ")", "unless", "result", ".", "success?", "raise", "Overcommit", "::", "Exceptions", "::", "HookCleanupFailed...
Applies the stash to the working tree to restore the user's state.
[ "Applies", "the", "stash", "to", "the", "working", "tree", "to", "restore", "the", "user", "s", "state", "." ]
35d60adb41da942178b789560968e3ad030b0ac7
https://github.com/sds/overcommit/blob/35d60adb41da942178b789560968e3ad030b0ac7/lib/overcommit/hook_context/pre_commit.rb#L163-L170
train
Restore the working tree from the working tree.
[ 30522, 13366, 9239, 1035, 2551, 1035, 3392, 2765, 1027, 2058, 9006, 22930, 1024, 1024, 21183, 12146, 1012, 15389, 1006, 1003, 1059, 1031, 21025, 2102, 2358, 11823, 3769, 1011, 1011, 5950, 1011, 1011, 4251, 1033, 1007, 4983, 2765, 1012, 3112...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
activeadmin/arbre
lib/arbre/element.rb
Arbre.Element.method_missing
def method_missing(name, *args, &block) if current_arbre_element.respond_to?(name) current_arbre_element.send name, *args, &block elsif assigns && assigns.has_key?(name) assigns[name] elsif helpers.respond_to?(name) helpers.send(name, *args, &block) else super ...
ruby
def method_missing(name, *args, &block) if current_arbre_element.respond_to?(name) current_arbre_element.send name, *args, &block elsif assigns && assigns.has_key?(name) assigns[name] elsif helpers.respond_to?(name) helpers.send(name, *args, &block) else super ...
[ "def", "method_missing", "(", "name", ",", "*", "args", ",", "&", "block", ")", "if", "current_arbre_element", ".", "respond_to?", "(", "name", ")", "current_arbre_element", ".", "send", "name", ",", "args", ",", "block", "elsif", "assigns", "&&", "assigns",...
Implements the method lookup chain. When you call a method that doesn't exist, we: 1. Try to call the method on the current DOM context 2. Return an assigned variable of the same name 3. Call the method on the helper object 4. Call super
[ "Implements", "the", "method", "lookup", "chain", ".", "When", "you", "call", "a", "method", "that", "doesn", "t", "exist", "we", ":" ]
8621789d2f3fcc8b92ca11cdded6383bba6fcf55
https://github.com/activeadmin/arbre/blob/8621789d2f3fcc8b92ca11cdded6383bba6fcf55/lib/arbre/element.rb#L175-L185
train
This method is called by the XMLParser class.
[ 30522, 13366, 4118, 1035, 4394, 1006, 2171, 1010, 1008, 12098, 5620, 1010, 1004, 3796, 1007, 2065, 2783, 1035, 12098, 13578, 1035, 5783, 1012, 6869, 1035, 2000, 1029, 1006, 2171, 1007, 2783, 1035, 12098, 13578, 1035, 5783, 1012, 4604, 2171,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/scss-lint
lib/scss_lint/linter/space_after_comma.rb
SCSSLint.Linter::SpaceAfterComma.find_comma_position
def find_comma_position(arg) # rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity offset = 0 pos = arg.source_range.end_pos if character_at(pos, offset) != ',' loop do offset += 1 break if (right_char = character_at(pos, offset)) == ',' offset = -offse...
ruby
def find_comma_position(arg) # rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity offset = 0 pos = arg.source_range.end_pos if character_at(pos, offset) != ',' loop do offset += 1 break if (right_char = character_at(pos, offset)) == ',' offset = -offse...
[ "def", "find_comma_position", "(", "arg", ")", "# rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity", "offset", "=", "0", "pos", "=", "arg", ".", "source_range", ".", "end_pos", "if", "character_at", "(", "pos", ",", "offset", ")", "!=", "','", "loop", ...
Find the comma following this argument. The Sass parser is unpredictable in where it marks the end of the source range. Thus we need to start at the indicated range, and check left and right of that range, gradually moving further outward until we find the comma.
[ "Find", "the", "comma", "following", "this", "argument", "." ]
e99afe4ede041a431a06e585c12ce82f6ad50116
https://github.com/sds/scss-lint/blob/e99afe4ede041a431a06e585c12ce82f6ad50116/lib/scss_lint/linter/space_after_comma.rb#L103-L123
train
Find the first comma character in the argument
[ 30522, 13366, 2424, 1035, 4012, 2863, 30524, 1024, 4487, 19150, 12046, 2015, 1013, 5925, 5332, 4371, 1010, 12046, 2015, 1013, 22330, 20464, 9626, 4588, 9006, 19386, 3012, 16396, 1027, 1014, 13433, 2015, 1027, 12098, 2290, 1012, 3120, 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...
appium/ruby_lib
lib/appium_lib/ios/common/helper.rb
Appium.Ios.page
def page(opts = {}) class_name = opts.is_a?(Hash) ? opts.fetch(:class, nil) : opts source = get_source # current_context may be nil which breaks start_with if current_context && current_context.start_with?('WEBVIEW') parser = @android_html_parser ||= Nokogiri::HTML::SAX::Parser.new(App...
ruby
def page(opts = {}) class_name = opts.is_a?(Hash) ? opts.fetch(:class, nil) : opts source = get_source # current_context may be nil which breaks start_with if current_context && current_context.start_with?('WEBVIEW') parser = @android_html_parser ||= Nokogiri::HTML::SAX::Parser.new(App...
[ "def", "page", "(", "opts", "=", "{", "}", ")", "class_name", "=", "opts", ".", "is_a?", "(", "Hash", ")", "?", "opts", ".", "fetch", "(", ":class", ",", "nil", ")", ":", "opts", "source", "=", "get_source", "# current_context may be nil which breaks start...
Prints a string of interesting elements to the console. @example ```ruby page class: :UIAButton # filter on buttons page class: :UIAButton, window: 1 ``` @option visible [Symbol] visible value to filter on @option class [Symbol] class name to filter on @return [void]
[ "Prints", "a", "string", "of", "interesting", "elements", "to", "the", "console", "." ]
1f5898400dd1928bfe42ddd5f842d1f8738f2f76
https://github.com/appium/ruby_lib/blob/1f5898400dd1928bfe42ddd5f842d1f8738f2f76/lib/appium_lib/ios/common/helper.rb#L73-L95
train
Returns the page object for the current context.
[ 30522, 13366, 3931, 1006, 23569, 2015, 1027, 1063, 1065, 1007, 2465, 1035, 2171, 1027, 23569, 2015, 1012, 2003, 1035, 1037, 1029, 1006, 23325, 1007, 1029, 23569, 2015, 1012, 18584, 1006, 1024, 2465, 1010, 9152, 2140, 1007, 1024, 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...
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_application_type_info_list_with_http_info
def get_application_type_info_list_with_http_info(application_type_definition_kind_filter:0, exclude_application_parameters:false, continuation_token:nil, max_results:0, timeout:60, custom_headers:nil) get_application_type_info_list_async(application_type_definition_kind_filter:application_type_definition_kind_fi...
ruby
def get_application_type_info_list_with_http_info(application_type_definition_kind_filter:0, exclude_application_parameters:false, continuation_token:nil, max_results:0, timeout:60, custom_headers:nil) get_application_type_info_list_async(application_type_definition_kind_filter:application_type_definition_kind_fi...
[ "def", "get_application_type_info_list_with_http_info", "(", "application_type_definition_kind_filter", ":", "0", ",", "exclude_application_parameters", ":", "false", ",", "continuation_token", ":", "nil", ",", "max_results", ":", "0", ",", "timeout", ":", "60", ",", "c...
Gets the list of application types in the Service Fabric cluster. Returns the information about the application types that are provisioned or in the process of being provisioned in the Service Fabric cluster. Each version of an application type is returned as one application type. The response includes the name, v...
[ "Gets", "the", "list", "of", "application", "types", "in", "the", "Service", "Fabric", "cluster", "." ]
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#L4738-L4740
train
Gets the list of all the applications of the specified type.
[ 30522, 13366, 2131, 1035, 4646, 1035, 2828, 1035, 18558, 1035, 2862, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 4646, 1035, 2828, 1035, 6210, 1035, 2785, 1035, 11307, 1024, 1014, 1010, 23329, 1035, 4646, 1035, 11709, 1024, 6270, 1010, 13633...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.resume_service_backup
def resume_service_backup(service_id, timeout:60, custom_headers:nil) response = resume_service_backup_async(service_id, timeout:timeout, custom_headers:custom_headers).value! nil end
ruby
def resume_service_backup(service_id, timeout:60, custom_headers:nil) response = resume_service_backup_async(service_id, timeout:timeout, custom_headers:custom_headers).value! nil end
[ "def", "resume_service_backup", "(", "service_id", ",", "timeout", ":", "60", ",", "custom_headers", ":", "nil", ")", "response", "=", "resume_service_backup_async", "(", "service_id", ",", "timeout", ":", "timeout", ",", "custom_headers", ":custom_headers", ")", ...
Resumes periodic backup of a Service Fabric service which was previously suspended. The previously suspended Service Fabric service resumes taking periodic backup as per the backup policy currently configured for the same. @param service_id [String] The identity of the service. This is typically the full name of...
[ "Resumes", "periodic", "backup", "of", "a", "Service", "Fabric", "service", "which", "was", "previously", "suspended", "." ]
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#L24610-L24613
train
Resumes a service backup of a service.
[ 30522, 13366, 13746, 1035, 2326, 1035, 10200, 1006, 2326, 1035, 8909, 1010, 2051, 5833, 1024, 3438, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 13746, 1035, 2326, 1035, 10200, 1035, 2004, 6038, 2278, 1006, 2326, 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_recovery_services_site_recovery/lib/2018-01-10/generated/azure_mgmt_recovery_services_site_recovery/replication_recovery_plans.rb
Azure::RecoveryServicesSiteRecovery::Mgmt::V2018_01_10.ReplicationRecoveryPlans.failover_commit_async
def failover_commit_async(recovery_plan_name, custom_headers:nil) # Send request promise = begin_failover_commit_async(recovery_plan_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_resp...
ruby
def failover_commit_async(recovery_plan_name, custom_headers:nil) # Send request promise = begin_failover_commit_async(recovery_plan_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_resp...
[ "def", "failover_commit_async", "(", "recovery_plan_name", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_failover_commit_async", "(", "recovery_plan_name", ",", "custom_headers", ":custom_headers", ")", "promise", "=", "promise", ".", ...
@param recovery_plan_name [String] Recovery plan name. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [Concurrent::Promise] promise which provides async access to http response.
[ "@param", "recovery_plan_name", "[", "String", "]", "Recovery", "plan", "name", ".", "@param", "custom_headers", "[", "Hash", "{", "String", "=", ">", "String", "}", "]", "A", "hash", "of", "custom", "headers", "that", "will", "be", "added", "to", "the", ...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_recovery_services_site_recovery/lib/2018-01-10/generated/azure_mgmt_recovery_services_site_recovery/replication_recovery_plans.rb#L362-L378
train
Gets the current state of a recovery plan failover commit.
[ 30522, 13366, 8246, 7840, 1035, 10797, 1035, 2004, 6038, 2278, 1006, 7233, 1035, 2933, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 1001, 4604, 5227, 4872, 1027, 4088, 1035, 30524, 7233, 1035, 2933, 1035, 2171, 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...
mongodb/mongo-ruby-driver
lib/mongo/client.rb
Mongo.Client.list_databases
def list_databases(filter = {}, name_only = false, opts = {}) cmd = { listDatabases: 1 } cmd[:nameOnly] = !!name_only cmd[:filter] = filter unless filter.empty? use(Database::ADMIN).command(cmd, opts).first[Database::DATABASES] end
ruby
def list_databases(filter = {}, name_only = false, opts = {}) cmd = { listDatabases: 1 } cmd[:nameOnly] = !!name_only cmd[:filter] = filter unless filter.empty? use(Database::ADMIN).command(cmd, opts).first[Database::DATABASES] end
[ "def", "list_databases", "(", "filter", "=", "{", "}", ",", "name_only", "=", "false", ",", "opts", "=", "{", "}", ")", "cmd", "=", "{", "listDatabases", ":", "1", "}", "cmd", "[", ":nameOnly", "]", "=", "!", "!", "name_only", "cmd", "[", ":filter"...
Get info for each database. @example Get the info for each database. client.list_databases @param [ Hash ] filter The filter criteria for getting a list of databases. @param [ true, false ] name_only Whether to only return each database name without full metadata. @param [ Hash ] opts The command options. @r...
[ "Get", "info", "for", "each", "database", "." ]
dca26d0870cb3386fad9ccc1d17228097c1fe1c8
https://github.com/mongodb/mongo-ruby-driver/blob/dca26d0870cb3386fad9ccc1d17228097c1fe1c8/lib/mongo/client.rb#L611-L616
train
List all databases
[ 30522, 13366, 2862, 1035, 17881, 1006, 11307, 1027, 1063, 1065, 1010, 2171, 1035, 2069, 1027, 6270, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 4642, 2094, 1027, 1063, 2862, 2850, 2696, 15058, 2015, 1024, 1015, 1065, 4642, 2094, 1031, 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/2014-04-01/generated/azure_mgmt_sql/replication_links.rb
Azure::SQL::Mgmt::V2014_04_01.ReplicationLinks.begin_failover
def begin_failover(resource_group_name, server_name, database_name, link_id, custom_headers:nil) response = begin_failover_async(resource_group_name, server_name, database_name, link_id, custom_headers:custom_headers).value! nil end
ruby
def begin_failover(resource_group_name, server_name, database_name, link_id, custom_headers:nil) response = begin_failover_async(resource_group_name, server_name, database_name, link_id, custom_headers:custom_headers).value! nil end
[ "def", "begin_failover", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",", "link_id", ",", "custom_headers", ":", "nil", ")", "response", "=", "begin_failover_async", "(", "resource_group_name", ",", "server_name", ",", "database_name", ",", ...
Sets which replica database is primary by failing over from the current primary replica database. @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 ...
[ "Sets", "which", "replica", "database", "is", "primary", "by", "failing", "over", "from", "the", "current", "primary", "replica", "database", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_sql/lib/2014-04-01/generated/azure_mgmt_sql/replication_links.rb#L446-L449
train
Gets the index of the elastic network link that is failing over.
[ 30522, 13366, 4088, 1035, 8246, 7840, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8241, 1035, 2171, 1010, 7809, 1035, 2171, 1010, 4957, 1035, 8909, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 4088, 1035, 8246, 7840, 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...
decidim/decidim
decidim-core/lib/decidim/content_block_registry.rb
Decidim.ContentBlockRegistry.register
def register(scope, name) scope = scope.to_s block_exists = content_blocks[scope].any? { |content_block| content_block.name == name } if block_exists raise( ContentBlockAlreadyRegistered, "There's a content block already registered with the name `:#{name}` for the scope `:...
ruby
def register(scope, name) scope = scope.to_s block_exists = content_blocks[scope].any? { |content_block| content_block.name == name } if block_exists raise( ContentBlockAlreadyRegistered, "There's a content block already registered with the name `:#{name}` for the scope `:...
[ "def", "register", "(", "scope", ",", "name", ")", "scope", "=", "scope", ".", "to_s", "block_exists", "=", "content_blocks", "[", "scope", "]", ".", "any?", "{", "|", "content_block", "|", "content_block", ".", "name", "==", "name", "}", "if", "block_ex...
Public: Registers a content block for the home page. scope - a symbol or string representing the scope of the content block. Will be persisted as a string. name - a symbol representing the name of the content block &block - The content block definition. Returns nothing. Raises an error if there's already...
[ "Public", ":", "Registers", "a", "content", "block", "for", "the", "home", "page", "." ]
6e2b14e559a63088669904e3c5c49a5180700cf7
https://github.com/decidim/decidim/blob/6e2b14e559a63088669904e3c5c49a5180700cf7/decidim-core/lib/decidim/content_block_registry.rb#L52-L69
train
Register a content block with the given scope.
[ 30522, 13366, 4236, 1006, 9531, 1010, 2171, 1007, 9531, 1027, 9531, 1012, 2000, 1035, 1055, 3796, 1035, 6526, 1027, 4180, 1035, 5991, 1031, 9531, 1033, 1012, 2151, 1029, 1063, 1064, 30524, 1065, 1036, 2005, 1996, 9531, 1036, 1024, 1001, 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_sql/lib/2014-04-01/generated/azure_mgmt_sql/firewall_rules.rb
Azure::SQL::Mgmt::V2014_04_01.FirewallRules.delete_with_http_info
def delete_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers:nil) delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value! end
ruby
def delete_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers:nil) delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value! end
[ "def", "delete_with_http_info", "(", "resource_group_name", ",", "server_name", ",", "firewall_rule_name", ",", "custom_headers", ":", "nil", ")", "delete_async", "(", "resource_group_name", ",", "server_name", ",", "firewall_rule_name", ",", "custom_headers", ":custom_he...
Deletes 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....
[ "Deletes", "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#L183-L185
train
Deletes the specified firewall rule from the specified server.
[ 30522, 13366, 3972, 12870, 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, 3972, 12870, 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_api_management/lib/2018-01-01/generated/azure_mgmt_api_management/api_release.rb
Azure::ApiManagement::Mgmt::V2018_01_01.ApiRelease.create_with_http_info
def create_with_http_info(resource_group_name, service_name, api_id, release_id, parameters, custom_headers:nil) create_async(resource_group_name, service_name, api_id, release_id, parameters, custom_headers:custom_headers).value! end
ruby
def create_with_http_info(resource_group_name, service_name, api_id, release_id, parameters, custom_headers:nil) create_async(resource_group_name, service_name, api_id, release_id, parameters, custom_headers:custom_headers).value! end
[ "def", "create_with_http_info", "(", "resource_group_name", ",", "service_name", ",", "api_id", ",", "release_id", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "create_async", "(", "resource_group_name", ",", "service_name", ",", "api_id", ",", "releas...
Creates a new Release for the API. @param resource_group_name [String] The name of the resource group. @param service_name [String] The name of the API Management service. @param api_id [String] API identifier. Must be unique in the current API Management service instance. @param release_id [String] Release ident...
[ "Creates", "a", "new", "Release", "for", "the", "API", "." ]
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/api_release.rb#L418-L420
train
Creates a new chunk of a chunk of a chunk of the image.
[ 30522, 13366, 3443, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2326, 1035, 2171, 1010, 17928, 1035, 8909, 1010, 2713, 1035, 8909, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3443, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/2017-04-02/generated/azure_mgmt_cdn/endpoints.rb
Azure::CDN::Mgmt::V2017_04_02.Endpoints.load_content
def load_content(resource_group_name, profile_name, endpoint_name, content_file_paths, custom_headers:nil) response = load_content_async(resource_group_name, profile_name, endpoint_name, content_file_paths, custom_headers:custom_headers).value! nil end
ruby
def load_content(resource_group_name, profile_name, endpoint_name, content_file_paths, custom_headers:nil) response = load_content_async(resource_group_name, profile_name, endpoint_name, content_file_paths, custom_headers:custom_headers).value! nil end
[ "def", "load_content", "(", "resource_group_name", ",", "profile_name", ",", "endpoint_name", ",", "content_file_paths", ",", "custom_headers", ":", "nil", ")", "response", "=", "load_content_async", "(", "resource_group_name", ",", "profile_name", ",", "endpoint_name",...
Pre-loads a content to CDN. Available for Verizon Profiles. @param resource_group_name [String] Name of the Resource group within the Azure subscription. @param profile_name [String] Name of the CDN profile which is unique within the resource group. @param endpoint_name [String] Name of the endpoint under the pro...
[ "Pre", "-", "loads", "a", "content", "to", "CDN", ".", "Available", "for", "Verizon", "Profiles", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_cdn/lib/2017-04-02/generated/azure_mgmt_cdn/endpoints.rb#L565-L568
train
Loads the content of the specified endpoint.
[ 30522, 13366, 7170, 1035, 4180, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 6337, 1035, 2171, 1010, 2203, 8400, 1035, 2171, 1010, 4180, 1035, 5371, 1035, 10425, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 7170, 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...
watir/watir
lib/watir/elements/select.rb
Watir.Select.select!
def select!(*str_or_rx) results = str_or_rx.flatten.map { |v| select_by!(v, :single) } results.first end
ruby
def select!(*str_or_rx) results = str_or_rx.flatten.map { |v| select_by!(v, :single) } results.first end
[ "def", "select!", "(", "*", "str_or_rx", ")", "results", "=", "str_or_rx", ".", "flatten", ".", "map", "{", "|", "v", "|", "select_by!", "(", "v", ",", ":single", ")", "}", "results", ".", "first", "end" ]
Uses JavaScript to select the option whose text matches the given string. @param [String, Regexp] str_or_rx @raise [Watir::Exception::NoValueFoundException] if the value does not exist.
[ "Uses", "JavaScript", "to", "select", "the", "option", "whose", "text", "matches", "the", "given", "string", "." ]
2d8db09811c6221ae401b85b2f61f5fa66e463a3
https://github.com/watir/watir/blob/2d8db09811c6221ae401b85b2f61f5fa66e463a3/lib/watir/elements/select.rb#L57-L60
train
Select the first element of the list
[ 30522, 13366, 7276, 999, 1006, 1008, 2358, 2099, 1035, 2030, 1035, 1054, 2595, 1007, 3463, 1027, 2358, 2099, 1035, 2030, 1035, 1054, 2595, 1012, 4257, 6528, 1012, 4949, 1063, 1064, 1058, 1064, 7276, 1035, 2011, 999, 1006, 1058, 1010, 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_advisor/lib/2017-03-31/generated/azure_mgmt_advisor/suppressions.rb
Azure::Advisor::Mgmt::V2017_03_31.Suppressions.create_with_http_info
def create_with_http_info(resource_uri, recommendation_id, name, suppression_contract, custom_headers:nil) create_async(resource_uri, recommendation_id, name, suppression_contract, custom_headers:custom_headers).value! end
ruby
def create_with_http_info(resource_uri, recommendation_id, name, suppression_contract, custom_headers:nil) create_async(resource_uri, recommendation_id, name, suppression_contract, custom_headers:custom_headers).value! end
[ "def", "create_with_http_info", "(", "resource_uri", ",", "recommendation_id", ",", "name", ",", "suppression_contract", ",", "custom_headers", ":", "nil", ")", "create_async", "(", "resource_uri", ",", "recommendation_id", ",", "name", ",", "suppression_contract", ",...
Enables the snoozed or dismissed attribute of a recommendation. The snoozed or dismissed attribute is referred to as a suppression. Use this API to create or update the snoozed or dismissed status of a recommendation. @param resource_uri [String] The fully qualified Azure Resource Manager identifier of the resourc...
[ "Enables", "the", "snoozed", "or", "dismissed", "attribute", "of", "a", "recommendation", ".", "The", "snoozed", "or", "dismissed", "attribute", "is", "referred", "to", "as", "a", "suppression", ".", "Use", "this", "API", "to", "create", "or", "update", "the...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_advisor/lib/2017-03-31/generated/azure_mgmt_advisor/suppressions.rb#L159-L161
train
Creates a new Central Season.
[ 30522, 13366, 3443, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 24471, 30524, 2171, 1010, 16341, 1035, 3206, 1010, 7661, 1035, 20346, 2015, 1024, 7661, 1035, 20346, 2015, 1007, 1012, 3643, 999, 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...
piotrmurach/github
lib/github_api/client/users/followers.rb
Github.Client::Users::Followers.following?
def following?(*args) arguments(args, required: [:username]) params = arguments.params if target_user = params.delete('target_user') get_request("/users/#{arguments.username}/following/#{target_user}", params) else get_request("/user/following/#{arguments.username}", params) ...
ruby
def following?(*args) arguments(args, required: [:username]) params = arguments.params if target_user = params.delete('target_user') get_request("/users/#{arguments.username}/following/#{target_user}", params) else get_request("/user/following/#{arguments.username}", params) ...
[ "def", "following?", "(", "*", "args", ")", "arguments", "(", "args", ",", "required", ":", "[", ":username", "]", ")", "params", "=", "arguments", ".", "params", "if", "target_user", "=", "params", ".", "delete", "(", "'target_user'", ")", "get_request", ...
Check if you are following a user @example github = Github.new oauth_token: '...' github.users.followers.following? 'user-name' github.users.followers.following? username: 'user-name' Check if one user follows another @example github = Github.new oauth_token: '...' github.users.followers.following?...
[ "Check", "if", "you", "are", "following", "a", "user" ]
8702452c66bea33c9388550aed9e9974f76aaef1
https://github.com/piotrmurach/github/blob/8702452c66bea33c9388550aed9e9974f76aaef1/lib/github_api/client/users/followers.rb#L77-L88
train
Get the following of a user
[ 30522, 13366, 2206, 1029, 1006, 1008, 12098, 5620, 1007, 9918, 1006, 12098, 5620, 1010, 3223, 1024, 1031, 1024, 5310, 18442, 1033, 1007, 11498, 5244, 1027, 9918, 1012, 11498, 5244, 2065, 4539, 1035, 5310, 1027, 11498, 5244, 1012, 3972, 1287...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/lib/2018-05-01/generated/azure_mgmt_resources/deployment_operations.rb
Azure::Resources::Mgmt::V2018_05_01.DeploymentOperations.list_at_subscription_scope_as_lazy
def list_at_subscription_scope_as_lazy(deployment_name, top:nil, custom_headers:nil) response = list_at_subscription_scope_async(deployment_name, top:top, custom_headers:custom_headers).value! unless response.nil? page = response.body page.next_method = Proc.new do |next_page_link| ...
ruby
def list_at_subscription_scope_as_lazy(deployment_name, top:nil, custom_headers:nil) response = list_at_subscription_scope_async(deployment_name, top:top, custom_headers:custom_headers).value! unless response.nil? page = response.body page.next_method = Proc.new do |next_page_link| ...
[ "def", "list_at_subscription_scope_as_lazy", "(", "deployment_name", ",", "top", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_at_subscription_scope_async", "(", "deployment_name", ",", "top", ":", "top", ",", "custom_headers", ":custom_he...
Gets all deployments operations for a deployment. @param deployment_name [String] The name of the deployment with the operation to get. @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 request. @return [D...
[ "Gets", "all", "deployments", "operations", "for", "a", "deployment", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_resources/lib/2018-05-01/generated/azure_mgmt_resources/deployment_operations.rb#L616-L625
train
Gets the list of all the managed managed
[ 30522, 13366, 2862, 1035, 2012, 1035, 15002, 1035, 9531, 1035, 2004, 1035, 13971, 1006, 10813, 1035, 2171, 1010, 2327, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 2012, 1035, 15002, 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...
meew0/discordrb
lib/discordrb/webhooks/embeds.rb
Discordrb::Webhooks.Embed.colour=
def colour=(value) if value.nil? @colour = nil elsif value.is_a? Integer raise ArgumentError, 'Embed colour must be 24-bit!' if value >= 16_777_216 @colour = value elsif value.is_a? String self.colour = value.delete('#').to_i(16) elsif value.is_a? Array r...
ruby
def colour=(value) if value.nil? @colour = nil elsif value.is_a? Integer raise ArgumentError, 'Embed colour must be 24-bit!' if value >= 16_777_216 @colour = value elsif value.is_a? String self.colour = value.delete('#').to_i(16) elsif value.is_a? Array r...
[ "def", "colour", "=", "(", "value", ")", "if", "value", ".", "nil?", "@colour", "=", "nil", "elsif", "value", ".", "is_a?", "Integer", "raise", "ArgumentError", ",", "'Embed colour must be 24-bit!'", "if", "value", ">=", "16_777_216", "@colour", "=", "value", ...
Sets the colour of the bar to the side of the embed to something new. @param value [Integer, String, {Integer, Integer, Integer}, #to_i, nil] The colour in decimal, hexadecimal, R/G/B decimal, or nil to clear the embeds colour form.
[ "Sets", "the", "colour", "of", "the", "bar", "to", "the", "side", "of", "the", "embed", "to", "something", "new", "." ]
764298a1ff0be69a1853b510d736f21c2b91a2fe
https://github.com/meew0/discordrb/blob/764298a1ff0be69a1853b510d736f21c2b91a2fe/lib/discordrb/webhooks/embeds.rb#L42-L58
train
Set the colour of the embed.
[ 30522, 13366, 6120, 1027, 1006, 3643, 1007, 2065, 3643, 1012, 9152, 30524, 9152, 2140, 3449, 5332, 2546, 3643, 1012, 2003, 1035, 1037, 1029, 16109, 5333, 6685, 2121, 29165, 1010, 1005, 7861, 8270, 6120, 2442, 2022, 2484, 1011, 2978, 999, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
petergoldstein/dalli
lib/dalli/client.rb
Dalli.Client.cas
def cas(key, ttl=nil, options=nil, &block) cas_core(key, false, ttl, options, &block) end
ruby
def cas(key, ttl=nil, options=nil, &block) cas_core(key, false, ttl, options, &block) end
[ "def", "cas", "(", "key", ",", "ttl", "=", "nil", ",", "options", "=", "nil", ",", "&", "block", ")", "cas_core", "(", "key", ",", "false", ",", "ttl", ",", "options", ",", "block", ")", "end" ]
compare and swap values using optimistic locking. Fetch the existing value for key. If it exists, yield the value to the block. Add the block's return value as the new value for the key. Add will fail if someone else changed the value. Returns: - nil if the key did not exist. - false if the value was changed by...
[ "compare", "and", "swap", "values", "using", "optimistic", "locking", ".", "Fetch", "the", "existing", "value", "for", "key", ".", "If", "it", "exists", "yield", "the", "value", "to", "the", "block", ".", "Add", "the", "block", "s", "return", "value", "a...
5755dbfd06e333a8239f976d4b10492b4555b726
https://github.com/petergoldstein/dalli/blob/5755dbfd06e333a8239f976d4b10492b4555b726/lib/dalli/client.rb#L114-L116
train
CAS the value at the given key.
[ 30522, 13366, 25222, 1006, 3145, 1010, 23746, 2140, 1027, 9152, 2140, 1010, 7047, 1027, 9152, 2140, 1010, 1004, 3796, 1007, 25222, 1035, 4563, 1006, 3145, 1010, 6270, 1010, 23746, 2140, 1010, 7047, 1010, 1004, 3796, 1007, 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...
chef/chef
chef-config/lib/chef-config/workstation_config_loader.rb
ChefConfig.WorkstationConfigLoader.apply_defaults
def apply_defaults # If we don't have a better guess use the username. Config[:node_name] ||= Etc.getlogin # If we don't have a key (path or inline) check user.pem and $node_name.pem. unless Config.key?(:client_key) || Config.key?(:client_key_contents) key_path = find_default_key(["#{Con...
ruby
def apply_defaults # If we don't have a better guess use the username. Config[:node_name] ||= Etc.getlogin # If we don't have a key (path or inline) check user.pem and $node_name.pem. unless Config.key?(:client_key) || Config.key?(:client_key_contents) key_path = find_default_key(["#{Con...
[ "def", "apply_defaults", "# If we don't have a better guess use the username.", "Config", "[", ":node_name", "]", "||=", "Etc", ".", "getlogin", "# If we don't have a key (path or inline) check user.pem and $node_name.pem.", "unless", "Config", ".", "key?", "(", ":client_key", ")...
Apply default configuration values for workstation-style tools. Global defaults should go in {ChefConfig::Config} instead, this is only for things like `knife` and `chef`. @api private @since 14.3 @return [void]
[ "Apply", "default", "configuration", "values", "for", "workstation", "-", "style", "tools", "." ]
61f69e18e69e0dca6e8cffdcd7451181d874cdb3
https://github.com/chef/chef/blob/61f69e18e69e0dca6e8cffdcd7451181d874cdb3/chef-config/lib/chef-config/workstation_config_loader.rb#L223-L237
train
Apply defaults to the current configuration
[ 30522, 13366, 6611, 1035, 12398, 2015, 1001, 2065, 2057, 2123, 1005, 1056, 2031, 1037, 2488, 3984, 2224, 1996, 5310, 18442, 1012, 9530, 8873, 2290, 1031, 1024, 13045, 1035, 2171, 1033, 1064, 1064, 1027, 4385, 1012, 2131, 21197, 2378, 1001, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_key_vault/lib/2016-10-01/generated/azure_key_vault/key_vault_client.rb
Azure::KeyVault::V2016_10_01.KeyVaultClient.recover_deleted_secret
def recover_deleted_secret(vault_base_url, secret_name, custom_headers:nil) response = recover_deleted_secret_async(vault_base_url, secret_name, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def recover_deleted_secret(vault_base_url, secret_name, custom_headers:nil) response = recover_deleted_secret_async(vault_base_url, secret_name, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "recover_deleted_secret", "(", "vault_base_url", ",", "secret_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "recover_deleted_secret_async", "(", "vault_base_url", ",", "secret_name", ",", "custom_headers", ":custom_headers", ")", ".", "value!", ...
Recovers the deleted secret to the latest version. Recovers the deleted secret in the specified vault. This operation can only be performed on a soft-delete enabled vault. This operation requires the secrets/recover permission. @param vault_base_url [String] The vault name, for example https://myvault.vault.azur...
[ "Recovers", "the", "deleted", "secret", "to", "the", "latest", "version", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_key_vault/lib/2016-10-01/generated/azure_key_vault/key_vault_client.rb#L3696-L3699
train
Recover the deleted secret.
[ 30522, 13366, 8980, 1035, 17159, 1035, 3595, 1006, 11632, 1035, 2918, 1035, 24471, 2140, 1010, 3595, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 8980, 1035, 17159, 1035, 3595, 1035, 2004, 6038, 2278, 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...
httprb/http
lib/http/connection.rb
HTTP.Connection.send_request
def send_request(req) raise StateError, "Tried to send a request while one is pending already. Make sure you read off the body." if @pending_response raise StateError, "Tried to send a request while a response is pending. Make sure you read off the body." if @pending_request @pending_request = true ...
ruby
def send_request(req) raise StateError, "Tried to send a request while one is pending already. Make sure you read off the body." if @pending_response raise StateError, "Tried to send a request while a response is pending. Make sure you read off the body." if @pending_request @pending_request = true ...
[ "def", "send_request", "(", "req", ")", "raise", "StateError", ",", "\"Tried to send a request while one is pending already. Make sure you read off the body.\"", "if", "@pending_response", "raise", "StateError", ",", "\"Tried to send a request while a response is pending. Make sure you r...
Send a request to the server @param [Request] req Request to send to the server @return [nil]
[ "Send", "a", "request", "to", "the", "server" ]
f37a10ea4fab3ee411907ea2e4251ddf0ca33a93
https://github.com/httprb/http/blob/f37a10ea4fab3ee411907ea2e4251ddf0ca33a93/lib/http/connection.rb#L70-L80
train
Send a request to the server.
[ 30522, 13366, 4604, 1035, 5227, 1006, 2128, 4160, 1007, 5333, 2110, 2121, 29165, 1010, 1000, 2699, 2000, 4604, 1037, 5227, 2096, 2028, 2003, 14223, 2525, 1012, 2191, 2469, 2017, 3191, 2125, 1996, 2303, 1012, 1000, 2065, 1030, 14223, 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...
decidim/decidim
decidim-core/app/models/decidim/content_block.rb
Decidim.ContentBlock.images_container
def images_container return @images_container if @images_container manifest = self.manifest @images_container = Class.new do extend ::CarrierWave::Mount include ActiveModel::Validations cattr_accessor :manifest, :manifest_scope attr_reader :content_block # Ne...
ruby
def images_container return @images_container if @images_container manifest = self.manifest @images_container = Class.new do extend ::CarrierWave::Mount include ActiveModel::Validations cattr_accessor :manifest, :manifest_scope attr_reader :content_block # Ne...
[ "def", "images_container", "return", "@images_container", "if", "@images_container", "manifest", "=", "self", ".", "manifest", "@images_container", "=", "Class", ".", "new", "do", "extend", "::", "CarrierWave", "::", "Mount", "include", "ActiveModel", "::", "Validat...
Public: Holds access to the images related to the content block. This method generates a dynamic class that encapsulates the uploaders for the content block images, and eases the access to them. It's a little bit hacky, but it's the only way I could come up with in order to let content block images have different u...
[ "Public", ":", "Holds", "access", "to", "the", "images", "related", "to", "the", "content", "block", ".", "This", "method", "generates", "a", "dynamic", "class", "that", "encapsulates", "the", "uploaders", "for", "the", "content", "block", "images", "and", "...
6e2b14e559a63088669904e3c5c49a5180700cf7
https://github.com/decidim/decidim/blob/6e2b14e559a63088669904e3c5c49a5180700cf7/decidim-core/app/models/decidim/content_block.rb#L67-L128
train
Creates a new images container.
[ 30522, 13366, 4871, 1035, 11661, 2709, 1030, 4871, 1035, 11661, 2065, 1030, 4871, 1035, 11661, 19676, 1027, 2969, 1012, 19676, 1030, 4871, 1035, 11661, 1027, 2465, 1012, 2047, 2079, 7949, 1024, 1024, 6839, 16535, 1024, 1024, 4057, 2421, 316...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.get_by_recommended_elastic_pool_with_http_info
def get_by_recommended_elastic_pool_with_http_info(resource_group_name, server_name, recommended_elastic_pool_name, database_name, custom_headers:nil) get_by_recommended_elastic_pool_async(resource_group_name, server_name, recommended_elastic_pool_name, database_name, custom_headers:custom_headers).value! end
ruby
def get_by_recommended_elastic_pool_with_http_info(resource_group_name, server_name, recommended_elastic_pool_name, database_name, custom_headers:nil) get_by_recommended_elastic_pool_async(resource_group_name, server_name, recommended_elastic_pool_name, database_name, custom_headers:custom_headers).value! end
[ "def", "get_by_recommended_elastic_pool_with_http_info", "(", "resource_group_name", ",", "server_name", ",", "recommended_elastic_pool_name", ",", "database_name", ",", "custom_headers", ":", "nil", ")", "get_by_recommended_elastic_pool_async", "(", "resource_group_name", ",", ...
Gets a database inside of a recommended elastic pool. @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 recommended_elastic_pool_name...
[ "Gets", "a", "database", "inside", "of", "a", "recommended", "elastic", "pool", "." ]
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#L785-L787
train
Gets the elastic pool.
[ 30522, 13366, 2131, 1035, 2011, 1035, 6749, 1035, 21274, 1035, 4770, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8241, 1035, 2171, 1010, 6749, 1035, 21274, 1035, 4770, 1035, 2171, 1010, 7809, 1035, 2171, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/workbook/worksheet/worksheet.rb
Axlsx.Worksheet.add_page_break
def add_page_break(cell) DataTypeValidator.validate :worksheet_page_break, [String, Cell], cell column_index, row_index = if cell.is_a?(String) Axlsx.name_to_indices(cell) else cell.pos end if column_index > 0 col_breaks.add_break(:id => column_index) ...
ruby
def add_page_break(cell) DataTypeValidator.validate :worksheet_page_break, [String, Cell], cell column_index, row_index = if cell.is_a?(String) Axlsx.name_to_indices(cell) else cell.pos end if column_index > 0 col_breaks.add_break(:id => column_index) ...
[ "def", "add_page_break", "(", "cell", ")", "DataTypeValidator", ".", "validate", ":worksheet_page_break", ",", "[", "String", ",", "Cell", "]", ",", "cell", "column_index", ",", "row_index", "=", "if", "cell", ".", "is_a?", "(", "String", ")", "Axlsx", ".", ...
Adds a page break (row break) to the worksheet @param cell A Cell object or excel style string reference indicating where the break should be added to the sheet. @example ws.add_page_break("A4")
[ "Adds", "a", "page", "break", "(", "row", "break", ")", "to", "the", "worksheet" ]
c593a08b2a929dac7aa8dc418b55e26b4c49dc34
https://github.com/randym/axlsx/blob/c593a08b2a929dac7aa8dc418b55e26b4c49dc34/lib/axlsx/workbook/worksheet/worksheet.rb#L495-L506
train
Add a page break to the worksheet
[ 30522, 13366, 5587, 1035, 3931, 1035, 3338, 1006, 3526, 1007, 2951, 13874, 10175, 8524, 4263, 1012, 9398, 3686, 1024, 2573, 21030, 2102, 1035, 3931, 1035, 3338, 1010, 1031, 5164, 1010, 3526, 1033, 1010, 3526, 5930, 1035, 5950, 1010, 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_relay/lib/2016-07-01/generated/azure_mgmt_relay/hybrid_connections.rb
Azure::Relay::Mgmt::V2016_07_01.HybridConnections.delete_authorization_rule_with_http_info
def delete_authorization_rule_with_http_info(resource_group_name, namespace_name, hybrid_connection_name, authorization_rule_name, custom_headers:nil) delete_authorization_rule_async(resource_group_name, namespace_name, hybrid_connection_name, authorization_rule_name, custom_headers:custom_headers).value! end
ruby
def delete_authorization_rule_with_http_info(resource_group_name, namespace_name, hybrid_connection_name, authorization_rule_name, custom_headers:nil) delete_authorization_rule_async(resource_group_name, namespace_name, hybrid_connection_name, authorization_rule_name, custom_headers:custom_headers).value! end
[ "def", "delete_authorization_rule_with_http_info", "(", "resource_group_name", ",", "namespace_name", ",", "hybrid_connection_name", ",", "authorization_rule_name", ",", "custom_headers", ":", "nil", ")", "delete_authorization_rule_async", "(", "resource_group_name", ",", "name...
Deletes a HybridConnection authorization rule @param resource_group_name [String] Name of the Resource group within the Azure subscription. @param namespace_name [String] The Namespace Name @param hybrid_connection_name [String] The hybrid connection name. @param authorization_rule_name [String] The authorization...
[ "Deletes", "a", "HybridConnection", "authorization", "rule" ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_relay/lib/2016-07-01/generated/azure_mgmt_relay/hybrid_connections.rb#L804-L806
train
Deletes the authorization rule.
[ 30522, 13366, 3972, 12870, 1035, 20104, 1035, 3627, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3415, 15327, 1035, 2171, 1010, 8893, 1035, 4434, 1035, 2171, 1010, 20104, 1035, 3627, 1035, 2171, 1010, 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...
rails/rails
activejob/lib/active_job/core.rb
ActiveJob.Core.deserialize
def deserialize(job_data) self.job_id = job_data["job_id"] self.provider_job_id = job_data["provider_job_id"] self.queue_name = job_data["queue_name"] self.priority = job_data["priority"] self.serialized_arguments = job_data["arguments"] self....
ruby
def deserialize(job_data) self.job_id = job_data["job_id"] self.provider_job_id = job_data["provider_job_id"] self.queue_name = job_data["queue_name"] self.priority = job_data["priority"] self.serialized_arguments = job_data["arguments"] self....
[ "def", "deserialize", "(", "job_data", ")", "self", ".", "job_id", "=", "job_data", "[", "\"job_id\"", "]", "self", ".", "provider_job_id", "=", "job_data", "[", "\"provider_job_id\"", "]", "self", ".", "queue_name", "=", "job_data", "[", "\"queue_name\"", "]"...
Attaches the stored job data to the current instance. Receives a hash returned from +serialize+ ==== Examples class DeliverWebhookJob < ActiveJob::Base attr_writer :attempt_number def attempt_number @attempt_number ||= 0 end def serialize super.merge('attempt_number' =>...
[ "Attaches", "the", "stored", "job", "data", "to", "the", "current", "instance", ".", "Receives", "a", "hash", "returned", "from", "+", "serialize", "+" ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activejob/lib/active_job/core.rb#L134-L145
train
Deserialize the job data
[ 30522, 13366, 4078, 11610, 3669, 4371, 1006, 3105, 1035, 2951, 1007, 2969, 1012, 3105, 1035, 8909, 1027, 3105, 1035, 2951, 1031, 1000, 3105, 1035, 8909, 1000, 1033, 2969, 1012, 10802, 1035, 3105, 1035, 8909, 1027, 3105, 1035, 2951, 1031, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/site.rb
Jekyll.Site.in_cache_dir
def in_cache_dir(*paths) paths.reduce(cache_dir) do |base, path| Jekyll.sanitized_path(base, path) end end
ruby
def in_cache_dir(*paths) paths.reduce(cache_dir) do |base, path| Jekyll.sanitized_path(base, path) end end
[ "def", "in_cache_dir", "(", "*", "paths", ")", "paths", ".", "reduce", "(", "cache_dir", ")", "do", "|", "base", ",", "path", "|", "Jekyll", ".", "sanitized_path", "(", "base", ",", "path", ")", "end", "end" ]
Public: Prefix a given path with the cache directory. paths - (optional) path elements to a file or directory within the cache directory Returns a path which is prefixed with the cache directory.
[ "Public", ":", "Prefix", "a", "given", "path", "with", "the", "cache", "directory", "." ]
fd74fe3e93a1fb506fa6621a2e271d7b9c5c3e3b
https://github.com/jekyll/jekyll/blob/fd74fe3e93a1fb506fa6621a2e271d7b9c5c3e3b/lib/jekyll/site.rb#L416-L420
train
Returns the cache directory for the given paths.
[ 30522, 13366, 1999, 1035, 17053, 1035, 16101, 1006, 1008, 10425, 1007, 10425, 1012, 5547, 1006, 17053, 1035, 16101, 1007, 2079, 1064, 2918, 1010, 4130, 1064, 15333, 4801, 3363, 1012, 2624, 25090, 5422, 1035, 4130, 1006, 2918, 1010, 4130, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/jobs.rb
Azure::StorSimple8000Series::Mgmt::V2017_06_01.Jobs.cancel_async
def cancel_async(device_name, job_name, resource_group_name, manager_name, custom_headers:nil) # Send request promise = begin_cancel_async(device_name, job_name, resource_group_name, manager_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization m...
ruby
def cancel_async(device_name, job_name, resource_group_name, manager_name, custom_headers:nil) # Send request promise = begin_cancel_async(device_name, job_name, resource_group_name, manager_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization m...
[ "def", "cancel_async", "(", "device_name", ",", "job_name", ",", "resource_group_name", ",", "manager_name", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_cancel_async", "(", "device_name", ",", "job_name", ",", "resource_group_name"...
@param device_name [String] The device name @param job_name [String] The jobName. @param resource_group_name [String] The resource group name @param manager_name [String] The manager name @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [Conc...
[ "@param", "device_name", "[", "String", "]", "The", "device", "name", "@param", "job_name", "[", "String", "]", "The", "jobName", ".", "@param", "resource_group_name", "[", "String", "]", "The", "resource", "group", "name", "@param", "manager_name", "[", "Stri...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/jobs.rb#L257-L271
train
Cancels a managed cluster job.
[ 30522, 13366, 17542, 1035, 2004, 6038, 2278, 1006, 5080, 1035, 2171, 1010, 3105, 1035, 2171, 1010, 7692, 1035, 2177, 1035, 2171, 1010, 3208, 1035, 2171, 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...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Model.delete_prebuilt_entity_role_with_http_info
def delete_prebuilt_entity_role_with_http_info(app_id, version_id, entity_id, role_id, custom_headers:nil) delete_prebuilt_entity_role_async(app_id, version_id, entity_id, role_id, custom_headers:custom_headers).value! end
ruby
def delete_prebuilt_entity_role_with_http_info(app_id, version_id, entity_id, role_id, custom_headers:nil) delete_prebuilt_entity_role_async(app_id, version_id, entity_id, role_id, custom_headers:custom_headers).value! end
[ "def", "delete_prebuilt_entity_role_with_http_info", "(", "app_id", ",", "version_id", ",", "entity_id", ",", "role_id", ",", "custom_headers", ":", "nil", ")", "delete_prebuilt_entity_role_async", "(", "app_id", ",", "version_id", ",", "entity_id", ",", "role_id", ",...
Delete a role in a prebuilt entity in a version of the application. @param app_id The application ID. @param version_id [String] The version ID. @param entity_id The entity ID. @param role_id The entity role Id. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTT...
[ "Delete", "a", "role", "in", "a", "prebuilt", "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#L9321-L9323
train
Deletes a prebuilt entity role.
[ 30522, 13366, 3972, 12870, 1035, 3653, 8569, 4014, 2102, 1035, 9178, 1035, 2535, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 9178, 1035, 8909, 1010, 2535, 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...
mhenrixon/sidekiq-unique-jobs
lib/sidekiq_unique_jobs/config.rb
SidekiqUniqueJobs.Config.add_strategy
def add_strategy(name, klass) raise ArgumentError, "strategy #{name} already defined, please use another name" if strategies.key?(name.to_sym) new_strategies = strategies.dup.merge(name.to_sym => klass).freeze self.strategies = new_strategies end
ruby
def add_strategy(name, klass) raise ArgumentError, "strategy #{name} already defined, please use another name" if strategies.key?(name.to_sym) new_strategies = strategies.dup.merge(name.to_sym => klass).freeze self.strategies = new_strategies end
[ "def", "add_strategy", "(", "name", ",", "klass", ")", "raise", "ArgumentError", ",", "\"strategy #{name} already defined, please use another name\"", "if", "strategies", ".", "key?", "(", "name", ".", "to_sym", ")", "new_strategies", "=", "strategies", ".", "dup", ...
Adds an on_conflict strategy to the configuration. It will raise if the strategy exists already @param [String] name the name of the custom strategy @param [Class] klass the class describing the strategy
[ "Adds", "an", "on_conflict", "strategy", "to", "the", "configuration", ".", "It", "will", "raise", "if", "the", "strategy", "exists", "already" ]
2944b97c720528f53962ccfd17d43ac939a77f46
https://github.com/mhenrixon/sidekiq-unique-jobs/blob/2944b97c720528f53962ccfd17d43ac939a77f46/lib/sidekiq_unique_jobs/config.rb#L62-L67
train
Add a strategy to the strategy list
[ 30522, 13366, 5587, 1035, 5656, 1006, 2171, 1010, 1047, 27102, 1007, 5333, 6685, 2121, 29165, 1010, 1000, 5656, 1001, 1063, 2171, 1065, 2525, 4225, 1010, 3531, 2224, 2178, 2171, 1000, 2065, 9942, 1012, 3145, 1029, 1006, 2171, 1012, 2000, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_storage/lib/2018-03-01-preview/generated/azure_mgmt_storage/storage_accounts.rb
Azure::Storage::Mgmt::V2018_03_01_preview.StorageAccounts.create_or_update_management_policies
def create_or_update_management_policies(resource_group_name, account_name, properties, custom_headers:nil) response = create_or_update_management_policies_async(resource_group_name, account_name, properties, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def create_or_update_management_policies(resource_group_name, account_name, properties, custom_headers:nil) response = create_or_update_management_policies_async(resource_group_name, account_name, properties, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "create_or_update_management_policies", "(", "resource_group_name", ",", "account_name", ",", "properties", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_or_update_management_policies_async", "(", "resource_group_name", ",", "account_name", ",", "p...
Sets the data policy rules associated with the specified storage account. @param resource_group_name [String] The name of the resource group within the user's subscription. The name is case insensitive. @param account_name [String] The name of the storage account within the specified resource group. Storage accoun...
[ "Sets", "the", "data", "policy", "rules", "associated", "with", "the", "specified", "storage", "account", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_storage/lib/2018-03-01-preview/generated/azure_mgmt_storage/storage_accounts.rb#L1329-L1332
train
Creates or updates management policies.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1035, 2968, 1035, 6043, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 4070, 1035, 2171, 1010, 5144, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3443, 1035, 2030, 1035, 10651, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/tree/node.rb
HamlLint::Tree.Node.each
def each return to_enum(__callee__) unless block_given? node = self loop do yield node break unless (node = node.next_node) end end
ruby
def each return to_enum(__callee__) unless block_given? node = self loop do yield node break unless (node = node.next_node) end end
[ "def", "each", "return", "to_enum", "(", "__callee__", ")", "unless", "block_given?", "node", "=", "self", "loop", "do", "yield", "node", "break", "unless", "(", "node", "=", "node", ".", "next_node", ")", "end", "end" ]
Implements the Enumerable interface to walk through an entire tree. @return [Enumerator, HamlLint::Tree::Node]
[ "Implements", "the", "Enumerable", "interface", "to", "walk", "through", "an", "entire", "tree", "." ]
024c773667e54cf88db938c2b368977005d70ee8
https://github.com/sds/haml-lint/blob/024c773667e54cf88db938c2b368977005d70ee8/lib/haml_lint/tree/node.rb#L51-L59
train
Yields each node in the sequence.
[ 30522, 13366, 2169, 2709, 2000, 1035, 4372, 2819, 1006, 1035, 1035, 2655, 4402, 1035, 1035, 1007, 4983, 3796, 1035, 2445, 1029, 13045, 1027, 2969, 7077, 2079, 10750, 13045, 3338, 4983, 1006, 13045, 1027, 13045, 1012, 2279, 1035, 13045, 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_policy_insights/lib/2018-04-04/generated/azure_mgmt_policy_insights/policy_states.rb
Azure::PolicyInsights::Mgmt::V2018_04_04.PolicyStates.summarize_for_resource_group
def summarize_for_resource_group(subscription_id, resource_group_name, query_options:nil, custom_headers:nil) response = summarize_for_resource_group_async(subscription_id, resource_group_name, query_options:query_options, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def summarize_for_resource_group(subscription_id, resource_group_name, query_options:nil, custom_headers:nil) response = summarize_for_resource_group_async(subscription_id, resource_group_name, query_options:query_options, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "summarize_for_resource_group", "(", "subscription_id", ",", "resource_group_name", ",", "query_options", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "summarize_for_resource_group_async", "(", "subscription_id", ",", "resource_group_name", ...
Summarizes policy states for the resources under the resource group. @param subscription_id [String] Microsoft Azure subscription ID. @param resource_group_name [String] Resource group name. @param query_options [QueryOptions] Additional parameters for the operation @param custom_headers [Hash{String => String}] A...
[ "Summarizes", "policy", "states", "for", "the", "resources", "under", "the", "resource", "group", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_policy_insights/lib/2018-04-04/generated/azure_mgmt_policy_insights/policy_states.rb#L648-L651
train
Gets the number of documents in a resource group.
[ 30522, 13366, 7680, 7849, 4697, 1035, 2005, 1035, 7692, 1035, 2177, 1006, 15002, 1035, 8909, 1010, 7692, 1035, 2177, 1035, 2171, 1010, 23032, 1035, 7047, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 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...
lostisland/faraday
lib/faraday/connection.rb
Faraday.Connection.build_exclusive_url
def build_exclusive_url(url = nil, params = nil, params_encoder = nil) url = nil if url.respond_to?(:empty?) && url.empty? base = url_prefix if url && base.path && base.path !~ %r{/$} base = base.dup base.path = base.path + '/' # ensure trailing slash end uri = url ? base +...
ruby
def build_exclusive_url(url = nil, params = nil, params_encoder = nil) url = nil if url.respond_to?(:empty?) && url.empty? base = url_prefix if url && base.path && base.path !~ %r{/$} base = base.dup base.path = base.path + '/' # ensure trailing slash end uri = url ? base +...
[ "def", "build_exclusive_url", "(", "url", "=", "nil", ",", "params", "=", "nil", ",", "params_encoder", "=", "nil", ")", "url", "=", "nil", "if", "url", ".", "respond_to?", "(", ":empty?", ")", "&&", "url", ".", "empty?", "base", "=", "url_prefix", "if...
Build an absolute URL based on url_prefix. @param url [String, URI] @param params [Faraday::Utils::ParamsHash] A Faraday::Utils::ParamsHash to replace the query values of the resulting url (default: nil). @return [URI]
[ "Build", "an", "absolute", "URL", "based", "on", "url_prefix", "." ]
3abe9d1eea4bdf61cdf7b76ff9f1ae7e09482e70
https://github.com/lostisland/faraday/blob/3abe9d1eea4bdf61cdf7b76ff9f1ae7e09482e70/lib/faraday/connection.rb#L530-L545
train
Build an exclusive URL
[ 30522, 13366, 3857, 1035, 7262, 1035, 24471, 2140, 1006, 24471, 2140, 1027, 9152, 2140, 1010, 11498, 5244, 1027, 9152, 2140, 1010, 11498, 5244, 1035, 4372, 16044, 2099, 1027, 9152, 2140, 1007, 24471, 2140, 1027, 9152, 2140, 2065, 24471, 214...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
lostisland/faraday
lib/faraday/options.rb
Faraday.Options.each
def each return to_enum(:each) unless block_given? members.each do |key| yield(key.to_sym, send(key)) end end
ruby
def each return to_enum(:each) unless block_given? members.each do |key| yield(key.to_sym, send(key)) end end
[ "def", "each", "return", "to_enum", "(", ":each", ")", "unless", "block_given?", "members", ".", "each", "do", "|", "key", "|", "yield", "(", "key", ".", "to_sym", ",", "send", "(", "key", ")", ")", "end", "end" ]
Public
[ "Public" ]
3abe9d1eea4bdf61cdf7b76ff9f1ae7e09482e70
https://github.com/lostisland/faraday/blob/3abe9d1eea4bdf61cdf7b76ff9f1ae7e09482e70/lib/faraday/options.rb#L13-L19
train
Yields the result of the block.
[ 30522, 13366, 2169, 2709, 2000, 1035, 4372, 2819, 1006, 1024, 2169, 1007, 4983, 3796, 1035, 2445, 1029, 2372, 1012, 2169, 2079, 1064, 3145, 1064, 10750, 1006, 3145, 1012, 2000, 1035, 25353, 2213, 1010, 4604, 1006, 3145, 1007, 1007, 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...
square/connect-ruby-sdk
lib/square_connect/api/v1_employees_api.rb
SquareConnect.V1EmployeesApi.create_employee_role
def create_employee_role(employee_role, opts = {}) data, _status_code, _headers = create_employee_role_with_http_info(employee_role, opts) return data end
ruby
def create_employee_role(employee_role, opts = {}) data, _status_code, _headers = create_employee_role_with_http_info(employee_role, opts) return data end
[ "def", "create_employee_role", "(", "employee_role", ",", "opts", "=", "{", "}", ")", "data", ",", "_status_code", ",", "_headers", "=", "create_employee_role_with_http_info", "(", "employee_role", ",", "opts", ")", "return", "data", "end" ]
CreateEmployeeRole Creates an employee role you can then assign to employees. Square accounts can include any number of roles that can be assigned to employees. These roles define the actions and permissions granted to an employee with that role. For example, an employee with a \"Shift Manager\" role might be able to...
[ "CreateEmployeeRole", "Creates", "an", "employee", "role", "you", "can", "then", "assign", "to", "employees", ".", "Square", "accounts", "can", "include", "any", "number", "of", "roles", "that", "can", "be", "assigned", "to", "employees", ".", "These", "roles"...
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/api/v1_employees_api.rb#L80-L83
train
Creates an employee role
[ 30522, 13366, 3443, 1035, 7904, 1035, 2535, 1006, 7904, 1035, 2535, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 2951, 1010, 1035, 3570, 1035, 3642, 1010, 1035, 20346, 2015, 1027, 3443, 1035, 7904, 1035, 2535, 1035, 2007, 1035, 8299, 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...
Fullscreen/yt
lib/yt/request.rb
Yt.Request.server_errors
def server_errors [ OpenSSL::SSL::SSLError, Errno::ETIMEDOUT, Errno::EHOSTUNREACH, Errno::ENETUNREACH, Errno::ECONNRESET, Net::OpenTimeout, SocketError, Net::HTTPServerError ] + extra_server_errors end
ruby
def server_errors [ OpenSSL::SSL::SSLError, Errno::ETIMEDOUT, Errno::EHOSTUNREACH, Errno::ENETUNREACH, Errno::ECONNRESET, Net::OpenTimeout, SocketError, Net::HTTPServerError ] + extra_server_errors end
[ "def", "server_errors", "[", "OpenSSL", "::", "SSL", "::", "SSLError", ",", "Errno", "::", "ETIMEDOUT", ",", "Errno", "::", "EHOSTUNREACH", ",", "Errno", "::", "ENETUNREACH", ",", "Errno", "::", "ECONNRESET", ",", "Net", "::", "OpenTimeout", ",", "SocketErro...
Returns the list of server errors worth retrying the request once.
[ "Returns", "the", "list", "of", "server", "errors", "worth", "retrying", "the", "request", "once", "." ]
bf5c33b977cb162bb7735ad5b80d1abdb5a38215
https://github.com/Fullscreen/yt/blob/bf5c33b977cb162bb7735ad5b80d1abdb5a38215/lib/yt/request.rb#L205-L216
train
Returns an array of server errors
[ 30522, 13366, 8241, 1035, 10697, 1031, 7480, 14540, 1024, 1024, 7020, 2140, 1024, 1024, 7020, 3917, 29165, 1010, 9413, 19139, 1024, 1024, 3802, 14428, 26797, 2102, 1010, 9413, 19139, 1024, 1024, 15501, 14122, 4609, 16416, 2818, 1010, 9413, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/nested_attributes.rb
ActiveRecord.NestedAttributes.assign_nested_attributes_for_one_to_one_association
def assign_nested_attributes_for_one_to_one_association(association_name, attributes) options = nested_attributes_options[association_name] if attributes.respond_to?(:permitted?) attributes = attributes.to_h end attributes = attributes.with_indifferent_access existing_r...
ruby
def assign_nested_attributes_for_one_to_one_association(association_name, attributes) options = nested_attributes_options[association_name] if attributes.respond_to?(:permitted?) attributes = attributes.to_h end attributes = attributes.with_indifferent_access existing_r...
[ "def", "assign_nested_attributes_for_one_to_one_association", "(", "association_name", ",", "attributes", ")", "options", "=", "nested_attributes_options", "[", "association_name", "]", "if", "attributes", ".", "respond_to?", "(", ":permitted?", ")", "attributes", "=", "a...
Assigns the given attributes to the association. If an associated record does not yet exist, one will be instantiated. If an associated record already exists, the method's behavior depends on the value of the update_only option. If update_only is +false+ and the given attributes include an <tt>:id</tt> that matche...
[ "Assigns", "the", "given", "attributes", "to", "the", "association", "." ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activerecord/lib/active_record/nested_attributes.rb#L407-L437
train
Assign nested attributes for one - to - one association
[ 30522, 13366, 23911, 1035, 9089, 2098, 1035, 12332, 1035, 2005, 1035, 2028, 1035, 2000, 1035, 2028, 1035, 2523, 1006, 2523, 1035, 2171, 1010, 12332, 1007, 7047, 1027, 9089, 2098, 1035, 12332, 1035, 7047, 1031, 2523, 1035, 2171, 1033, 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...
strongself/Generamba
lib/generamba/template/helpers/catalog_downloader.rb
Generamba.CatalogDownloader.download_catalog
def download_catalog(name, url) catalogs_local_path = Pathname.new(ENV['HOME']) .join(GENERAMBA_HOME_DIR) .join(CATALOGS_DIR) current_catalog_path = catalogs_local_path .join(name) if File.exists?(current_c...
ruby
def download_catalog(name, url) catalogs_local_path = Pathname.new(ENV['HOME']) .join(GENERAMBA_HOME_DIR) .join(CATALOGS_DIR) current_catalog_path = catalogs_local_path .join(name) if File.exists?(current_c...
[ "def", "download_catalog", "(", "name", ",", "url", ")", "catalogs_local_path", "=", "Pathname", ".", "new", "(", "ENV", "[", "'HOME'", "]", ")", ".", "join", "(", "GENERAMBA_HOME_DIR", ")", ".", "join", "(", "CATALOGS_DIR", ")", "current_catalog_path", "=",...
Clones a template catalog from a remote repository @param name [String] The name of the template catalog @param url [String] The url of the repository @return [Pathname] A filepath to the downloaded catalog
[ "Clones", "a", "template", "catalog", "from", "a", "remote", "repository" ]
9ef343805f3a66f58bc36e120e822d5436a4da97
https://github.com/strongself/Generamba/blob/9ef343805f3a66f58bc36e120e822d5436a4da97/lib/generamba/template/helpers/catalog_downloader.rb#L41-L56
train
downloads a catalog from the local repository
[ 30522, 13366, 8816, 1035, 12105, 1006, 2171, 1010, 24471, 2140, 1007, 12105, 2015, 1035, 2334, 1035, 4130, 1027, 4130, 18442, 1012, 2047, 1006, 4372, 2615, 1031, 1005, 2188, 1005, 1033, 1007, 1012, 3693, 1006, 11416, 11201, 1035, 2188, 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
activesupport/lib/active_support/message_verifier.rb
ActiveSupport.MessageVerifier.verified
def verified(signed_message, purpose: nil, **) if valid_message?(signed_message) begin data = signed_message.split("--")[0] message = Messages::Metadata.verify(decode(data), purpose) @serializer.load(message) if message rescue ArgumentError => argument_error ...
ruby
def verified(signed_message, purpose: nil, **) if valid_message?(signed_message) begin data = signed_message.split("--")[0] message = Messages::Metadata.verify(decode(data), purpose) @serializer.load(message) if message rescue ArgumentError => argument_error ...
[ "def", "verified", "(", "signed_message", ",", "purpose", ":", "nil", ",", "**", ")", "if", "valid_message?", "(", "signed_message", ")", "begin", "data", "=", "signed_message", ".", "split", "(", "\"--\"", ")", "[", "0", "]", "message", "=", "Messages", ...
Decodes the signed message using the +MessageVerifier+'s secret. verifier = ActiveSupport::MessageVerifier.new 's3Krit' signed_message = verifier.generate 'a private message' verifier.verified(signed_message) # => 'a private message' Returns +nil+ if the message was not signed with the same secret. oth...
[ "Decodes", "the", "signed", "message", "using", "the", "+", "MessageVerifier", "+", "s", "secret", "." ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activesupport/lib/active_support/message_verifier.rb#L150-L161
train
verify the message
[ 30522, 13366, 20119, 1006, 2772, 1035, 4471, 1010, 3800, 1024, 9152, 2140, 1010, 1008, 1008, 1007, 2065, 9398, 1035, 4471, 1029, 1006, 2772, 1035, 4471, 1007, 4088, 2951, 1027, 2772, 1035, 4471, 1012, 3975, 1006, 1000, 1011, 1011, 1000, 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.add_principals_with_http_info
def add_principals_with_http_info(resource_group_name, cluster_name, database_name, database_principals_to_add, custom_headers:nil) add_principals_async(resource_group_name, cluster_name, database_name, database_principals_to_add, custom_headers:custom_headers).value! end
ruby
def add_principals_with_http_info(resource_group_name, cluster_name, database_name, database_principals_to_add, custom_headers:nil) add_principals_async(resource_group_name, cluster_name, database_name, database_principals_to_add, custom_headers:custom_headers).value! end
[ "def", "add_principals_with_http_info", "(", "resource_group_name", ",", "cluster_name", ",", "database_name", ",", "database_principals_to_add", ",", "custom_headers", ":", "nil", ")", "add_principals_async", "(", "resource_group_name", ",", "cluster_name", ",", "database_...
Add Database principals permissions. @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 [String] The name of the database in the Kusto cluster. @param database_principals_to_add [Database...
[ "Add", "Database", "principals", "permissions", "." ]
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#L603-L605
train
Adds a collection of principals to the database.
[ 30522, 13366, 5587, 1035, 27928, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 9324, 1035, 2171, 1010, 7809, 1035, 2171, 1010, 7809, 1035, 27928, 1035, 2000, 1035, 5587, 1010, 7661, 1035, 20346, 2015, 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...
randym/axlsx
lib/axlsx/workbook/worksheet/rich_text_run.rb
Axlsx.RichTextRun.font_size
def font_size return sz if sz font = styles.fonts[styles.cellXfs[style].fontId] || styles.fonts[0] (font.b || (defined?(@b) && @b)) ? (font.sz * 1.5) : font.sz end
ruby
def font_size return sz if sz font = styles.fonts[styles.cellXfs[style].fontId] || styles.fonts[0] (font.b || (defined?(@b) && @b)) ? (font.sz * 1.5) : font.sz end
[ "def", "font_size", "return", "sz", "if", "sz", "font", "=", "styles", ".", "fonts", "[", "styles", ".", "cellXfs", "[", "style", "]", ".", "fontId", "]", "||", "styles", ".", "fonts", "[", "0", "]", "(", "font", ".", "b", "||", "(", "defined?", ...
we scale the font size if bold style is applied to either the style font or the cell itself. Yes, it is a bit of a hack, but it is much better than using imagemagick and loading metrics for every character.
[ "we", "scale", "the", "font", "size", "if", "bold", "style", "is", "applied", "to", "either", "the", "style", "font", "or", "the", "cell", "itself", ".", "Yes", "it", "is", "a", "bit", "of", "a", "hack", "but", "it", "is", "much", "better", "than", ...
c593a08b2a929dac7aa8dc418b55e26b4c49dc34
https://github.com/randym/axlsx/blob/c593a08b2a929dac7aa8dc418b55e26b4c49dc34/lib/axlsx/workbook/worksheet/rich_text_run.rb#L224-L228
train
Returns the number of bytes of the font in the cell.
[ 30522, 13366, 15489, 1035, 2946, 2709, 1055, 2480, 2065, 1055, 2480, 15489, 1027, 6782, 1012, 15489, 2015, 1031, 6782, 1012, 3526, 2595, 10343, 1031, 2806, 1033, 1012, 15489, 3593, 1033, 1064, 1064, 6782, 1012, 15489, 2015, 1031, 1014, 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...
mhenrixon/sidekiq-unique-jobs
lib/sidekiq_unique_jobs/util.rb
SidekiqUniqueJobs.Util.keys
def keys(pattern = SCAN_PATTERN, count = DEFAULT_COUNT) return redis(&:keys) if pattern.nil? redis { |conn| conn.scan_each(match: prefix(pattern), count: count).to_a } end
ruby
def keys(pattern = SCAN_PATTERN, count = DEFAULT_COUNT) return redis(&:keys) if pattern.nil? redis { |conn| conn.scan_each(match: prefix(pattern), count: count).to_a } end
[ "def", "keys", "(", "pattern", "=", "SCAN_PATTERN", ",", "count", "=", "DEFAULT_COUNT", ")", "return", "redis", "(", ":keys", ")", "if", "pattern", ".", "nil?", "redis", "{", "|", "conn", "|", "conn", ".", "scan_each", "(", "match", ":", "prefix", "(",...
Find unique keys in redis @param [String] pattern a pattern to scan for in redis @param [Integer] count the maximum number of keys to delete @return [Array<String>] an array with active unique keys
[ "Find", "unique", "keys", "in", "redis" ]
2944b97c720528f53962ccfd17d43ac939a77f46
https://github.com/mhenrixon/sidekiq-unique-jobs/blob/2944b97c720528f53962ccfd17d43ac939a77f46/lib/sidekiq_unique_jobs/util.rb#L21-L25
train
Returns an array of keys in the cache.
[ 30522, 13366, 6309, 1006, 5418, 1027, 13594, 1035, 5418, 1010, 4175, 1027, 12398, 1035, 4175, 1007, 2709, 2417, 2483, 1006, 1004, 1024, 6309, 1007, 2065, 5418, 1012, 9152, 2140, 1029, 2417, 2483, 1063, 1064, 9530, 2078, 1064, 9530, 2078, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
wearefine/fae
app/helpers/fae/form_helper.rb
Fae.FormHelper.language_support
def language_support(f, attribute, options) return if Fae.languages.blank? attribute_array = attribute.to_s.split('_') language_suffix = attribute_array.pop return unless Fae.languages.has_key?(language_suffix.to_sym) || Fae.languages.has_key?(language_suffix) label = attribute_array.pus...
ruby
def language_support(f, attribute, options) return if Fae.languages.blank? attribute_array = attribute.to_s.split('_') language_suffix = attribute_array.pop return unless Fae.languages.has_key?(language_suffix.to_sym) || Fae.languages.has_key?(language_suffix) label = attribute_array.pus...
[ "def", "language_support", "(", "f", ",", "attribute", ",", "options", ")", "return", "if", "Fae", ".", "languages", ".", "blank?", "attribute_array", "=", "attribute", ".", "to_s", ".", "split", "(", "'_'", ")", "language_suffix", "=", "attribute_array", "....
removes language suffix from label and adds data attr for languange nav
[ "removes", "language", "suffix", "from", "label", "and", "adds", "data", "attr", "for", "languange", "nav" ]
645d6b66945aeff54e27af6a95c4f8a1f7a67d39
https://github.com/wearefine/fae/blob/645d6b66945aeff54e27af6a95c4f8a1f7a67d39/app/helpers/fae/form_helper.rb#L199-L214
train
Returns the language support for the given attribute.
[ 30522, 13366, 2653, 1035, 2490, 1006, 1042, 1010, 17961, 1010, 7047, 1007, 2709, 2065, 17282, 1012, 4155, 1012, 8744, 1029, 17961, 1035, 9140, 1027, 17961, 1012, 2000, 1035, 1055, 1012, 3975, 1006, 1005, 1035, 1005, 1007, 2653, 1035, 16809,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/type.rb
Puppet.Type.builddepends
def builddepends # Handle the requires self.class.relationship_params.collect do |klass| if param = @parameters[klass.name] param.to_edges end end.flatten.reject { |r| r.nil? } end
ruby
def builddepends # Handle the requires self.class.relationship_params.collect do |klass| if param = @parameters[klass.name] param.to_edges end end.flatten.reject { |r| r.nil? } end
[ "def", "builddepends", "# Handle the requires", "self", ".", "class", ".", "relationship_params", ".", "collect", "do", "|", "klass", "|", "if", "param", "=", "@parameters", "[", "klass", ".", "name", "]", "param", ".", "to_edges", "end", "end", ".", "flatte...
Builds the dependencies associated with this resource. @return [Array<Puppet::Relationship>] list of relationships to other resources
[ "Builds", "the", "dependencies", "associated", "with", "this", "resource", "." ]
4baeed97cbb7571ddc6635f0a24debe2e8b22cd3
https://github.com/puppetlabs/puppet/blob/4baeed97cbb7571ddc6635f0a24debe2e8b22cd3/lib/puppet/type.rb#L2194-L2201
train
Build the requires
[ 30522, 13366, 3857, 3207, 11837, 5104, 1001, 5047, 1996, 5942, 2969, 1012, 2465, 1012, 3276, 1035, 11498, 5244, 1012, 8145, 2079, 1064, 1047, 27102, 1064, 2065, 11498, 2213, 1027, 1030, 11709, 1031, 1047, 27102, 1012, 2171, 1033, 11498, 221...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.create_hierarchical_entity_role
def create_hierarchical_entity_role(app_id, version_id, h_entity_id, entity_role_create_object, custom_headers:nil) response = create_hierarchical_entity_role_async(app_id, version_id, h_entity_id, entity_role_create_object, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def create_hierarchical_entity_role(app_id, version_id, h_entity_id, entity_role_create_object, custom_headers:nil) response = create_hierarchical_entity_role_async(app_id, version_id, h_entity_id, entity_role_create_object, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "create_hierarchical_entity_role", "(", "app_id", ",", "version_id", ",", "h_entity_id", ",", "entity_role_create_object", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_hierarchical_entity_role_async", "(", "app_id", ",", "version_id", ",", "h_...
Create a role for an 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 entity_role_create_object [EntityRoleCreateObject] An entity role object containing the name of rol...
[ "Create", "a", "role", "for", "an", "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#L7605-L7608
train
Creates an entity role for a given Hierarchical entity.
[ 30522, 13366, 3443, 1035, 25835, 1035, 9178, 1035, 2535, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 1044, 1035, 9178, 1035, 8909, 1010, 9178, 1035, 2535, 1035, 3443, 1035, 4874, 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...
sds/haml-lint
lib/haml_lint/linter.rb
HamlLint.Linter.next_node
def next_node(node) return unless node siblings = node.parent ? node.parent.children : [node] next_sibling = siblings[siblings.index(node) + 1] if siblings.count > 1 return next_sibling if next_sibling next_node(node.parent) end
ruby
def next_node(node) return unless node siblings = node.parent ? node.parent.children : [node] next_sibling = siblings[siblings.index(node) + 1] if siblings.count > 1 return next_sibling if next_sibling next_node(node.parent) end
[ "def", "next_node", "(", "node", ")", "return", "unless", "node", "siblings", "=", "node", ".", "parent", "?", "node", ".", "parent", ".", "children", ":", "[", "node", "]", "next_sibling", "=", "siblings", "[", "siblings", ".", "index", "(", "node", "...
Gets the next node following this node, ascending up the ancestor chain recursively if this node has no siblings. @param node [HamlLint::Tree::Node] @return [HamlLint::Tree::Node,nil]
[ "Gets", "the", "next", "node", "following", "this", "node", "ascending", "up", "the", "ancestor", "chain", "recursively", "if", "this", "node", "has", "no", "siblings", "." ]
024c773667e54cf88db938c2b368977005d70ee8
https://github.com/sds/haml-lint/blob/024c773667e54cf88db938c2b368977005d70ee8/lib/haml_lint/linter.rb#L153-L161
train
Returns the next node in the hierarchy.
[ 30522, 13366, 2279, 1035, 13045, 1006, 13045, 1007, 2709, 4983, 13045, 9504, 1027, 13045, 1012, 6687, 1029, 13045, 1012, 6687, 1012, 2336, 1024, 1031, 13045, 1033, 2279, 1035, 22941, 1027, 9504, 1031, 9504, 1012, 5950, 1006, 13045, 1007, 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...
square/connect-ruby-sdk
lib/square_connect/api/v1_items_api.rb
SquareConnect.V1ItemsApi.delete_discount
def delete_discount(location_id, discount_id, opts = {}) data, _status_code, _headers = delete_discount_with_http_info(location_id, discount_id, opts) return data end
ruby
def delete_discount(location_id, discount_id, opts = {}) data, _status_code, _headers = delete_discount_with_http_info(location_id, discount_id, opts) return data end
[ "def", "delete_discount", "(", "location_id", ",", "discount_id", ",", "opts", "=", "{", "}", ")", "data", ",", "_status_code", ",", "_headers", "=", "delete_discount_with_http_info", "(", "location_id", ",", "discount_id", ",", "opts", ")", "return", "data", ...
DeleteDiscount Deletes an existing discount. *Note**: DeleteDiscount returns nothing on success but Connect SDKs map the empty response to an empty `V1DeleteDiscountRequest` object as documented below. @param location_id The ID of the item&#39;s associated location. @param discount_id The ID of the discount to delet...
[ "DeleteDiscount", "Deletes", "an", "existing", "discount", ".", "*", "Note", "**", ":", "DeleteDiscount", "returns", "nothing", "on", "success", "but", "Connect", "SDKs", "map", "the", "empty", "response", "to", "an", "empty", "V1DeleteDiscountRequest", "object", ...
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/api/v1_items_api.rb#L754-L757
train
Delete a discount
[ 30522, 13366, 3972, 12870, 1035, 19575, 1006, 3295, 1035, 8909, 1010, 19575, 1035, 8909, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 2951, 1010, 1035, 3570, 1035, 3642, 1010, 1035, 20346, 2015, 1027, 3972, 12870, 1035, 19575, 1035, 2007, 103...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/pops/visitor.rb
Puppet::Pops.Visitor.visit_this_1
def visit_this_1(receiver, thing, arg) if method_name = @cache[thing.class] return receiver.send(method_name, thing, arg) end visit_this(receiver, thing, [arg]) end
ruby
def visit_this_1(receiver, thing, arg) if method_name = @cache[thing.class] return receiver.send(method_name, thing, arg) end visit_this(receiver, thing, [arg]) end
[ "def", "visit_this_1", "(", "receiver", ",", "thing", ",", "arg", ")", "if", "method_name", "=", "@cache", "[", "thing", ".", "class", "]", "return", "receiver", ".", "send", "(", "method_name", ",", "thing", ",", "arg", ")", "end", "visit_this", "(", ...
Visit an explicit receiver with 1 args (This is ~30% faster than calling the general method)
[ "Visit", "an", "explicit", "receiver", "with", "1", "args", "(", "This", "is", "~30%", "faster", "than", "calling", "the", "general", "method", ")" ]
4baeed97cbb7571ddc6635f0a24debe2e8b22cd3
https://github.com/puppetlabs/puppet/blob/4baeed97cbb7571ddc6635f0a24debe2e8b22cd3/lib/puppet/pops/visitor.rb#L88-L93
train
This method is called by the visitor to visit the given thing.
[ 30522, 13366, 3942, 1035, 2023, 1035, 1015, 1006, 8393, 1010, 2518, 1010, 12098, 2290, 1007, 2065, 4118, 1035, 2171, 1027, 1030, 17053, 1031, 2518, 1012, 2465, 1033, 2709, 8393, 1012, 4604, 1006, 4118, 1035, 2171, 1010, 2518, 1010, 12098, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
cloudfoundry/bosh
src/bosh-director/lib/bosh/director/nats_rpc.rb
Bosh::Director.NatsRpc.send_request
def send_request(subject_name, client_id, request, options, &callback) request_id = generate_request_id request["reply_to"] = "#{@inbox_name}.#{client_id}.#{request_id}" @lock.synchronize do @requests[request_id] = [callback, options] end sanitized_log_message = sanitize_log_messa...
ruby
def send_request(subject_name, client_id, request, options, &callback) request_id = generate_request_id request["reply_to"] = "#{@inbox_name}.#{client_id}.#{request_id}" @lock.synchronize do @requests[request_id] = [callback, options] end sanitized_log_message = sanitize_log_messa...
[ "def", "send_request", "(", "subject_name", ",", "client_id", ",", "request", ",", "options", ",", "&", "callback", ")", "request_id", "=", "generate_request_id", "request", "[", "\"reply_to\"", "]", "=", "\"#{@inbox_name}.#{client_id}.#{request_id}\"", "@lock", ".", ...
Sends a request (encoded as JSON) and listens for the response
[ "Sends", "a", "request", "(", "encoded", "as", "JSON", ")", "and", "listens", "for", "the", "response" ]
2eaa7100879ddd20cd909cd698514746195e28b7
https://github.com/cloudfoundry/bosh/blob/2eaa7100879ddd20cd909cd698514746195e28b7/src/bosh-director/lib/bosh/director/nats_rpc.rb#L40-L63
train
Send a request to the server
[ 30522, 13366, 4604, 1035, 5227, 1006, 3395, 1035, 2171, 1010, 7396, 1035, 8909, 1010, 5227, 1010, 7047, 1010, 1004, 2655, 5963, 1007, 5227, 1035, 8909, 1027, 9699, 1035, 5227, 1035, 8909, 5227, 1031, 1000, 7514, 1035, 2000, 1000, 1033, 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...
puppetlabs/bolt
lib/plan_executor/executor.rb
PlanExecutor.Executor.as_resultset
def as_resultset(targets) result_array = begin yield rescue StandardError => e @logger.warn(e) # CODEREVIEW how should we fail if there's an error? Array(Bolt::Result.from_exception(targets[0], e)) ...
ruby
def as_resultset(targets) result_array = begin yield rescue StandardError => e @logger.warn(e) # CODEREVIEW how should we fail if there's an error? Array(Bolt::Result.from_exception(targets[0], e)) ...
[ "def", "as_resultset", "(", "targets", ")", "result_array", "=", "begin", "yield", "rescue", "StandardError", "=>", "e", "@logger", ".", "warn", "(", "e", ")", "# CODEREVIEW how should we fail if there's an error?", "Array", "(", "Bolt", "::", "Result", ".", "from...
This handles running the job, catching errors, and turning the result into a result set
[ "This", "handles", "running", "the", "job", "catching", "errors", "and", "turning", "the", "result", "into", "a", "result", "set" ]
50689a33699939d262ea7c822a4b24fd8c4f8d8a
https://github.com/puppetlabs/bolt/blob/50689a33699939d262ea7c822a4b24fd8c4f8d8a/lib/plan_executor/executor.rb#L29-L38
train
Returns a new result set with the results of the block.
[ 30522, 13366, 2004, 1035, 3463, 3388, 1006, 7889, 1007, 2765, 1035, 9140, 1027, 4088, 10750, 5343, 3115, 2121, 29165, 1027, 1028, 1041, 1030, 8833, 4590, 1012, 11582, 1006, 1041, 1007, 1001, 3642, 2890, 8584, 2129, 2323, 2057, 8246, 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...
fastlane/fastlane
spaceship/lib/spaceship/client.rb
Spaceship.Client.team_id=
def team_id=(team_id) # First, we verify the team actually exists, because otherwise iTC would return the # following confusing error message # # invalid content provider id # available_teams = teams.collect do |team| { team_id: (team["contentProvider"] || {})["...
ruby
def team_id=(team_id) # First, we verify the team actually exists, because otherwise iTC would return the # following confusing error message # # invalid content provider id # available_teams = teams.collect do |team| { team_id: (team["contentProvider"] || {})["...
[ "def", "team_id", "=", "(", "team_id", ")", "# First, we verify the team actually exists, because otherwise iTC would return the", "# following confusing error message", "#", "# invalid content provider id", "#", "available_teams", "=", "teams", ".", "collect", "do", "|", "te...
Set a new team ID which will be used from now on
[ "Set", "a", "new", "team", "ID", "which", "will", "be", "used", "from", "now", "on" ]
457c5d647c77f0e078dafa5129da616914e002c5
https://github.com/fastlane/fastlane/blob/457c5d647c77f0e078dafa5129da616914e002c5/spaceship/lib/spaceship/client.rb#L137-L171
train
Set the current team ID
[ 30522, 13366, 2136, 1035, 8909, 1027, 1006, 2136, 1035, 8909, 1007, 1001, 2034, 1010, 2057, 20410, 1996, 2136, 2941, 6526, 1010, 2138, 4728, 2009, 2278, 2052, 2709, 1996, 1001, 2206, 16801, 7561, 4471, 1001, 1001, 19528, 4180, 10802, 8909, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_by_operation_with_http_info
def get_by_operation_with_http_info(resource_group_name, service_name, api_id, operation_id, tag_id, custom_headers:nil) get_by_operation_async(resource_group_name, service_name, api_id, operation_id, tag_id, custom_headers:custom_headers).value! end
ruby
def get_by_operation_with_http_info(resource_group_name, service_name, api_id, operation_id, tag_id, custom_headers:nil) get_by_operation_async(resource_group_name, service_name, api_id, operation_id, tag_id, custom_headers:custom_headers).value! end
[ "def", "get_by_operation_with_http_info", "(", "resource_group_name", ",", "service_name", ",", "api_id", ",", "operation_id", ",", "tag_id", ",", "custom_headers", ":", "nil", ")", "get_by_operation_async", "(", "resource_group_name", ",", "service_name", ",", "api_id"...
Get tag associated with the Operation. @param resource_group_name [String] The name of the resource group. @param service_name [String] The name of the API Management service. @param api_id [String] API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;re...
[ "Get", "tag", "associated", "with", "the", "Operation", "." ]
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#L1630-L1632
train
Gets the specified tag for the specified API.
[ 30522, 13366, 2131, 1035, 2011, 1035, 3169, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2326, 1035, 2171, 1010, 17928, 1035, 8909, 1010, 3169, 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_storagesync/lib/2018-07-01/generated/azure_mgmt_storagesync/registered_servers.rb
Azure::StorageSync::Mgmt::V2018_07_01.RegisteredServers.begin_delete_with_http_info
def begin_delete_with_http_info(resource_group_name, storage_sync_service_name, server_id, custom_headers:nil) begin_delete_async(resource_group_name, storage_sync_service_name, server_id, custom_headers:custom_headers).value! end
ruby
def begin_delete_with_http_info(resource_group_name, storage_sync_service_name, server_id, custom_headers:nil) begin_delete_async(resource_group_name, storage_sync_service_name, server_id, custom_headers:custom_headers).value! end
[ "def", "begin_delete_with_http_info", "(", "resource_group_name", ",", "storage_sync_service_name", ",", "server_id", ",", "custom_headers", ":", "nil", ")", "begin_delete_async", "(", "resource_group_name", ",", "storage_sync_service_name", ",", "server_id", ",", "custom_h...
Delete the given registered server. @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 server_id [String] GUID identifying the on-premises server. @param custom_headers [Hash{Str...
[ "Delete", "the", "given", "registered", "server", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_storagesync/lib/2018-07-01/generated/azure_mgmt_storagesync/registered_servers.rb#L527-L529
train
Deletes a server from the specified Data Lake Store account.
[ 30522, 13366, 4088, 1035, 3972, 12870, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 5527, 1035, 26351, 1035, 2326, 1035, 2171, 1010, 8241, 1035, 8909, 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...
aws/aws-sdk-ruby
gems/aws-sdk-rds/lib/aws-sdk-rds/resource.rb
Aws::RDS.Resource.create_db_subnet_group
def create_db_subnet_group(options = {}) resp = @client.create_db_subnet_group(options) DBSubnetGroup.new( name: resp.data.db_subnet_group.db_subnet_group_name, data: resp.data.db_subnet_group, client: @client ) end
ruby
def create_db_subnet_group(options = {}) resp = @client.create_db_subnet_group(options) DBSubnetGroup.new( name: resp.data.db_subnet_group.db_subnet_group_name, data: resp.data.db_subnet_group, client: @client ) end
[ "def", "create_db_subnet_group", "(", "options", "=", "{", "}", ")", "resp", "=", "@client", ".", "create_db_subnet_group", "(", "options", ")", "DBSubnetGroup", ".", "new", "(", "name", ":", "resp", ".", "data", ".", "db_subnet_group", ".", "db_subnet_group_n...
@example Request syntax with placeholder values dbsubnetgroup = rds.create_db_subnet_group({ db_subnet_group_name: "String", # required db_subnet_group_description: "String", # required subnet_ids: ["String"], # required tags: [ { key: "String", value: "String", }...
[ "@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#L1378-L1385
train
Creates a DB subnet group
[ 30522, 13366, 3443, 1035, 16962, 1035, 4942, 7159, 1035, 2177, 1006, 7047, 1027, 1063, 1065, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 3443, 1035, 16962, 1035, 4942, 7159, 1035, 2177, 1006, 7047, 1007, 16962, 6342, 24700, 3388, 17058, 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...
github/linguist
lib/linguist/generated.rb
Linguist.Generated.generated_apache_thrift?
def generated_apache_thrift? return false unless APACHE_THRIFT_EXTENSIONS.include?(extname) return lines.first(6).any? { |l| l.include?("Autogenerated by Thrift Compiler") } end
ruby
def generated_apache_thrift? return false unless APACHE_THRIFT_EXTENSIONS.include?(extname) return lines.first(6).any? { |l| l.include?("Autogenerated by Thrift Compiler") } end
[ "def", "generated_apache_thrift?", "return", "false", "unless", "APACHE_THRIFT_EXTENSIONS", ".", "include?", "(", "extname", ")", "return", "lines", ".", "first", "(", "6", ")", ".", "any?", "{", "|", "l", "|", "l", ".", "include?", "(", "\"Autogenerated by Th...
Internal: Is the blob generated by Apache Thrift compiler? Returns true or false
[ "Internal", ":", "Is", "the", "blob", "generated", "by", "Apache", "Thrift", "compiler?" ]
9116c90fcbb82ac03b4b33c58cfbde1fcf745e99
https://github.com/github/linguist/blob/9116c90fcbb82ac03b4b33c58cfbde1fcf745e99/lib/linguist/generated.rb#L327-L330
train
Returns true if the file is generated by apache thrift
[ 30522, 13366, 7013, 1035, 15895, 1035, 16215, 16338, 1029, 2709, 6270, 4983, 15895, 1035, 16215, 16338, 1035, 14305, 1012, 2421, 1029, 1006, 4654, 2102, 18442, 1007, 2709, 3210, 1012, 2034, 1006, 1020, 1007, 1012, 2151, 1029, 1063, 1064, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/device_settings.rb
Azure::StorSimple8000Series::Mgmt::V2017_06_01.DeviceSettings.create_or_update_alert_settings
def create_or_update_alert_settings(device_name, parameters, resource_group_name, manager_name, custom_headers:nil) response = create_or_update_alert_settings_async(device_name, parameters, resource_group_name, manager_name, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def create_or_update_alert_settings(device_name, parameters, resource_group_name, manager_name, custom_headers:nil) response = create_or_update_alert_settings_async(device_name, parameters, resource_group_name, manager_name, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "create_or_update_alert_settings", "(", "device_name", ",", "parameters", ",", "resource_group_name", ",", "manager_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_or_update_alert_settings_async", "(", "device_name", ",", "parameters", ",", ...
Creates or updates the alert settings of the specified device. @param device_name [String] The device name @param parameters [AlertSettings] The alert settings to be added or updated. @param resource_group_name [String] The resource group name @param manager_name [String] The manager name @param custom_headers [H...
[ "Creates", "or", "updates", "the", "alert", "settings", "of", "the", "specified", "device", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/device_settings.rb#L134-L137
train
Creates or updates alert settings for the device.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1035, 9499, 1035, 10906, 1006, 5080, 1035, 2171, 1010, 11709, 1010, 7692, 1035, 2177, 1035, 2171, 1010, 3208, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3443, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
awesome-print/awesome_print
lib/awesome_print/ext/active_record.rb
AwesomePrint.ActiveRecord.cast_with_active_record
def cast_with_active_record(object, type) cast = cast_without_active_record(object, type) return cast if !defined?(::ActiveRecord::Base) if object.is_a?(::ActiveRecord::Base) cast = :active_record_instance elsif object.is_a?(::ActiveModel::Errors) cast = :active_model_error ...
ruby
def cast_with_active_record(object, type) cast = cast_without_active_record(object, type) return cast if !defined?(::ActiveRecord::Base) if object.is_a?(::ActiveRecord::Base) cast = :active_record_instance elsif object.is_a?(::ActiveModel::Errors) cast = :active_model_error ...
[ "def", "cast_with_active_record", "(", "object", ",", "type", ")", "cast", "=", "cast_without_active_record", "(", "object", ",", "type", ")", "return", "cast", "if", "!", "defined?", "(", "::", "ActiveRecord", "::", "Base", ")", "if", "object", ".", "is_a?"...
Add ActiveRecord class names to the dispatcher pipeline. ------------------------------------------------------------------------------
[ "Add", "ActiveRecord", "class", "names", "to", "the", "dispatcher", "pipeline", ".", "------------------------------------------------------------------------------" ]
4564fd74721562cbef2443f7d97109bf9192343d
https://github.com/awesome-print/awesome_print/blob/4564fd74721562cbef2443f7d97109bf9192343d/lib/awesome_print/ext/active_record.rb#L16-L30
train
Casts an object to the given type.
[ 30522, 13366, 3459, 1035, 2007, 1035, 3161, 1035, 2501, 1006, 4874, 1010, 2828, 1007, 3459, 1027, 3459, 1035, 2302, 1035, 3161, 1035, 2501, 1006, 4874, 1010, 2828, 1007, 2709, 3459, 2065, 999, 4225, 1029, 1006, 1024, 1024, 3161, 2890, 271...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_service_bus/lib/2018-01-01-preview/generated/azure_mgmt_service_bus/namespaces.rb
Azure::ServiceBus::Mgmt::V2018_01_01_preview.Namespaces.list_ip_filter_rules
def list_ip_filter_rules(resource_group_name, namespace_name, custom_headers:nil) first_page = list_ip_filter_rules_as_lazy(resource_group_name, namespace_name, custom_headers:custom_headers) first_page.get_all_items end
ruby
def list_ip_filter_rules(resource_group_name, namespace_name, custom_headers:nil) first_page = list_ip_filter_rules_as_lazy(resource_group_name, namespace_name, custom_headers:custom_headers) first_page.get_all_items end
[ "def", "list_ip_filter_rules", "(", "resource_group_name", ",", "namespace_name", ",", "custom_headers", ":", "nil", ")", "first_page", "=", "list_ip_filter_rules_as_lazy", "(", "resource_group_name", ",", "namespace_name", ",", "custom_headers", ":custom_headers", ")", "...
Gets a list of IP Filter rules for a Namespace. @param resource_group_name [String] Name of the Resource group within the Azure subscription. @param namespace_name [String] The namespace name @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return ...
[ "Gets", "a", "list", "of", "IP", "Filter", "rules", "for", "a", "Namespace", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_service_bus/lib/2018-01-01-preview/generated/azure_mgmt_service_bus/namespaces.rb#L531-L534
train
Gets all the IP filter rules for a namespace.
[ 30522, 13366, 2862, 1035, 12997, 1035, 11307, 1035, 3513, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3415, 15327, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2034, 1035, 3931, 1027, 2862, 1035, 12997, 1035, 11307, 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_media_services/lib/2015-10-01/generated/azure_mgmt_media_services/media_service_operations.rb
Azure::MediaServices::Mgmt::V2015_10_01.MediaServiceOperations.create_with_http_info
def create_with_http_info(resource_group_name, media_service_name, parameters, custom_headers:nil) create_async(resource_group_name, media_service_name, parameters, custom_headers:custom_headers).value! end
ruby
def create_with_http_info(resource_group_name, media_service_name, parameters, custom_headers:nil) create_async(resource_group_name, media_service_name, parameters, custom_headers:custom_headers).value! end
[ "def", "create_with_http_info", "(", "resource_group_name", ",", "media_service_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "create_async", "(", "resource_group_name", ",", "media_service_name", ",", "parameters", ",", "custom_headers", ":custom_head...
Creates a Media Service. @param resource_group_name [String] Name of the resource group within the Azure subscription. @param media_service_name [String] Name of the Media Service. @param parameters [MediaService] Media Service properties needed for creation. @param custom_headers [Hash{String => String}] A hash...
[ "Creates", "a", "Media", "Service", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_media_services/lib/2015-10-01/generated/azure_mgmt_media_services/media_service_operations.rb#L345-L347
train
Creates a new chunk of a chunk of a chunk of the media service.
[ 30522, 13366, 3443, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2865, 1035, 2326, 1035, 2171, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3443, 1035, 2004, 6038, 2278, 1006, 7692, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
attr-encrypted/attr_encrypted
lib/attr_encrypted.rb
AttrEncrypted.InstanceMethods.encrypted_attributes
def encrypted_attributes @encrypted_attributes ||= begin duplicated= {} self.class.encrypted_attributes.map { |key, value| duplicated[key] = value.dup } duplicated end end
ruby
def encrypted_attributes @encrypted_attributes ||= begin duplicated= {} self.class.encrypted_attributes.map { |key, value| duplicated[key] = value.dup } duplicated end end
[ "def", "encrypted_attributes", "@encrypted_attributes", "||=", "begin", "duplicated", "=", "{", "}", "self", ".", "class", ".", "encrypted_attributes", ".", "map", "{", "|", "key", ",", "value", "|", "duplicated", "[", "key", "]", "=", "value", ".", "dup", ...
Copies the class level hash of encrypted attributes with virtual attribute names as keys and their corresponding options as values to the instance
[ "Copies", "the", "class", "level", "hash", "of", "encrypted", "attributes", "with", "virtual", "attribute", "names", "as", "keys", "and", "their", "corresponding", "options", "as", "values", "to", "the", "instance" ]
11df93aef14c661dd0c03169d382a0412f93124e
https://github.com/attr-encrypted/attr_encrypted/blob/11df93aef14c661dd0c03169d382a0412f93124e/lib/attr_encrypted.rb#L358-L364
train
Returns the array of the encrypted attributes for this object.
[ 30522, 13366, 4372, 26775, 22571, 3064, 1035, 12332, 1030, 4372, 26775, 22571, 3064, 1035, 12332, 1064, 1064, 1027, 4088, 24473, 2094, 1027, 1063, 1065, 2969, 1012, 2465, 1012, 4372, 26775, 22571, 3064, 1035, 12332, 1012, 4949, 1063, 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_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/backup_schedules.rb
Azure::StorSimple8000Series::Mgmt::V2017_06_01.BackupSchedules.begin_create_or_update
def begin_create_or_update(device_name, backup_policy_name, backup_schedule_name, parameters, resource_group_name, manager_name, custom_headers:nil) response = begin_create_or_update_async(device_name, backup_policy_name, backup_schedule_name, parameters, resource_group_name, manager_name, custom_headers:custom_h...
ruby
def begin_create_or_update(device_name, backup_policy_name, backup_schedule_name, parameters, resource_group_name, manager_name, custom_headers:nil) response = begin_create_or_update_async(device_name, backup_policy_name, backup_schedule_name, parameters, resource_group_name, manager_name, custom_headers:custom_h...
[ "def", "begin_create_or_update", "(", "device_name", ",", "backup_policy_name", ",", "backup_schedule_name", ",", "parameters", ",", "resource_group_name", ",", "manager_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "begin_create_or_update_async", "(", ...
Creates or updates the backup schedule. @param device_name [String] The device name @param backup_policy_name [String] The backup policy name. @param backup_schedule_name [String] The backup schedule name. @param parameters [BackupSchedule] The backup schedule. @param resource_group_name [String] The resource gro...
[ "Creates", "or", "updates", "the", "backup", "schedule", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_stor_simple8000_series/lib/2017-06-01/generated/azure_mgmt_stor_simple8000_series/backup_schedules.rb#L343-L346
train
Creates or updates a backup policy schedule.
[ 30522, 13366, 4088, 1035, 3443, 1035, 2030, 1035, 10651, 1006, 5080, 1035, 2171, 1010, 10200, 1035, 3343, 1035, 2171, 1010, 10200, 1035, 6134, 1035, 2171, 1010, 11709, 1010, 7692, 1035, 2177, 1035, 2171, 1010, 3208, 1035, 2171, 1010, 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...
square/connect-ruby-sdk
lib/square_connect/api/v1_transactions_api.rb
SquareConnect.V1TransactionsApi.list_bank_accounts
def list_bank_accounts(location_id, opts = {}) data, _status_code, _headers = list_bank_accounts_with_http_info(location_id, opts) return data end
ruby
def list_bank_accounts(location_id, opts = {}) data, _status_code, _headers = list_bank_accounts_with_http_info(location_id, opts) return data end
[ "def", "list_bank_accounts", "(", "location_id", ",", "opts", "=", "{", "}", ")", "data", ",", "_status_code", ",", "_headers", "=", "list_bank_accounts_with_http_info", "(", "location_id", ",", "opts", ")", "return", "data", "end" ]
ListBankAccounts Provides non-confidential details for all of a location's associated bank accounts. This endpoint does not provide full bank account numbers, and there is no way to obtain a full bank account number with the Connect API. @param location_id The ID of the location to list bank accounts for. @param [Ha...
[ "ListBankAccounts", "Provides", "non", "-", "confidential", "details", "for", "all", "of", "a", "location", "s", "associated", "bank", "accounts", ".", "This", "endpoint", "does", "not", "provide", "full", "bank", "account", "numbers", "and", "there", "is", "n...
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/api/v1_transactions_api.rb#L84-L87
train
Returns a list of Bank Account objects
[ 30522, 13366, 2862, 1035, 2924, 1035, 6115, 1006, 3295, 1035, 8909, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 2951, 1010, 1035, 3570, 1035, 3642, 1010, 1035, 20346, 2015, 1027, 2862, 1035, 2924, 1035, 6115, 1035, 2007, 1035, 8299, 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...
awesome-print/awesome_print
lib/awesome_print/ext/mongo_mapper.rb
AwesomePrint.MongoMapper.awesome_mongo_mapper_association
def awesome_mongo_mapper_association(object) return object.inspect if !defined?(::ActiveSupport::OrderedHash) return awesome_object(object) if @options[:raw] association = object.class.name.split('::').last.titleize.downcase.sub(/ association$/, '') association = "embeds #{association}" if obje...
ruby
def awesome_mongo_mapper_association(object) return object.inspect if !defined?(::ActiveSupport::OrderedHash) return awesome_object(object) if @options[:raw] association = object.class.name.split('::').last.titleize.downcase.sub(/ association$/, '') association = "embeds #{association}" if obje...
[ "def", "awesome_mongo_mapper_association", "(", "object", ")", "return", "object", ".", "inspect", "if", "!", "defined?", "(", "::", "ActiveSupport", "::", "OrderedHash", ")", "return", "awesome_object", "(", "object", ")", "if", "@options", "[", ":raw", "]", ...
Format MongoMapper association object. ------------------------------------------------------------------------------
[ "Format", "MongoMapper", "association", "object", ".", "------------------------------------------------------------------------------" ]
4564fd74721562cbef2443f7d97109bf9192343d
https://github.com/awesome-print/awesome_print/blob/4564fd74721562cbef2443f7d97109bf9192343d/lib/awesome_print/ext/mongo_mapper.rb#L95-L104
train
Returns a string representation of the association of the given object.
[ 30522, 13366, 12476, 1035, 12256, 3995, 1035, 4949, 4842, 1035, 2523, 1006, 4874, 1007, 2709, 4874, 1012, 22459, 2065, 999, 4225, 1029, 1006, 1024, 1024, 3161, 6342, 9397, 11589, 1024, 1024, 3641, 14949, 2232, 1007, 2709, 12476, 1035, 4874,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_service_bus/lib/2015-08-01/generated/azure_mgmt_service_bus/queues.rb
Azure::ServiceBus::Mgmt::V2015_08_01.Queues.get_with_http_info
def get_with_http_info(resource_group_name, namespace_name, queue_name, custom_headers:nil) get_async(resource_group_name, namespace_name, queue_name, custom_headers:custom_headers).value! end
ruby
def get_with_http_info(resource_group_name, namespace_name, queue_name, custom_headers:nil) get_async(resource_group_name, namespace_name, queue_name, custom_headers:custom_headers).value! end
[ "def", "get_with_http_info", "(", "resource_group_name", ",", "namespace_name", ",", "queue_name", ",", "custom_headers", ":", "nil", ")", "get_async", "(", "resource_group_name", ",", "namespace_name", ",", "queue_name", ",", "custom_headers", ":custom_headers", ")", ...
Returns a description for the specified queue. @param resource_group_name [String] Name of the Resource group within the Azure subscription. @param namespace_name [String] The namespace name @param queue_name [String] The queue name. @param custom_headers [Hash{String => String}] A hash of custom headers that wi...
[ "Returns", "a", "description", "for", "the", "specified", "queue", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_service_bus/lib/2015-08-01/generated/azure_mgmt_service_bus/queues.rb#L365-L367
train
Gets the sequence of elements in the queue.
[ 30522, 13366, 2131, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3415, 15327, 1035, 2171, 1010, 24240, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2131, 1035, 2004, 6038, 2278, 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...