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_search/lib/2015-08-19/generated/azure_mgmt_search/query_keys.rb
Azure::Search::Mgmt::V2015_08_19.QueryKeys.create
def create(resource_group_name, search_service_name, name, search_management_request_options:nil, custom_headers:nil) response = create_async(resource_group_name, search_service_name, name, search_management_request_options:search_management_request_options, custom_headers:custom_headers).value! response.bo...
ruby
def create(resource_group_name, search_service_name, name, search_management_request_options:nil, custom_headers:nil) response = create_async(resource_group_name, search_service_name, name, search_management_request_options:search_management_request_options, custom_headers:custom_headers).value! response.bo...
[ "def", "create", "(", "resource_group_name", ",", "search_service_name", ",", "name", ",", "search_management_request_options", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_async", "(", "resource_group_name", ",", "search_service_name", ...
Generates a new query key for the specified Search service. You can create up to 50 query keys per service. @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 [S...
[ "Generates", "a", "new", "query", "key", "for", "the", "specified", "Search", "service", ".", "You", "can", "create", "up", "to", "50", "query", "keys", "per", "service", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_search/lib/2015-08-19/generated/azure_mgmt_search/query_keys.rb#L41-L44
train
Creates a new search service.
[ 30522, 13366, 3443, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3945, 1035, 2326, 1035, 2171, 1010, 2171, 1010, 3945, 1035, 2968, 1035, 5227, 1035, 7047, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 3...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/hub_virtual_network_connections.rb
Azure::Network::Mgmt::V2018_07_01.HubVirtualNetworkConnections.get_with_http_info
def get_with_http_info(resource_group_name, virtual_hub_name, connection_name, custom_headers:nil) get_async(resource_group_name, virtual_hub_name, connection_name, custom_headers:custom_headers).value! end
ruby
def get_with_http_info(resource_group_name, virtual_hub_name, connection_name, custom_headers:nil) get_async(resource_group_name, virtual_hub_name, connection_name, custom_headers:custom_headers).value! end
[ "def", "get_with_http_info", "(", "resource_group_name", ",", "virtual_hub_name", ",", "connection_name", ",", "custom_headers", ":", "nil", ")", "get_async", "(", "resource_group_name", ",", "virtual_hub_name", ",", "connection_name", ",", "custom_headers", ":custom_head...
Retrieves the details of a HubVirtualNetworkConnection. @param resource_group_name [String] The resource group name of the VirtualHub. @param virtual_hub_name [String] The name of the VirtualHub. @param connection_name [String] The name of the vpn connection. @param custom_headers [Hash{String => String}] A hash ...
[ "Retrieves", "the", "details", "of", "a", "HubVirtualNetworkConnection", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-07-01/generated/azure_mgmt_network/hub_virtual_network_connections.rb#L53-L55
train
Gets the specified virtual hub connection.
[ 30522, 13366, 2131, 1035, 2007, 30524, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 7484, 1035, 9594, 1035, 2171, 1010, 4434, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2131, 1035, 2004, 6038, 2278, 1006, 7692, 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...
cloudfoundry/bosh
src/bosh-director/lib/bosh/director/nats_rpc.rb
Bosh::Director.NatsRpc.send_message
def send_message(client, payload) message = JSON.generate(payload) @logger.debug("SENT: #{client} #{message}") EM.schedule do nats.publish(client, message) end end
ruby
def send_message(client, payload) message = JSON.generate(payload) @logger.debug("SENT: #{client} #{message}") EM.schedule do nats.publish(client, message) end end
[ "def", "send_message", "(", "client", ",", "payload", ")", "message", "=", "JSON", ".", "generate", "(", "payload", ")", "@logger", ".", "debug", "(", "\"SENT: #{client} #{message}\"", ")", "EM", ".", "schedule", "do", "nats", ".", "publish", "(", "client", ...
Publishes a payload (encoded as JSON) without expecting a response
[ "Publishes", "a", "payload", "(", "encoded", "as", "JSON", ")", "without", "expecting", "a", "response" ]
2eaa7100879ddd20cd909cd698514746195e28b7
https://github.com/cloudfoundry/bosh/blob/2eaa7100879ddd20cd909cd698514746195e28b7/src/bosh-director/lib/bosh/director/nats_rpc.rb#L30-L37
train
Send a message to a client
[ 30522, 13366, 4604, 1035, 4471, 1006, 7396, 1010, 18093, 1007, 4471, 1027, 1046, 3385, 1012, 9699, 1006, 18093, 1007, 1030, 8833, 4590, 1012, 2139, 8569, 2290, 1006, 1000, 2741, 1024, 1001, 1063, 7396, 1065, 1001, 1063, 4471, 1065, 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...
getsentry/raven-ruby
lib/raven/integrations/rack.rb
Raven.RackInterface.read_data_from
def read_data_from(request) if request.form_data? request.POST elsif request.body # JSON requests, etc data = request.body.read(4096 * 4) # Sentry server limit request.body.rewind data end rescue IOError => ex ex.message end
ruby
def read_data_from(request) if request.form_data? request.POST elsif request.body # JSON requests, etc data = request.body.read(4096 * 4) # Sentry server limit request.body.rewind data end rescue IOError => ex ex.message end
[ "def", "read_data_from", "(", "request", ")", "if", "request", ".", "form_data?", "request", ".", "POST", "elsif", "request", ".", "body", "# JSON requests, etc", "data", "=", "request", ".", "body", ".", "read", "(", "4096", "*", "4", ")", "# Sentry server ...
See Sentry server default limits at https://github.com/getsentry/sentry/blob/master/src/sentry/conf/server.py
[ "See", "Sentry", "server", "default", "limits", "at", "https", ":", "//", "github", ".", "com", "/", "getsentry", "/", "sentry", "/", "blob", "/", "master", "/", "src", "/", "sentry", "/", "conf", "/", "server", ".", "py" ]
729c22f9284939695f14822683bff1a0b72502bd
https://github.com/getsentry/raven-ruby/blob/729c22f9284939695f14822683bff1a0b72502bd/lib/raven/integrations/rack.rb#L87-L97
train
Reads the data from the request body and returns the result as a string.
[ 30522, 13366, 3191, 1035, 2951, 1035, 2013, 1006, 5227, 1007, 2065, 5227, 1012, 2433, 1035, 2951, 1029, 5227, 1012, 2695, 3449, 5332, 2546, 5227, 1012, 2303, 1001, 1046, 3385, 11186, 1010, 4385, 2951, 1027, 5227, 1012, 2303, 1012, 3191, 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...
mongodb/mongoid
lib/mongoid/atomic.rb
Mongoid.Atomic.atomic_unsets
def atomic_unsets unsets = [] delayed_atomic_unsets.each_pair do |name, docs| path = nil docs.each do |doc| path ||= doc.flag_as_destroyed end unsets.push(path || name) end unsets end
ruby
def atomic_unsets unsets = [] delayed_atomic_unsets.each_pair do |name, docs| path = nil docs.each do |doc| path ||= doc.flag_as_destroyed end unsets.push(path || name) end unsets end
[ "def", "atomic_unsets", "unsets", "=", "[", "]", "delayed_atomic_unsets", ".", "each_pair", "do", "|", "name", ",", "docs", "|", "path", "=", "nil", "docs", ".", "each", "do", "|", "doc", "|", "path", "||=", "doc", ".", "flag_as_destroyed", "end", "unset...
Get all the attributes that need to be unset. @example Get the unsets. person.atomic_unsets @return [ Array<Hash> ] The $unset operations. @since 2.2.0
[ "Get", "all", "the", "attributes", "that", "need", "to", "be", "unset", "." ]
56976e32610f4c2450882b0bfe14da099f0703f4
https://github.com/mongodb/mongoid/blob/56976e32610f4c2450882b0bfe14da099f0703f4/lib/mongoid/atomic.rb#L249-L259
train
Returns the set of deleted documents.
[ 30522, 13366, 9593, 1035, 4895, 13462, 2015, 4895, 13462, 2015, 1027, 1031, 1033, 8394, 1035, 9593, 1035, 4895, 13462, 2015, 1012, 2169, 1035, 3940, 2079, 1064, 2171, 1010, 9986, 2015, 1064, 4130, 1027, 9152, 2140, 9986, 2015, 1012, 2169, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.get_certificate_versions_with_http_info
def get_certificate_versions_with_http_info(vault_base_url, certificate_name, maxresults:nil, custom_headers:nil) get_certificate_versions_async(vault_base_url, certificate_name, maxresults:maxresults, custom_headers:custom_headers).value! end
ruby
def get_certificate_versions_with_http_info(vault_base_url, certificate_name, maxresults:nil, custom_headers:nil) get_certificate_versions_async(vault_base_url, certificate_name, maxresults:maxresults, custom_headers:custom_headers).value! end
[ "def", "get_certificate_versions_with_http_info", "(", "vault_base_url", ",", "certificate_name", ",", "maxresults", ":", "nil", ",", "custom_headers", ":", "nil", ")", "get_certificate_versions_async", "(", "vault_base_url", ",", "certificate_name", ",", "maxresults", ":...
List the versions of a certificate. The GetCertificateVersions operation returns the versions of a certificate in the specified key vault. This operation requires the certificates/list permission. @param vault_base_url [String] The vault name, for example https://myvault.vault.azure.net. @param certificate_name...
[ "List", "the", "versions", "of", "a", "certificate", "." ]
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#L5478-L5480
train
Gets the versions of the certificate in the specified vault.
[ 30522, 13366, 2131, 1035, 8196, 1035, 4617, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 11632, 1035, 2918, 1035, 24471, 2140, 1010, 8196, 1035, 2171, 1010, 4098, 6072, 11314, 2015, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_sql/lib/2017-03-01-preview/generated/azure_mgmt_sql/job_executions.rb
Azure::SQL::Mgmt::V2017_03_01_preview.JobExecutions.list_by_job_as_lazy
def list_by_job_as_lazy(resource_group_name, server_name, job_agent_name, job_name, create_time_min:nil, create_time_max:nil, end_time_min:nil, end_time_max:nil, is_active:nil, skip:nil, top:nil, custom_headers:nil) response = list_by_job_async(resource_group_name, server_name, job_agent_name, job_name, create_ti...
ruby
def list_by_job_as_lazy(resource_group_name, server_name, job_agent_name, job_name, create_time_min:nil, create_time_max:nil, end_time_min:nil, end_time_max:nil, is_active:nil, skip:nil, top:nil, custom_headers:nil) response = list_by_job_async(resource_group_name, server_name, job_agent_name, job_name, create_ti...
[ "def", "list_by_job_as_lazy", "(", "resource_group_name", ",", "server_name", ",", "job_agent_name", ",", "job_name", ",", "create_time_min", ":", "nil", ",", "create_time_max", ":", "nil", ",", "end_time_min", ":", "nil", ",", "end_time_max", ":", "nil", ",", "...
Lists a job's executions. @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 job_agent_name [String] The name of the job agent. @para...
[ "Lists", "a", "job", "s", "executions", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_sql/lib/2017-03-01-preview/generated/azure_mgmt_sql/job_executions.rb#L1089-L1098
train
Gets the list of all the image files in a job agent.
[ 30522, 13366, 2862, 1035, 2011, 1035, 3105, 1035, 2004, 1035, 13971, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8241, 1035, 2171, 1010, 3105, 1035, 4005, 1035, 2171, 1010, 3105, 1035, 2171, 1010, 3443, 1035, 2051, 1035, 8117, 1024, 9152, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_web/lib/2018-02-01/generated/azure_mgmt_web/resource_health_metadata_operations.rb
Azure::Web::Mgmt::V2018_02_01.ResourceHealthMetadataOperations.list_by_site_slot
def list_by_site_slot(resource_group_name, name, slot, custom_headers:nil) first_page = list_by_site_slot_as_lazy(resource_group_name, name, slot, custom_headers:custom_headers) first_page.get_all_items end
ruby
def list_by_site_slot(resource_group_name, name, slot, custom_headers:nil) first_page = list_by_site_slot_as_lazy(resource_group_name, name, slot, custom_headers:custom_headers) first_page.get_all_items end
[ "def", "list_by_site_slot", "(", "resource_group_name", ",", "name", ",", "slot", ",", "custom_headers", ":", "nil", ")", "first_page", "=", "list_by_site_slot_as_lazy", "(", "resource_group_name", ",", "name", ",", "slot", ",", "custom_headers", ":custom_headers", ...
Gets the category of ResourceHealthMetadata to use for the given site as a collection Gets the category of ResourceHealthMetadata to use for the given site as a collection @param resource_group_name [String] Name of the resource group to which the resource belongs. @param name [String] Name of web app. @param ...
[ "Gets", "the", "category", "of", "ResourceHealthMetadata", "to", "use", "for", "the", "given", "site", "as", "a", "collection" ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_web/lib/2018-02-01/generated/azure_mgmt_web/resource_health_metadata_operations.rb#L451-L454
train
Gets all the vulnerability assessment of a site.
[ 30522, 13366, 2862, 1035, 2011, 1035, 2609, 1035, 10453, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2171, 1010, 10453, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2034, 1035, 3931, 1027, 2862, 1035, 2011, 1035, 2609, 1035, 10453, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
amatsuda/active_decorator
lib/active_decorator/decorator.rb
ActiveDecorator.Decorator.decorator_for
def decorator_for(model_class) return @@decorators[model_class] if @@decorators.key? model_class decorator_name = "#{model_class.name}#{ActiveDecorator.config.decorator_suffix}" d = Object.const_get decorator_name, false unless Class === d d.send :include, ActiveDecorator::Helpers ...
ruby
def decorator_for(model_class) return @@decorators[model_class] if @@decorators.key? model_class decorator_name = "#{model_class.name}#{ActiveDecorator.config.decorator_suffix}" d = Object.const_get decorator_name, false unless Class === d d.send :include, ActiveDecorator::Helpers ...
[ "def", "decorator_for", "(", "model_class", ")", "return", "@@decorators", "[", "model_class", "]", "if", "@@decorators", ".", "key?", "model_class", "decorator_name", "=", "\"#{model_class.name}#{ActiveDecorator.config.decorator_suffix}\"", "d", "=", "Object", ".", "cons...
Returns a decorator module for the given class. Returns `nil` if no decorator module was found.
[ "Returns", "a", "decorator", "module", "for", "the", "given", "class", ".", "Returns", "nil", "if", "no", "decorator", "module", "was", "found", "." ]
e7cfa764e657ea8bbb4cbe92cb220ee67ebae58e
https://github.com/amatsuda/active_decorator/blob/e7cfa764e657ea8bbb4cbe92cb220ee67ebae58e/lib/active_decorator/decorator.rb#L68-L87
train
Returns the class that is decorated with the given model class.
[ 30522, 13366, 25545, 8844, 1035, 2005, 1006, 2944, 1035, 2465, 1007, 2709, 1030, 1030, 25545, 18926, 1031, 2944, 1035, 2465, 1033, 2065, 1030, 1030, 25545, 18926, 1012, 3145, 1029, 2944, 1035, 2465, 25545, 8844, 1035, 2171, 1027, 1000, 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...
sporkmonger/addressable
lib/addressable/uri.rb
Addressable.URI.split_path
def split_path(path) splitted = path.split(SLASH) splitted << EMPTY_STR if path.end_with? SLASH splitted end
ruby
def split_path(path) splitted = path.split(SLASH) splitted << EMPTY_STR if path.end_with? SLASH splitted end
[ "def", "split_path", "(", "path", ")", "splitted", "=", "path", ".", "split", "(", "SLASH", ")", "splitted", "<<", "EMPTY_STR", "if", "path", ".", "end_with?", "SLASH", "splitted", "end" ]
Splits path string with "/" (slash). It is considered that there is empty string after last slash when path ends with slash. @param [String] path The path to split. @return [Array<String>] An array of parts of path.
[ "Splits", "path", "string", "with", "/", "(", "slash", ")", ".", "It", "is", "considered", "that", "there", "is", "empty", "string", "after", "last", "slash", "when", "path", "ends", "with", "slash", "." ]
5894c95a7768435cb46d1355954611dbd194832e
https://github.com/sporkmonger/addressable/blob/5894c95a7768435cb46d1355954611dbd194832e/lib/addressable/uri.rb#L2495-L2499
train
Split a path into its components.
[ 30522, 13366, 3975, 1035, 4130, 1006, 4130, 1007, 3975, 3064, 1027, 4130, 1012, 3975, 1006, 18296, 1007, 3975, 3064, 1026, 1026, 4064, 1035, 2358, 2099, 2065, 4130, 1012, 2203, 1035, 2007, 1029, 18296, 3975, 3064, 2203, 102, 0, 0, 0, 0,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-ruby
gems/aws-sdk-ec2/lib/aws-sdk-ec2/subnet.rb
Aws::EC2.Subnet.create_instances
def create_instances(options = {}) batch = [] options = options.merge(subnet_id: @id) resp = @client.run_instances(options) resp.data.instances.each do |i| batch << Instance.new( id: i.instance_id, data: i, client: @client ) end Instance:...
ruby
def create_instances(options = {}) batch = [] options = options.merge(subnet_id: @id) resp = @client.run_instances(options) resp.data.instances.each do |i| batch << Instance.new( id: i.instance_id, data: i, client: @client ) end Instance:...
[ "def", "create_instances", "(", "options", "=", "{", "}", ")", "batch", "=", "[", "]", "options", "=", "options", ".", "merge", "(", "subnet_id", ":", "@id", ")", "resp", "=", "@client", ".", "run_instances", "(", "options", ")", "resp", ".", "data", ...
@!group Actions @example Request syntax with placeholder values instance = subnet.create_instances({ block_device_mappings: [ { device_name: "String", virtual_name: "String", ebs: { delete_on_termination: false, iops: 1, snapshot_id: "String",...
[ "@!group", "Actions", "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-ec2/lib/aws-sdk-ec2/subnet.rb#L643-L655
train
Creates a new instance in the subnet.
[ 30522, 13366, 3443, 1035, 12107, 1006, 7047, 1027, 1063, 1065, 1007, 14108, 1027, 1031, 1033, 7047, 1027, 7047, 1012, 13590, 1006, 4942, 7159, 1035, 8909, 1024, 1030, 8909, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 2448, 1035, 12107, 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...
hanami/hanami
lib/hanami/server.rb
Hanami.Server.middleware
def middleware mw = Hash.new { |e, m| e[m] = [] } mw["development"].concat([::Rack::ShowExceptions, ::Rack::Lint]) require 'hanami/assets/static' mw["development"].push(::Hanami::Assets::Static) mw end
ruby
def middleware mw = Hash.new { |e, m| e[m] = [] } mw["development"].concat([::Rack::ShowExceptions, ::Rack::Lint]) require 'hanami/assets/static' mw["development"].push(::Hanami::Assets::Static) mw end
[ "def", "middleware", "mw", "=", "Hash", ".", "new", "{", "|", "e", ",", "m", "|", "e", "[", "m", "]", "=", "[", "]", "}", "mw", "[", "\"development\"", "]", ".", "concat", "(", "[", "::", "Rack", "::", "ShowExceptions", ",", "::", "Rack", "::",...
@since 0.8.0 @api private @see Hanami::Environment#initialize Primarily this removes the ::Rack::Chunked middleware which is the cause of Safari content-length bugs. @since 0.8.0
[ "@since", "0", ".", "8", ".", "0", "@api", "private" ]
8c6e5147e92ef869b25379448572da3698eacfdc
https://github.com/hanami/hanami/blob/8c6e5147e92ef869b25379448572da3698eacfdc/lib/hanami/server.rb#L32-L38
train
Returns a hash of middleware to use for the middleware
[ 30522, 13366, 2690, 8059, 12464, 1027, 23325, 1012, 2047, 1063, 1064, 1041, 1010, 1049, 1064, 1041, 1031, 1049, 1033, 1027, 1031, 1033, 1065, 12464, 1031, 1000, 2458, 1000, 1033, 1012, 9530, 11266, 1006, 1031, 1024, 1024, 14513, 1024, 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_batch/lib/2017-09-01/generated/azure_mgmt_batch/certificate_operations.rb
Azure::Batch::Mgmt::V2017_09_01.CertificateOperations.begin_delete_with_http_info
def begin_delete_with_http_info(resource_group_name, account_name, certificate_name, custom_headers:nil) begin_delete_async(resource_group_name, account_name, certificate_name, custom_headers:custom_headers).value! end
ruby
def begin_delete_with_http_info(resource_group_name, account_name, certificate_name, custom_headers:nil) begin_delete_async(resource_group_name, account_name, certificate_name, custom_headers:custom_headers).value! end
[ "def", "begin_delete_with_http_info", "(", "resource_group_name", ",", "account_name", ",", "certificate_name", ",", "custom_headers", ":", "nil", ")", "begin_delete_async", "(", "resource_group_name", ",", "account_name", ",", "certificate_name", ",", "custom_headers", "...
Deletes the specified certificate. @param resource_group_name [String] The name of the resource group that contains the Batch account. @param account_name [String] The name of the Batch account. @param certificate_name [String] The identifier for the certificate. This must be made up of algorithm and thumbprint s...
[ "Deletes", "the", "specified", "certificate", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_batch/lib/2017-09-01/generated/azure_mgmt_batch/certificate_operations.rb#L821-L823
train
Deletes a certificate.
[ 30522, 13366, 4088, 1035, 3972, 12870, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 4070, 1035, 2171, 1010, 8196, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 4088, 1035, 3972, 12870, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
pythonicrubyist/creek
lib/creek/sheet.rb
Creek.Creek::Sheet.rows_generator
def rows_generator include_meta_data=false, use_simple_rows_format=false path = if @sheetfile.start_with? "/xl/" or @sheetfile.start_with? "xl/" then @sheetfile else "xl/#{@sheetfile}" end if @book.files.file.exist?(path) # SAX parsing, Each element in the stream comes through as two events: ...
ruby
def rows_generator include_meta_data=false, use_simple_rows_format=false path = if @sheetfile.start_with? "/xl/" or @sheetfile.start_with? "xl/" then @sheetfile else "xl/#{@sheetfile}" end if @book.files.file.exist?(path) # SAX parsing, Each element in the stream comes through as two events: ...
[ "def", "rows_generator", "include_meta_data", "=", "false", ",", "use_simple_rows_format", "=", "false", "path", "=", "if", "@sheetfile", ".", "start_with?", "\"/xl/\"", "or", "@sheetfile", ".", "start_with?", "\"xl/\"", "then", "@sheetfile", "else", "\"xl/#{@sheetfil...
Returns a hash per row that includes the cell ids and values. Empty cells will be also included in the hash with a nil value.
[ "Returns", "a", "hash", "per", "row", "that", "includes", "the", "cell", "ids", "and", "values", ".", "Empty", "cells", "will", "be", "also", "included", "in", "the", "hash", "with", "a", "nil", "value", "." ]
1a5c99032ee736e8f24ebd524adffba068d236b4
https://github.com/pythonicrubyist/creek/blob/1a5c99032ee736e8f24ebd524adffba068d236b4/lib/creek/sheet.rb#L83-L127
train
Returns an enumerator of rows from the workbook.
[ 30522, 13366, 10281, 1035, 13103, 2421, 1035, 18804, 1035, 2951, 1027, 6270, 1010, 2224, 1035, 3722, 1035, 10281, 1035, 4289, 1027, 6270, 4130, 1027, 2065, 1030, 7123, 8873, 2571, 1012, 2707, 1035, 2007, 1029, 1000, 1013, 28712, 1013, 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...
markdownlint/markdownlint
lib/mdl/doc.rb
MarkdownLint.Doc.header_style
def header_style(header) if header.type != :header raise "header_style called with non-header element" end line = element_line(header) if line.start_with?("#") if line.strip.end_with?("#") :atx_closed else :atx end else :setext ...
ruby
def header_style(header) if header.type != :header raise "header_style called with non-header element" end line = element_line(header) if line.start_with?("#") if line.strip.end_with?("#") :atx_closed else :atx end else :setext ...
[ "def", "header_style", "(", "header", ")", "if", "header", ".", "type", "!=", ":header", "raise", "\"header_style called with non-header element\"", "end", "line", "=", "element_line", "(", "header", ")", "if", "line", ".", "start_with?", "(", "\"#\"", ")", "if"...
Returns the header 'style' - :atx (hashes at the beginning), :atx_closed (atx header style, but with hashes at the end of the line also), :setext (underlined). You can pass in the element object or an options hash here.
[ "Returns", "the", "header", "style", "-", ":", "atx", "(", "hashes", "at", "the", "beginning", ")", ":", "atx_closed", "(", "atx", "header", "style", "but", "with", "hashes", "at", "the", "end", "of", "the", "line", "also", ")", ":", "setext", "(", "...
a9e80fcf3989d73b654b00bb2225a00be53983e8
https://github.com/markdownlint/markdownlint/blob/a9e80fcf3989d73b654b00bb2225a00be53983e8/lib/mdl/doc.rb#L168-L182
train
Returns the header style for the given header element.
[ 30522, 13366, 20346, 1035, 2806, 1006, 20346, 1007, 2065, 20346, 1012, 2828, 999, 1027, 1024, 20346, 5333, 1000, 20346, 1035, 2806, 2170, 2007, 2512, 1011, 20346, 5783, 1000, 2203, 2240, 1027, 5783, 1035, 2240, 1006, 20346, 1007, 2065, 2240...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
backup/backup
lib/backup/logger.rb
Backup.Logger.abort!
def abort! console = Console.new console.log(messages.shift) until messages.empty? end
ruby
def abort! console = Console.new console.log(messages.shift) until messages.empty? end
[ "def", "abort!", "console", "=", "Console", ".", "new", "console", ".", "log", "(", "messages", ".", "shift", ")", "until", "messages", ".", "empty?", "end" ]
If errors are encountered by Backup::CLI while preparing to perform the backup jobs, this method is called to dump all messages to the console before Backup exits.
[ "If", "errors", "are", "encountered", "by", "Backup", "::", "CLI", "while", "preparing", "to", "perform", "the", "backup", "jobs", "this", "method", "is", "called", "to", "dump", "all", "messages", "to", "the", "console", "before", "Backup", "exits", "." ]
64370f925e859f858766b674717a3dbee0de7a26
https://github.com/backup/backup/blob/64370f925e859f858766b674717a3dbee0de7a26/lib/backup/logger.rb#L177-L180
train
Aborts the current request.
[ 30522, 13366, 11113, 11589, 999, 10122, 1027, 10122, 1012, 2047, 10122, 1012, 8833, 1006, 7696, 1012, 5670, 1007, 2127, 7696, 1012, 4064, 1029, 2203, 102, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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
frameit/lib/frameit/editor.rb
Frameit.Editor.complex_framing
def complex_framing background = generate_background self.space_to_device = vertical_frame_padding if fetch_config['title'] background = put_title_into_background(background, fetch_config['stack_title']) end if self.frame # we have no frame on le mac resize_frame! ...
ruby
def complex_framing background = generate_background self.space_to_device = vertical_frame_padding if fetch_config['title'] background = put_title_into_background(background, fetch_config['stack_title']) end if self.frame # we have no frame on le mac resize_frame! ...
[ "def", "complex_framing", "background", "=", "generate_background", "self", ".", "space_to_device", "=", "vertical_frame_padding", "if", "fetch_config", "[", "'title'", "]", "background", "=", "put_title_into_background", "(", "background", ",", "fetch_config", "[", "'s...
more complex mode: background, frame and title
[ "more", "complex", "mode", ":", "background", "frame", "and", "title" ]
457c5d647c77f0e078dafa5129da616914e002c5
https://github.com/fastlane/fastlane/blob/457c5d647c77f0e078dafa5129da616914e002c5/frameit/lib/frameit/editor.rb#L155-L190
train
This method is used to generate the framing image
[ 30522, 13366, 3375, 1035, 20241, 4281, 1027, 9699, 1035, 4281, 2969, 1012, 2686, 1035, 2000, 1035, 5080, 1027, 7471, 1035, 4853, 1035, 11687, 4667, 2065, 18584, 1035, 9530, 8873, 2290, 1031, 1005, 2516, 1005, 1033, 4281, 1027, 2404, 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_scheduler/lib/2016-03-01/generated/azure_mgmt_scheduler/jobs.rb
Azure::Scheduler::Mgmt::V2016_03_01.Jobs.list_job_history_next
def list_job_history_next(next_page_link, custom_headers:nil) response = list_job_history_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_job_history_next(next_page_link, custom_headers:nil) response = list_job_history_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_job_history_next", "(", "next_page_link", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_job_history_next_async", "(", "next_page_link", ",", "custom_headers", ":custom_headers", ")", ".", "value!", "response", ".", "body", "unless", "resp...
Lists job history. @param next_page_link [String] The NextLink from the previous successful call to List operation. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [JobHistoryListResult] operation results.
[ "Lists", "job", "history", "." ]
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#L834-L837
train
Gets the job history of the current job.
[ 30522, 13366, 2862, 1035, 3105, 1035, 2381, 1035, 2279, 1006, 2279, 1035, 3931, 1035, 4957, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 3105, 1035, 2381, 1035, 2279, 1035, 2004, 6038, 2278, 1006, 2279, 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_search/lib/2015-08-19/generated/azure_mgmt_search/query_keys.rb
Azure::Search::Mgmt::V2015_08_19.QueryKeys.list_by_search_service_with_http_info
def list_by_search_service_with_http_info(resource_group_name, search_service_name, search_management_request_options:nil, custom_headers:nil) list_by_search_service_async(resource_group_name, search_service_name, search_management_request_options:search_management_request_options, custom_headers:custom_headers)....
ruby
def list_by_search_service_with_http_info(resource_group_name, search_service_name, search_management_request_options:nil, custom_headers:nil) list_by_search_service_async(resource_group_name, search_service_name, search_management_request_options:search_management_request_options, custom_headers:custom_headers)....
[ "def", "list_by_search_service_with_http_info", "(", "resource_group_name", ",", "search_service_name", ",", "search_management_request_options", ":", "nil", ",", "custom_headers", ":", "nil", ")", "list_by_search_service_async", "(", "resource_group_name", ",", "search_service...
Returns the list of query API keys for the given Azure Search service. @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 of the Azure Search se...
[ "Returns", "the", "list", "of", "query", "API", "keys", "for", "the", "given", "Azure", "Search", "service", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_search/lib/2015-08-19/generated/azure_mgmt_search/query_keys.rb#L178-L180
train
Gets the list of the documents in a search service.
[ 30522, 13366, 2862, 1035, 2011, 1035, 3945, 1035, 2326, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3945, 1035, 2326, 1035, 2171, 1010, 3945, 1035, 2968, 1035, 5227, 1035, 7047, 1024, 9152, 2140, 1010, 7...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/core.rb
ActiveRecord.Core.init_with_attributes
def init_with_attributes(attributes, new_record = false) # :nodoc: @new_record = new_record @attributes = attributes init_internals yield self if block_given? _run_find_callbacks _run_initialize_callbacks self end
ruby
def init_with_attributes(attributes, new_record = false) # :nodoc: @new_record = new_record @attributes = attributes init_internals yield self if block_given? _run_find_callbacks _run_initialize_callbacks self end
[ "def", "init_with_attributes", "(", "attributes", ",", "new_record", "=", "false", ")", "# :nodoc:", "@new_record", "=", "new_record", "@attributes", "=", "attributes", "init_internals", "yield", "self", "if", "block_given?", "_run_find_callbacks", "_run_initialize_callba...
Initialize an empty model object from +attributes+. +attributes+ should be an attributes object, and unlike the `initialize` method, no assignment calls are made per attribute.
[ "Initialize", "an", "empty", "model", "object", "from", "+", "attributes", "+", ".", "+", "attributes", "+", "should", "be", "an", "attributes", "object", "and", "unlike", "the", "initialize", "method", "no", "assignment", "calls", "are", "made", "per", "att...
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activerecord/lib/active_record/core.rb#L356-L368
train
Initialize the object with the given attributes.
[ 30522, 13366, 1999, 4183, 1035, 2007, 1035, 12332, 1006, 12332, 1010, 2047, 1035, 2501, 1027, 6270, 1007, 1001, 1024, 7293, 10085, 1024, 1030, 2047, 1035, 2501, 1027, 2047, 1035, 2501, 1030, 12332, 1027, 12332, 1999, 4183, 1035, 4722, 2015,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_container_service/lib/2019-02-01/generated/azure_mgmt_container_service/agent_pools.rb
Azure::ContainerService::Mgmt::V2019_02_01.AgentPools.get_with_http_info
def get_with_http_info(resource_group_name, managed_cluster_name, agent_pool_name, custom_headers:nil) get_async(resource_group_name, managed_cluster_name, agent_pool_name, custom_headers:custom_headers).value! end
ruby
def get_with_http_info(resource_group_name, managed_cluster_name, agent_pool_name, custom_headers:nil) get_async(resource_group_name, managed_cluster_name, agent_pool_name, custom_headers:custom_headers).value! end
[ "def", "get_with_http_info", "(", "resource_group_name", ",", "managed_cluster_name", ",", "agent_pool_name", ",", "custom_headers", ":", "nil", ")", "get_async", "(", "resource_group_name", ",", "managed_cluster_name", ",", "agent_pool_name", ",", "custom_headers", ":cus...
Gets the agent pool. Gets the details of the agent pool by managed cluster and resource group. @param resource_group_name [String] The name of the resource group. @param managed_cluster_name [String] The name of the managed cluster resource. @param agent_pool_name [String] The name of the agent pool. @param cus...
[ "Gets", "the", "agent", "pool", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_container_service/lib/2019-02-01/generated/azure_mgmt_container_service/agent_pools.rb#L162-L164
train
Gets the specified managed cluster agent pool.
[ 30522, 13366, 2131, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3266, 1035, 9324, 1035, 2171, 1010, 4005, 1035, 4770, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2131, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
seejohnrun/ice_cube
lib/ice_cube/schedule.rb
IceCube.Schedule.previous_occurrences
def previous_occurrences(num, from) from = TimeUtil.match_zone(from, start_time) or raise ArgumentError, "Time required, got #{from.inspect}" return [] if from <= start_time a = enumerate_occurrences(start_time, from - 1).to_a a.size > num ? a[-1*num,a.size] : a end
ruby
def previous_occurrences(num, from) from = TimeUtil.match_zone(from, start_time) or raise ArgumentError, "Time required, got #{from.inspect}" return [] if from <= start_time a = enumerate_occurrences(start_time, from - 1).to_a a.size > num ? a[-1*num,a.size] : a end
[ "def", "previous_occurrences", "(", "num", ",", "from", ")", "from", "=", "TimeUtil", ".", "match_zone", "(", "from", ",", "start_time", ")", "or", "raise", "ArgumentError", ",", "\"Time required, got #{from.inspect}\"", "return", "[", "]", "if", "from", "<=", ...
The previous n occurrences before a given time
[ "The", "previous", "n", "occurrences", "before", "a", "given", "time" ]
fb6c657bdc4f87dfda2bf83f15c5f487b78ccabd
https://github.com/seejohnrun/ice_cube/blob/fb6c657bdc4f87dfda2bf83f15c5f487b78ccabd/lib/ice_cube/schedule.rb#L192-L197
train
Returns the previous occurrences of the given number of times from the given time.
[ 30522, 13366, 3025, 1035, 27247, 1006, 16371, 2213, 1010, 2013, 1007, 2013, 1027, 2051, 21823, 2140, 1012, 2674, 1035, 4224, 1006, 2013, 1010, 2707, 1035, 2051, 1007, 2030, 5333, 6685, 2121, 29165, 1010, 1000, 2051, 3223, 1010, 2288, 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...
alexreisner/geocoder
lib/geocoder/results/geocoder_ca.rb
Geocoder::Result.GeocoderCa.canadian_province_abbreviations
def canadian_province_abbreviations %w[ON QC NS NB MB BC PE SK AB NL] end
ruby
def canadian_province_abbreviations %w[ON QC NS NB MB BC PE SK AB NL] end
[ "def", "canadian_province_abbreviations", "%w[", "ON", "QC", "NS", "NB", "MB", "BC", "PE", "SK", "AB", "NL", "]", "end" ]
----------------------------------------------------------------
[ "----------------------------------------------------------------" ]
e087dc2759264ee6f307b926bb2de4ec2406859e
https://github.com/alexreisner/geocoder/blob/e087dc2759264ee6f307b926bb2de4ec2406859e/lib/geocoder/results/geocoder_ca.rb#L56-L58
train
Returns the canadian province abbreviations for the given data
[ 30522, 13366, 3010, 1035, 2874, 1035, 22498, 2015, 1003, 1059, 1031, 2006, 25196, 24978, 1050, 30524, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
sunspot/sunspot
sunspot/lib/sunspot/setup.rb
Sunspot.Setup.add_text_field_factory
def add_text_field_factory(name, options = {}, &block) stored, more_like_this = options[:stored], options[:more_like_this] field_factory = FieldFactory::Static.new(name, Type::TextType.instance, options, &block) @text_field_factories[name] = field_factory @text_field_factories_cache[field_factor...
ruby
def add_text_field_factory(name, options = {}, &block) stored, more_like_this = options[:stored], options[:more_like_this] field_factory = FieldFactory::Static.new(name, Type::TextType.instance, options, &block) @text_field_factories[name] = field_factory @text_field_factories_cache[field_factor...
[ "def", "add_text_field_factory", "(", "name", ",", "options", "=", "{", "}", ",", "&", "block", ")", "stored", ",", "more_like_this", "=", "options", "[", ":stored", "]", ",", "options", "[", ":more_like_this", "]", "field_factory", "=", "FieldFactory", "::"...
Add field_factories for fulltext search ==== Parameters field_factories<Array>:: Array of Sunspot::Field objects
[ "Add", "field_factories", "for", "fulltext", "search" ]
31dd76cd7a14a4ef7bd541de97483d8cd72ff685
https://github.com/sunspot/sunspot/blob/31dd76cd7a14a4ef7bd541de97483d8cd72ff685/sunspot/lib/sunspot/setup.rb#L59-L70
train
Adds a text field factory to the document.
[ 30522, 13366, 5587, 1035, 3793, 1035, 2492, 1035, 4713, 1006, 2171, 1010, 7047, 1027, 1063, 1065, 1010, 1004, 3796, 1007, 8250, 1010, 2062, 1035, 2066, 1035, 2023, 1027, 7047, 1031, 1024, 8250, 1033, 1010, 7047, 1031, 1024, 2062, 1035, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_container_instance/lib/2018-09-01/generated/azure_mgmt_container_instance/container_operations.rb
Azure::ContainerInstance::Mgmt::V2018_09_01.ContainerOperations.list_logs
def list_logs(resource_group_name, container_group_name, container_name, tail:nil, custom_headers:nil) response = list_logs_async(resource_group_name, container_group_name, container_name, tail:tail, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_logs(resource_group_name, container_group_name, container_name, tail:nil, custom_headers:nil) response = list_logs_async(resource_group_name, container_group_name, container_name, tail:tail, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_logs", "(", "resource_group_name", ",", "container_group_name", ",", "container_name", ",", "tail", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_logs_async", "(", "resource_group_name", ",", "container_group_name", ",", "co...
Get the logs for a specified container instance. Get the logs for a specified container instance in a specified resource group and container group. @param resource_group_name [String] The name of the resource group. @param container_group_name [String] The name of the container group. @param container_name [Stri...
[ "Get", "the", "logs", "for", "a", "specified", "container", "instance", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_container_instance/lib/2018-09-01/generated/azure_mgmt_container_instance/container_operations.rb#L41-L44
train
Gets the logs for the specified container.
[ 30522, 13366, 2862, 1035, 15664, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 11661, 1035, 2177, 1035, 2171, 1010, 11661, 1035, 2171, 1010, 5725, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_web/lib/2015-08-01/generated/azure_mgmt_web/app_service_certificate_orders.rb
Azure::Web::Mgmt::V2015_08_01.AppServiceCertificateOrders.begin_create_or_update_certificate
def begin_create_or_update_certificate(resource_group_name, certificate_order_name, name, key_vault_certificate, custom_headers:nil) response = begin_create_or_update_certificate_async(resource_group_name, certificate_order_name, name, key_vault_certificate, custom_headers:custom_headers).value! response.bo...
ruby
def begin_create_or_update_certificate(resource_group_name, certificate_order_name, name, key_vault_certificate, custom_headers:nil) response = begin_create_or_update_certificate_async(resource_group_name, certificate_order_name, name, key_vault_certificate, custom_headers:custom_headers).value! response.bo...
[ "def", "begin_create_or_update_certificate", "(", "resource_group_name", ",", "certificate_order_name", ",", "name", ",", "key_vault_certificate", ",", "custom_headers", ":", "nil", ")", "response", "=", "begin_create_or_update_certificate_async", "(", "resource_group_name", ...
Creates or updates a certificate and associates with key vault secret. Creates or updates a certificate and associates with key vault secret. @param resource_group_name [String] Name of the resource group to which the resource belongs. @param certificate_order_name [String] Name of the certificate order. @param ...
[ "Creates", "or", "updates", "a", "certificate", "and", "associates", "with", "key", "vault", "secret", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_web/lib/2015-08-01/generated/azure_mgmt_web/app_service_certificate_orders.rb#L2181-L2184
train
Creates or updates a certificate in the specified certificate order.
[ 30522, 13366, 4088, 1035, 3443, 1035, 2030, 1035, 10651, 1035, 8196, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 8196, 1035, 2344, 1035, 2171, 1010, 2171, 1010, 3145, 1035, 11632, 1035, 8196, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_labservices/lib/2018-10-15/generated/azure_mgmt_labservices/users.rb
Azure::Labservices::Mgmt::V2018_10_15.Users.update
def update(resource_group_name, lab_account_name, lab_name, user_name, user, custom_headers:nil) response = update_async(resource_group_name, lab_account_name, lab_name, user_name, user, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def update(resource_group_name, lab_account_name, lab_name, user_name, user, custom_headers:nil) response = update_async(resource_group_name, lab_account_name, lab_name, user_name, user, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "update", "(", "resource_group_name", ",", "lab_account_name", ",", "lab_name", ",", "user_name", ",", "user", ",", "custom_headers", ":", "nil", ")", "response", "=", "update_async", "(", "resource_group_name", ",", "lab_account_name", ",", "lab_name", ","...
Modify properties of users. @param resource_group_name [String] The name of the resource group. @param lab_account_name [String] The name of the lab Account. @param lab_name [String] The name of the lab. @param user_name [String] The name of the user. @param user [UserFragment] The User registered to a lab @para...
[ "Modify", "properties", "of", "users", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_labservices/lib/2018-10-15/generated/azure_mgmt_labservices/users.rb#L423-L426
train
Updates a user s index.
[ 30522, 13366, 10651, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 6845, 1035, 4070, 1035, 2171, 1010, 6845, 1035, 2171, 1010, 5310, 1035, 2171, 1010, 5310, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 10651, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_policy_insights/lib/2018-04-04/generated/azure_mgmt_policy_insights/policy_states.rb
Azure::PolicyInsights::Mgmt::V2018_04_04.PolicyStates.list_query_results_for_resource_with_http_info
def list_query_results_for_resource_with_http_info(policy_states_resource, resource_id, query_options:nil, custom_headers:nil) list_query_results_for_resource_async(policy_states_resource, resource_id, query_options:query_options, custom_headers:custom_headers).value! end
ruby
def list_query_results_for_resource_with_http_info(policy_states_resource, resource_id, query_options:nil, custom_headers:nil) list_query_results_for_resource_async(policy_states_resource, resource_id, query_options:query_options, custom_headers:custom_headers).value! end
[ "def", "list_query_results_for_resource_with_http_info", "(", "policy_states_resource", ",", "resource_id", ",", "query_options", ":", "nil", ",", "custom_headers", ":", "nil", ")", "list_query_results_for_resource_async", "(", "policy_states_resource", ",", "resource_id", ",...
Queries policy states for the resource. @param policy_states_resource [PolicyStatesResource] The virtual resource under PolicyStates resource type. In a given time range, 'latest' represents the latest policy state(s), whereas 'default' represents all policy state(s). Possible values include: 'default', 'latest' ...
[ "Queries", "policy", "states", "for", "the", "resource", "." ]
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#L781-L783
train
Gets the list of policy states for the resource.
[ 30522, 13366, 2862, 1035, 23032, 1035, 3463, 1035, 2005, 1035, 7692, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 3343, 1035, 2163, 1035, 7692, 1010, 7692, 1035, 8909, 1010, 23032, 1035, 7047, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/model.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Model.get_explicit_list
def get_explicit_list(app_id, version_id, entity_id, custom_headers:nil) response = get_explicit_list_async(app_id, version_id, entity_id, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def get_explicit_list(app_id, version_id, entity_id, custom_headers:nil) response = get_explicit_list_async(app_id, version_id, entity_id, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "get_explicit_list", "(", "app_id", ",", "version_id", ",", "entity_id", ",", "custom_headers", ":", "nil", ")", "response", "=", "get_explicit_list_async", "(", "app_id", ",", "version_id", ",", "entity_id", ",", "custom_headers", ":custom_headers", ")", "...
Get the explicit (exception) list of the pattern.any entity in a version of the application. @param app_id The application ID. @param version_id [String] The version ID. @param entity_id The Pattern.Any entity id. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the H...
[ "Get", "the", "explicit", "(", "exception", ")", "list", "of", "the", "pattern", ".", "any", "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#L7947-L7950
train
Gets the list of entities in a version of the application.
[ 30522, 13366, 2131, 1035, 13216, 1035, 2862, 1006, 10439, 1035, 8909, 1010, 2544, 1035, 8909, 1010, 9178, 1035, 8909, 30524, 1007, 1012, 3643, 999, 3433, 1012, 2303, 4983, 3433, 1012, 9152, 2140, 1029, 2203, 102, 0, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
cheezy/page-object
lib/page-object/page_factory.rb
PageObject.PageFactory.if_page
def if_page(page_class, params={:using_params => {}},&block) page_class = class_from_string(page_class) if page_class.is_a? String return @current_page unless @current_page.class == page_class on_page(page_class, params, false, &block) end
ruby
def if_page(page_class, params={:using_params => {}},&block) page_class = class_from_string(page_class) if page_class.is_a? String return @current_page unless @current_page.class == page_class on_page(page_class, params, false, &block) end
[ "def", "if_page", "(", "page_class", ",", "params", "=", "{", ":using_params", "=>", "{", "}", "}", ",", "&", "block", ")", "page_class", "=", "class_from_string", "(", "page_class", ")", "if", "page_class", ".", "is_a?", "String", "return", "@current_page",...
Create a page object if and only if the current page is the same page to be created @param [PageObject, String] a class that has included the PageObject module or a string containing the name of the class @param Hash values that is pass through to page class a available in the @params instance variable. @param [b...
[ "Create", "a", "page", "object", "if", "and", "only", "if", "the", "current", "page", "is", "the", "same", "page", "to", "be", "created" ]
850d775bf63768fbb1551a34480195785fe8e193
https://github.com/cheezy/page-object/blob/850d775bf63768fbb1551a34480195785fe8e193/lib/page-object/page_factory.rb#L91-L95
train
If the current page is a page class return the current page.
[ 30522, 13366, 2065, 1035, 3931, 1006, 3931, 1035, 2465, 1010, 11498, 5244, 1027, 1063, 1024, 2478, 1035, 11498, 5244, 1027, 1028, 1063, 1065, 1065, 1010, 1004, 3796, 1007, 3931, 1035, 2465, 1027, 2465, 1035, 2013, 1035, 5164, 1006, 3931, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
minimagick/minimagick
lib/mini_magick/image.rb
MiniMagick.Image.validate!
def validate! identify rescue MiniMagick::Error => error raise MiniMagick::Invalid, error.message end
ruby
def validate! identify rescue MiniMagick::Error => error raise MiniMagick::Invalid, error.message end
[ "def", "validate!", "identify", "rescue", "MiniMagick", "::", "Error", "=>", "error", "raise", "MiniMagick", "::", "Invalid", ",", "error", ".", "message", "end" ]
Runs `identify` on the current image, and raises an error if it doesn't pass. @raise [MiniMagick::Invalid]
[ "Runs", "identify", "on", "the", "current", "image", "and", "raises", "an", "error", "if", "it", "doesn", "t", "pass", "." ]
d484786f35e91f107836d3c86aca61d50a35820b
https://github.com/minimagick/minimagick/blob/d484786f35e91f107836d3c86aca61d50a35820b/lib/mini_magick/image.rb#L205-L209
train
Validates the structure of the structure
[ 30522, 13366, 9398, 3686, 999, 6709, 5343, 7163, 2863, 12863, 2243, 1024, 1024, 7561, 1027, 1028, 7561, 5333, 7163, 2863, 12863, 2243, 1024, 1024, 19528, 1010, 7561, 1012, 4471, 2203, 102, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
management/azure_mgmt_compute/lib/2016-04-30-preview/generated/azure_mgmt_compute/virtual_machine_scale_sets.rb
Azure::Compute::Mgmt::V2016_04_30_preview.VirtualMachineScaleSets.power_off
def power_off(resource_group_name, vm_scale_set_name, vm_instance_ids:nil, custom_headers:nil) response = power_off_async(resource_group_name, vm_scale_set_name, vm_instance_ids:vm_instance_ids, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def power_off(resource_group_name, vm_scale_set_name, vm_instance_ids:nil, custom_headers:nil) response = power_off_async(resource_group_name, vm_scale_set_name, vm_instance_ids:vm_instance_ids, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "power_off", "(", "resource_group_name", ",", "vm_scale_set_name", ",", "vm_instance_ids", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "power_off_async", "(", "resource_group_name", ",", "vm_scale_set_name", ",", "vm_instance_ids", ":vm...
Power off (stop) one or more virtual machines in a VM scale set. Note that resources are still attached and you are getting charged for the resources. Instead, use deallocate to release resources and avoid charges. @param resource_group_name [String] The name of the resource group. @param vm_scale_set_name [String...
[ "Power", "off", "(", "stop", ")", "one", "or", "more", "virtual", "machines", "in", "a", "VM", "scale", "set", ".", "Note", "that", "resources", "are", "still", "attached", "and", "you", "are", "getting", "charged", "for", "the", "resources", ".", "Inste...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_compute/lib/2016-04-30-preview/generated/azure_mgmt_compute/virtual_machine_scale_sets.rb#L678-L681
train
Power off the virtual machines in a VM scale set.
[ 30522, 13366, 2373, 1035, 2125, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 1058, 2213, 1035, 4094, 1035, 2275, 1035, 2171, 1010, 1058, 2213, 1035, 6013, 1035, 8909, 2015, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 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...
daddyz/phonelib
lib/phonelib/phone_analyzer_helper.rb
Phonelib.PhoneAnalyzerHelper.country_prefix
def country_prefix(country) country = country.to_s.upcase Phonelib.phone_data[country] && \ Phonelib.phone_data[country][Core::COUNTRY_CODE] end
ruby
def country_prefix(country) country = country.to_s.upcase Phonelib.phone_data[country] && \ Phonelib.phone_data[country][Core::COUNTRY_CODE] end
[ "def", "country_prefix", "(", "country", ")", "country", "=", "country", ".", "to_s", ".", "upcase", "Phonelib", ".", "phone_data", "[", "country", "]", "&&", "Phonelib", ".", "phone_data", "[", "country", "]", "[", "Core", "::", "COUNTRY_CODE", "]", "end"...
returns country prefix for provided country or nil
[ "returns", "country", "prefix", "for", "provided", "country", "or", "nil" ]
aa0023eab7c896b71275bf342bc7f49735cbdbbf
https://github.com/daddyz/phonelib/blob/aa0023eab7c896b71275bf342bc7f49735cbdbbf/lib/phonelib/phone_analyzer_helper.rb#L36-L40
train
Returns the prefix for a country
[ 30522, 13366, 2406, 1035, 17576, 1006, 2406, 1007, 2406, 1027, 2406, 1012, 2000, 1035, 1055, 1012, 2039, 18382, 3042, 29521, 1012, 3042, 1035, 2951, 1031, 2406, 1033, 1004, 1004, 1032, 3042, 29521, 1012, 3042, 1035, 2951, 1031, 2406, 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...
tongueroo/jets
lib/jets/job/dsl/s3_event.rb
Jets::Job::Dsl.S3Event.declare_s3_bucket_resources
def declare_s3_bucket_resources(bucket_name) # If shared s3 bucket resources have already been declared. # We will not generate them again. However, we still need to always # add the depends_on declaration to ensure that the shared stack parameters # are properly passed to the nested child stack...
ruby
def declare_s3_bucket_resources(bucket_name) # If shared s3 bucket resources have already been declared. # We will not generate them again. However, we still need to always # add the depends_on declaration to ensure that the shared stack parameters # are properly passed to the nested child stack...
[ "def", "declare_s3_bucket_resources", "(", "bucket_name", ")", "# If shared s3 bucket resources have already been declared.", "# We will not generate them again. However, we still need to always", "# add the depends_on declaration to ensure that the shared stack parameters", "# are properly passed t...
Returns stack_name
[ "Returns", "stack_name" ]
46943a519224067e58aa3e2d5656e3ca083150f9
https://github.com/tongueroo/jets/blob/46943a519224067e58aa3e2d5656e3ca083150f9/lib/jets/job/dsl/s3_event.rb#L9-L24
train
Declare the resources for the given bucket.
[ 30522, 13366, 13520, 1035, 1055, 2509, 1035, 13610, 1035, 4219, 1006, 13610, 1035, 2171, 1007, 1001, 2065, 4207, 1055, 2509, 13610, 4219, 2031, 2525, 2042, 4161, 1012, 1001, 2057, 2097, 2025, 9699, 2068, 2153, 1012, 2174, 1010, 2057, 2145, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/form_builder.rb
Decidim.FormBuilder.check_box
def check_box(attribute, options = {}, checked_value = "1", unchecked_value = "0") custom_label(attribute, options[:label], options[:label_options], true, false) do options.delete(:label) options.delete(:label_options) @template.check_box(@object_name, attribute, objectify_options(options)...
ruby
def check_box(attribute, options = {}, checked_value = "1", unchecked_value = "0") custom_label(attribute, options[:label], options[:label_options], true, false) do options.delete(:label) options.delete(:label_options) @template.check_box(@object_name, attribute, objectify_options(options)...
[ "def", "check_box", "(", "attribute", ",", "options", "=", "{", "}", ",", "checked_value", "=", "\"1\"", ",", "unchecked_value", "=", "\"0\"", ")", "custom_label", "(", "attribute", ",", "options", "[", ":label", "]", ",", "options", "[", ":label_options", ...
Public: Override so checkboxes are rendered before the label.
[ "Public", ":", "Override", "so", "checkboxes", "are", "rendered", "before", "the", "label", "." ]
6e2b14e559a63088669904e3c5c49a5180700cf7
https://github.com/decidim/decidim/blob/6e2b14e559a63088669904e3c5c49a5180700cf7/decidim-core/lib/decidim/form_builder.rb#L301-L307
train
Returns a check box with the given attribute.
[ 30522, 13366, 4638, 1035, 3482, 1006, 17961, 1010, 7047, 1027, 1063, 1065, 1010, 7039, 1035, 3643, 1027, 1000, 1015, 1000, 1010, 4895, 5403, 18141, 1035, 3643, 1027, 1000, 1014, 1000, 1007, 7661, 1035, 3830, 1006, 17961, 1010, 7047, 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...
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.get_sas_definitions
def get_sas_definitions(vault_base_url, storage_account_name, maxresults:nil, custom_headers:nil) first_page = get_sas_definitions_as_lazy(vault_base_url, storage_account_name, maxresults:maxresults, custom_headers:custom_headers) first_page.get_all_items end
ruby
def get_sas_definitions(vault_base_url, storage_account_name, maxresults:nil, custom_headers:nil) first_page = get_sas_definitions_as_lazy(vault_base_url, storage_account_name, maxresults:maxresults, custom_headers:custom_headers) first_page.get_all_items end
[ "def", "get_sas_definitions", "(", "vault_base_url", ",", "storage_account_name", ",", "maxresults", ":", "nil", ",", "custom_headers", ":", "nil", ")", "first_page", "=", "get_sas_definitions_as_lazy", "(", "vault_base_url", ",", "storage_account_name", ",", "maxresult...
List storage SAS definitions for the given storage account. This operation requires the storage/listsas permission. @param vault_base_url [String] The vault name, for example https://myvault.vault.azure.net. @param storage_account_name [String] The name of the storage account. @param maxresults [Integer] Maximum ...
[ "List", "storage", "SAS", "definitions", "for", "the", "given", "storage", "account", ".", "This", "operation", "requires", "the", "storage", "/", "listsas", "permission", "." ]
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#L7673-L7676
train
Gets the SAS definitions for the specified storage account.
[ 30522, 13366, 2131, 1035, 21871, 1035, 15182, 30524, 1035, 24471, 2140, 1010, 5527, 1035, 4070, 1035, 2171, 1010, 4098, 6072, 11314, 2015, 1024, 4098, 6072, 11314, 2015, 1010, 7661, 1035, 20346, 2015, 1024, 7661, 1035, 20346, 2015, 1007, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/devices.rb
Azure::StorSimple8000Series::Mgmt::V2017_06_01.Devices.begin_configure
def begin_configure(parameters, resource_group_name, manager_name, custom_headers:nil) response = begin_configure_async(parameters, resource_group_name, manager_name, custom_headers:custom_headers).value! nil end
ruby
def begin_configure(parameters, resource_group_name, manager_name, custom_headers:nil) response = begin_configure_async(parameters, resource_group_name, manager_name, custom_headers:custom_headers).value! nil end
[ "def", "begin_configure", "(", "parameters", ",", "resource_group_name", ",", "manager_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "begin_configure_async", "(", "parameters", ",", "resource_group_name", ",", "manager_name", ",", "custom_headers", "...
Complete minimal setup before using the device. @param parameters [ConfigureDeviceRequest] The minimal properties to configure a device. @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...
[ "Complete", "minimal", "setup", "before", "using", "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#L1219-L1222
train
Configure the specified managed network interface.
[ 30522, 13366, 4088, 1035, 9530, 8873, 27390, 2063, 1006, 11709, 1010, 7692, 1035, 2177, 1035, 2171, 1010, 3208, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 4088, 1035, 9530, 8873, 27390, 2063, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
EugenMayer/docker-sync
lib/docker-sync/sync_process.rb
DockerSync.SyncProcess.set_sync_strategy
def set_sync_strategy case @options['sync_strategy'] when 'rsync' @sync_strategy = DockerSync::SyncStrategy::Rsync.new(@sync_name, @options) when 'unison' @sync_strategy = DockerSync::SyncStrategy::Unison.new(@sync_name, @options) when 'native' @sync_strategy = DockerSync...
ruby
def set_sync_strategy case @options['sync_strategy'] when 'rsync' @sync_strategy = DockerSync::SyncStrategy::Rsync.new(@sync_name, @options) when 'unison' @sync_strategy = DockerSync::SyncStrategy::Unison.new(@sync_name, @options) when 'native' @sync_strategy = DockerSync...
[ "def", "set_sync_strategy", "case", "@options", "[", "'sync_strategy'", "]", "when", "'rsync'", "@sync_strategy", "=", "DockerSync", "::", "SyncStrategy", "::", "Rsync", ".", "new", "(", "@sync_name", ",", "@options", ")", "when", "'unison'", "@sync_strategy", "="...
noinspection RubyStringKeysInHashInspection
[ "noinspection", "RubyStringKeysInHashInspection" ]
7bac0072e959bc1596a8e4075e77fed48360fe04
https://github.com/EugenMayer/docker-sync/blob/7bac0072e959bc1596a8e4075e77fed48360fe04/lib/docker-sync/sync_process.rb#L43-L56
train
Sets the sync strategy to use for the current sync
[ 30522, 13366, 2275, 1035, 26351, 1035, 5656, 2553, 1030, 7047, 1031, 1005, 26351, 1035, 5656, 1005, 1033, 2043, 1005, 12667, 6038, 2278, 1005, 1030, 26351, 1035, 5656, 1027, 8946, 2545, 6038, 2278, 1024, 1024, 26351, 20528, 2618, 6292, 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...
twitter/secure_headers
lib/secure_headers/view_helper.rb
SecureHeaders.ViewHelpers.nonced_stylesheet_link_tag
def nonced_stylesheet_link_tag(*args, &block) opts = extract_options(args).merge(nonce: _content_security_policy_nonce(:style)) stylesheet_link_tag(*args, opts, &block) end
ruby
def nonced_stylesheet_link_tag(*args, &block) opts = extract_options(args).merge(nonce: _content_security_policy_nonce(:style)) stylesheet_link_tag(*args, opts, &block) end
[ "def", "nonced_stylesheet_link_tag", "(", "*", "args", ",", "&", "block", ")", "opts", "=", "extract_options", "(", "args", ")", ".", "merge", "(", "nonce", ":", "_content_security_policy_nonce", "(", ":style", ")", ")", "stylesheet_link_tag", "(", "args", ","...
Public: create a stylesheet link tag using the content security policy nonce. Instructs secure_headers to append a nonce to style-src directive. Returns an html-safe link tag with the nonce attribute.
[ "Public", ":", "create", "a", "stylesheet", "link", "tag", "using", "the", "content", "security", "policy", "nonce", ".", "Instructs", "secure_headers", "to", "append", "a", "nonce", "to", "style", "-", "src", "directive", "." ]
543e6712aadae08f1653ed973e6b6204f7eac26a
https://github.com/twitter/secure_headers/blob/543e6712aadae08f1653ed973e6b6204f7eac26a/lib/secure_headers/view_helper.rb#L21-L25
train
Returns a stylesheet link tag with a non - stylesheet nonce.
[ 30522, 13366, 2512, 11788, 1035, 6782, 21030, 2102, 1035, 4957, 1035, 6415, 1006, 1008, 12098, 5620, 1010, 1004, 3796, 1007, 23569, 2015, 1027, 14817, 1035, 7047, 1006, 12098, 5620, 1007, 1012, 13590, 1006, 2512, 3401, 1024, 1035, 4180, 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...
cucumber/aruba
lib/aruba/event_bus.rb
Aruba.EventBus.register
def register(event_ids, handler_object = nil, &handler_proc) handler = handler_proc || handler_object fail ArgumentError, 'Please pass either an object#call or a handler block' if handler.nil? || !handler.respond_to?(:call) Array(event_ids).flatten.each do |id| @handlers[ @resolver...
ruby
def register(event_ids, handler_object = nil, &handler_proc) handler = handler_proc || handler_object fail ArgumentError, 'Please pass either an object#call or a handler block' if handler.nil? || !handler.respond_to?(:call) Array(event_ids).flatten.each do |id| @handlers[ @resolver...
[ "def", "register", "(", "event_ids", ",", "handler_object", "=", "nil", ",", "&", "handler_proc", ")", "handler", "=", "handler_proc", "||", "handler_object", "fail", "ArgumentError", ",", "'Please pass either an object#call or a handler block'", "if", "handler", ".", ...
Create EventBus @param [#transform] resolver A resolver which transforms Symbol, String, Class into an event Class. Register for an event @param [String, Symbol, Class, Array] event_ids If Array, register multiple events witht the same handler. If String, Symbol, Class register handler for given event. ...
[ "Create", "EventBus" ]
add17615322f575588aef1fccce875396cdf36e9
https://github.com/cucumber/aruba/blob/add17615322f575588aef1fccce875396cdf36e9/lib/aruba/event_bus.rb#L33-L45
train
Register a handler for the given event_ids
[ 30522, 13366, 4236, 1006, 2724, 1035, 8909, 2015, 1010, 28213, 1035, 4874, 1027, 9152, 2140, 1010, 1004, 28213, 1035, 4013, 2278, 1007, 28213, 1027, 28213, 1035, 4013, 2278, 1064, 1064, 28213, 1035, 4874, 8246, 6685, 2121, 29165, 1010, 1005...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/route_filters.rb
Azure::Network::Mgmt::V2018_07_01.RouteFilters.begin_create_or_update_with_http_info
def begin_create_or_update_with_http_info(resource_group_name, route_filter_name, route_filter_parameters, custom_headers:nil) begin_create_or_update_async(resource_group_name, route_filter_name, route_filter_parameters, custom_headers:custom_headers).value! end
ruby
def begin_create_or_update_with_http_info(resource_group_name, route_filter_name, route_filter_parameters, custom_headers:nil) begin_create_or_update_async(resource_group_name, route_filter_name, route_filter_parameters, custom_headers:custom_headers).value! end
[ "def", "begin_create_or_update_with_http_info", "(", "resource_group_name", ",", "route_filter_name", ",", "route_filter_parameters", ",", "custom_headers", ":", "nil", ")", "begin_create_or_update_async", "(", "resource_group_name", ",", "route_filter_name", ",", "route_filter...
Creates or updates a route filter in a specified resource group. @param resource_group_name [String] The name of the resource group. @param route_filter_name [String] The name of the route filter. @param route_filter_parameters [RouteFilter] Parameters supplied to the create or update route filter operation. @par...
[ "Creates", "or", "updates", "a", "route", "filter", "in", "a", "specified", "resource", "group", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-07-01/generated/azure_mgmt_network/route_filters.rb#L534-L536
train
Creates or updates a route filter in the specified resource group.
[ 30522, 13366, 4088, 1035, 3443, 1035, 2030, 1035, 10651, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2799, 1035, 11307, 1035, 2171, 1010, 2799, 1035, 11307, 1035, 11709, 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...
rails/sprockets
lib/sprockets/loader.rb
Sprockets.Loader.fetch_asset_from_dependency_cache
def fetch_asset_from_dependency_cache(unloaded, limit = 3) key = unloaded.dependency_history_key history = cache.get(key) || [] history.each_with_index do |deps, index| expanded_deps = deps.map do |path| path.start_with?("file-digest://") ? expand_from_root(path) : path ...
ruby
def fetch_asset_from_dependency_cache(unloaded, limit = 3) key = unloaded.dependency_history_key history = cache.get(key) || [] history.each_with_index do |deps, index| expanded_deps = deps.map do |path| path.start_with?("file-digest://") ? expand_from_root(path) : path ...
[ "def", "fetch_asset_from_dependency_cache", "(", "unloaded", ",", "limit", "=", "3", ")", "key", "=", "unloaded", ".", "dependency_history_key", "history", "=", "cache", ".", "get", "(", "key", ")", "||", "[", "]", "history", ".", "each_with_index", "do", "|...
Internal: Retrieves an asset based on its digest unloaded - An UnloadedAsset limit - A Fixnum which sets the maximum number of versions of "histories" stored in the cache This method attempts to retrieve the last `limit` number of histories of an asset from the cache a "history" which is an array o...
[ "Internal", ":", "Retrieves", "an", "asset", "based", "on", "its", "digest" ]
9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd
https://github.com/rails/sprockets/blob/9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd/lib/sprockets/loader.rb#L315-L335
train
Fetch the asset from the dependency cache.
[ 30522, 13366, 18584, 1035, 11412, 1035, 2013, 1035, 24394, 1035, 17053, 1006, 4895, 17468, 1010, 5787, 1027, 1017, 1007, 3145, 1027, 4895, 17468, 1012, 24394, 1035, 2381, 1035, 3145, 2381, 1027, 17053, 1012, 2131, 1006, 3145, 1007, 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...
aws/aws-sdk-ruby
gems/aws-sdk-autoscaling/lib/aws-sdk-autoscaling/tag.rb
Aws::AutoScaling.Tag.create
def create(options = {}) options = Aws::Util.deep_merge(options, tags: [{ resource_type: @resource_type, resource_id: @resource_id, key: @key }]) resp = @client.create_or_update_tags(options) resp.data end
ruby
def create(options = {}) options = Aws::Util.deep_merge(options, tags: [{ resource_type: @resource_type, resource_id: @resource_id, key: @key }]) resp = @client.create_or_update_tags(options) resp.data end
[ "def", "create", "(", "options", "=", "{", "}", ")", "options", "=", "Aws", "::", "Util", ".", "deep_merge", "(", "options", ",", "tags", ":", "[", "{", "resource_type", ":", "@resource_type", ",", "resource_id", ":", "@resource_id", ",", "key", ":", "...
@!group Actions @example Request syntax with placeholder values tag.create({ tags: [ # required { resource_id: "XmlString", resource_type: "XmlString", key: "TagKey", # required value: "TagValue", propagate_at_launch: false, }, ], }) @param [...
[ "@!group", "Actions", "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-autoscaling/lib/aws-sdk-autoscaling/tag.rb#L220-L228
train
Creates a new resource or updates an existing resource or updates an existing resource or updates an existing resource.
[ 30522, 13366, 3443, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 22091, 2015, 1024, 1024, 21183, 4014, 1012, 2784, 1035, 13590, 1006, 7047, 1010, 22073, 1024, 1031, 1063, 7692, 1035, 2828, 1024, 1030, 7692, 1035, 2828, 1010, 7692, 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_consumption/lib/2018-01-31/generated/azure_mgmt_consumption/reservations_summaries.rb
Azure::Consumption::Mgmt::V2018_01_31.ReservationsSummaries.list_by_reservation_order_and_reservation_next
def list_by_reservation_order_and_reservation_next(next_page_link, custom_headers:nil) response = list_by_reservation_order_and_reservation_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_by_reservation_order_and_reservation_next(next_page_link, custom_headers:nil) response = list_by_reservation_order_and_reservation_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_by_reservation_order_and_reservation_next", "(", "next_page_link", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_by_reservation_order_and_reservation_next_async", "(", "next_page_link", ",", "custom_headers", ":custom_headers", ")", ".", "value!", ...
Lists the reservations summaries for daily or monthly grain. @param next_page_link [String] The NextLink from the previous successful call to List operation. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [ReservationSummariesListResult] op...
[ "Lists", "the", "reservations", "summaries", "for", "daily", "or", "monthly", "grain", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_consumption/lib/2018-01-31/generated/azure_mgmt_consumption/reservations_summaries.rb#L333-L336
train
Gets the list of all the elastic advisors in a resource group.
[ 30522, 13366, 2862, 1035, 2011, 1035, 11079, 1035, 2344, 1035, 1998, 1035, 11079, 1035, 2279, 1006, 2279, 1035, 3931, 1035, 4957, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 2011, 1035, 11079, 1035, 2344, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/2016-10-10/generated/azure_mgmt_api_management/product_apis.rb
Azure::ApiManagement::Mgmt::V2016_10_10.ProductApis.list_by_products_next
def list_by_products_next(next_page_link, custom_headers:nil) response = list_by_products_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_by_products_next(next_page_link, custom_headers:nil) response = list_by_products_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_by_products_next", "(", "next_page_link", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_by_products_next_async", "(", "next_page_link", ",", "custom_headers", ":custom_headers", ")", ".", "value!", "response", ".", "body", "unless", "resp...
Lists a collection of the APIs associated with a product. @param next_page_link [String] The NextLink from the previous successful call to List operation. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [ApiCollection] operation results.
[ "Lists", "a", "collection", "of", "the", "APIs", "associated", "with", "a", "product", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_api_management/lib/2016-10-10/generated/azure_mgmt_api_management/product_apis.rb#L397-L400
train
Gets the list of product objects.
[ 30522, 13366, 2862, 1035, 2011, 1035, 3688, 1035, 2279, 1006, 2279, 1035, 3931, 1035, 4957, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 2011, 1035, 3688, 1035, 2279, 1035, 2004, 6038, 2278, 1006, 2279, 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...
rails/rails
activerecord/lib/active_record/relation/batches.rb
ActiveRecord.Batches.find_in_batches
def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil) relation = self unless block_given? return to_enum(:find_in_batches, start: start, finish: finish, batch_size: batch_size, error_on_ignore: error_on_ignore) do total = apply_limits(relation, start, finish)...
ruby
def find_in_batches(start: nil, finish: nil, batch_size: 1000, error_on_ignore: nil) relation = self unless block_given? return to_enum(:find_in_batches, start: start, finish: finish, batch_size: batch_size, error_on_ignore: error_on_ignore) do total = apply_limits(relation, start, finish)...
[ "def", "find_in_batches", "(", "start", ":", "nil", ",", "finish", ":", "nil", ",", "batch_size", ":", "1000", ",", "error_on_ignore", ":", "nil", ")", "relation", "=", "self", "unless", "block_given?", "return", "to_enum", "(", ":find_in_batches", ",", "sta...
Yields each batch of records that was found by the find options as an array. Person.where("age > 21").find_in_batches do |group| sleep(50) # Make sure it doesn't get too crowded in there! group.each { |person| person.party_all_night! } end If you do not provide a block to #find_in_batches, it will r...
[ "Yields", "each", "batch", "of", "records", "that", "was", "found", "by", "the", "find", "options", "as", "an", "array", "." ]
85a8bc644be69908f05740a5886ec19cd3679df5
https://github.com/rails/rails/blob/85a8bc644be69908f05740a5886ec19cd3679df5/activerecord/lib/active_record/relation/batches.rb#L126-L138
train
Find all the documents in batches of the given size.
[ 30522, 13366, 2424, 1035, 1999, 1035, 14108, 2229, 1006, 2707, 1024, 9152, 2140, 1010, 3926, 1024, 9152, 2140, 1010, 14108, 1035, 2946, 1024, 6694, 1010, 7561, 1035, 2006, 1035, 8568, 1024, 9152, 2140, 1007, 7189, 1027, 2969, 4983, 3796, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/module_tool/metadata.rb
Puppet::ModuleTool.Metadata.validate_version_range
def validate_version_range(version_range) SemanticPuppet::VersionRange.parse(version_range) rescue ArgumentError => e raise ArgumentError, _("Invalid 'version_range' field in metadata.json: %{err}") % { err: e } end
ruby
def validate_version_range(version_range) SemanticPuppet::VersionRange.parse(version_range) rescue ArgumentError => e raise ArgumentError, _("Invalid 'version_range' field in metadata.json: %{err}") % { err: e } end
[ "def", "validate_version_range", "(", "version_range", ")", "SemanticPuppet", "::", "VersionRange", ".", "parse", "(", "version_range", ")", "rescue", "ArgumentError", "=>", "e", "raise", "ArgumentError", ",", "_", "(", "\"Invalid 'version_range' field in metadata.json: %...
Validates that the version range can be parsed by Semantic.
[ "Validates", "that", "the", "version", "range", "can", "be", "parsed", "by", "Semantic", "." ]
4baeed97cbb7571ddc6635f0a24debe2e8b22cd3
https://github.com/puppetlabs/puppet/blob/4baeed97cbb7571ddc6635f0a24debe2e8b22cd3/lib/puppet/module_tool/metadata.rb#L216-L220
train
Validate the version_range field in the metadata. json
[ 30522, 13366, 9398, 3686, 1035, 2544, 1035, 2846, 1006, 2544, 1035, 2846, 1007, 21641, 14289, 29519, 1024, 1024, 2544, 24388, 2063, 1012, 11968, 3366, 1006, 2544, 1035, 2846, 1007, 5343, 6685, 2121, 29165, 1027, 1028, 1041, 5333, 6685, 2121...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
kmuto/review
lib/review/latexbuilder.rb
ReVIEW.LATEXBuilder.listnum
def listnum(lines, id, caption, lang = nil) first_line_num = line_num if highlight_listings? common_code_block_lst(id, lines, 'reviewlistnumlst', 'caption', caption, lang, first_line_num: first_line_num) else common_code_block(id, lines, 'reviewlist', caption, lang) { |line, idx| detab...
ruby
def listnum(lines, id, caption, lang = nil) first_line_num = line_num if highlight_listings? common_code_block_lst(id, lines, 'reviewlistnumlst', 'caption', caption, lang, first_line_num: first_line_num) else common_code_block(id, lines, 'reviewlist', caption, lang) { |line, idx| detab...
[ "def", "listnum", "(", "lines", ",", "id", ",", "caption", ",", "lang", "=", "nil", ")", "first_line_num", "=", "line_num", "if", "highlight_listings?", "common_code_block_lst", "(", "id", ",", "lines", ",", "'reviewlistnumlst'", ",", "'caption'", ",", "captio...
override Builder#listnum
[ "override", "Builder#listnum" ]
77d1273e671663f05db2992281fd891b776badf0
https://github.com/kmuto/review/blob/77d1273e671663f05db2992281fd891b776badf0/lib/review/latexbuilder.rb#L361-L368
train
Returns the listnum of the lines
[ 30522, 13366, 2862, 19172, 1006, 3210, 1010, 8909, 1010, 14408, 3258, 1010, 11374, 1027, 9152, 2140, 1007, 2034, 1035, 2240, 1035, 16371, 2213, 1027, 2240, 1035, 16371, 2213, 2065, 12944, 1035, 26213, 1029, 2691, 1035, 3642, 1035, 3796, 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...
tomiacannondale/era_ja
lib/era_ja/conversion.rb
EraJa.Conversion.to_era
def to_era(format = "%o%E.%m.%d", era_names: ERA_NAME_DEFAULTS) raise EraJa::DateOutOfRangeError unless era_convertible? @era_format = format.gsub(/%J/, "%J%") str_time = strftime(@era_format) if @era_format =~ /%([EOo]|1O)/ case when self.to_time < ::Time.mktime(1912,7,30) ...
ruby
def to_era(format = "%o%E.%m.%d", era_names: ERA_NAME_DEFAULTS) raise EraJa::DateOutOfRangeError unless era_convertible? @era_format = format.gsub(/%J/, "%J%") str_time = strftime(@era_format) if @era_format =~ /%([EOo]|1O)/ case when self.to_time < ::Time.mktime(1912,7,30) ...
[ "def", "to_era", "(", "format", "=", "\"%o%E.%m.%d\"", ",", "era_names", ":", "ERA_NAME_DEFAULTS", ")", "raise", "EraJa", "::", "DateOutOfRangeError", "unless", "era_convertible?", "@era_format", "=", "format", ".", "gsub", "(", "/", "/", ",", "\"%J%\"", ")", ...
Convert to Japanese era. @param [String] format_string Time#strftime format string can be used #### extra format string * %o - era(alphabet) * %O - era(kanzi) * %E - era year * %J - kanzi number @param [Hash] era_names If you want to convert custom to era strings (eg `平`, `h`), you can set this ...
[ "Convert", "to", "Japanese", "era", "." ]
1ec1b7e1b53caf4290c755967f180719db944d50
https://github.com/tomiacannondale/era_ja/blob/1ec1b7e1b53caf4290c755967f180719db944d50/lib/era_ja/conversion.rb#L28-L48
train
Convert the date to an Era object.
[ 30522, 13366, 2000, 1035, 3690, 1006, 4289, 1027, 1000, 1003, 1051, 1003, 1041, 1012, 1003, 1049, 1012, 1003, 1040, 1000, 1010, 3690, 1035, 3415, 1024, 3690, 1035, 2171, 1035, 12398, 2015, 1007, 5333, 3690, 3900, 1024, 1024, 3058, 5833, 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...
samvera/hyrax
app/controllers/concerns/hyrax/deny_access_override_behavior.rb
Hyrax.DenyAccessOverrideBehavior.deny_access
def deny_access(exception) if current_user&.persisted? redirect_to root_path, alert: exception.message else session['user_return_to'.freeze] = request.url redirect_to main_app.new_user_session_path, alert: exception.message end end
ruby
def deny_access(exception) if current_user&.persisted? redirect_to root_path, alert: exception.message else session['user_return_to'.freeze] = request.url redirect_to main_app.new_user_session_path, alert: exception.message end end
[ "def", "deny_access", "(", "exception", ")", "if", "current_user", "&.", "persisted?", "redirect_to", "root_path", ",", "alert", ":", "exception", ".", "message", "else", "session", "[", "'user_return_to'", ".", "freeze", "]", "=", "request", ".", "url", "redi...
Overriding the default behavior from Hydra::Core::ControllerBehavior
[ "Overriding", "the", "default", "behavior", "from", "Hydra", "::", "Core", "::", "ControllerBehavior" ]
e2b4f56e829a53b1f11296324736e9d5b8c9ee5f
https://github.com/samvera/hyrax/blob/e2b4f56e829a53b1f11296324736e9d5b8c9ee5f/app/controllers/concerns/hyrax/deny_access_override_behavior.rb#L4-L11
train
Deny access to the user
[ 30522, 13366, 9772, 1035, 3229, 1006, 6453, 1007, 2065, 2783, 1035, 5310, 1004, 1012, 19035, 1029, 2417, 7442, 6593, 1035, 2000, 7117, 1035, 4130, 1010, 9499, 1024, 6453, 1012, 4471, 2842, 5219, 1031, 1005, 5310, 1035, 2709, 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...
alexreisner/geocoder
lib/geocoder/calculations.rb
Geocoder.Calculations.endpoint
def endpoint(start, heading, distance, options = {}) radius = earth_radius(options[:units]) start = extract_coordinates(start) # convert degrees to radians start = to_radians(start) lat = start[0] lon = start[1] heading = to_radians(heading) distance = distance.to_f ...
ruby
def endpoint(start, heading, distance, options = {}) radius = earth_radius(options[:units]) start = extract_coordinates(start) # convert degrees to radians start = to_radians(start) lat = start[0] lon = start[1] heading = to_radians(heading) distance = distance.to_f ...
[ "def", "endpoint", "(", "start", ",", "heading", ",", "distance", ",", "options", "=", "{", "}", ")", "radius", "=", "earth_radius", "(", "options", "[", ":units", "]", ")", "start", "=", "extract_coordinates", "(", "start", ")", "# convert degrees to radian...
Given a start point, heading (in degrees), and distance, provides an endpoint. The starting point is given in the same way that points are given to all Geocoder methods that accept points as arguments. It can be: * an array of coordinates ([lat,lon]) * a geocodable address (string) * a geocoded object (one which...
[ "Given", "a", "start", "point", "heading", "(", "in", "degrees", ")", "and", "distance", "provides", "an", "endpoint", ".", "The", "starting", "point", "is", "given", "in", "the", "same", "way", "that", "points", "are", "given", "to", "all", "Geocoder", ...
e087dc2759264ee6f307b926bb2de4ec2406859e
https://github.com/alexreisner/geocoder/blob/e087dc2759264ee6f307b926bb2de4ec2406859e/lib/geocoder/calculations.rb#L269-L289
train
Returns the endpoint of the given start and heading
[ 30522, 13366, 2203, 8400, 1006, 2707, 1010, 5825, 1010, 3292, 1010, 7047, 1027, 1063, 1065, 1007, 12177, 1027, 3011, 1035, 12177, 1006, 7047, 1031, 1024, 3197, 1033, 1007, 2707, 1027, 14817, 1035, 12093, 1006, 2707, 1007, 1001, 10463, 5445,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_stream_analytics/lib/2016-03-01/generated/azure_mgmt_stream_analytics/outputs.rb
Azure::StreamAnalytics::Mgmt::V2016_03_01.Outputs.create_or_replace
def create_or_replace(output, resource_group_name, job_name, output_name, if_match:nil, if_none_match:nil, custom_headers:nil) response = create_or_replace_async(output, resource_group_name, job_name, output_name, if_match:if_match, if_none_match:if_none_match, custom_headers:custom_headers).value! response...
ruby
def create_or_replace(output, resource_group_name, job_name, output_name, if_match:nil, if_none_match:nil, custom_headers:nil) response = create_or_replace_async(output, resource_group_name, job_name, output_name, if_match:if_match, if_none_match:if_none_match, custom_headers:custom_headers).value! response...
[ "def", "create_or_replace", "(", "output", ",", "resource_group_name", ",", "job_name", ",", "output_name", ",", "if_match", ":", "nil", ",", "if_none_match", ":", "nil", ",", "custom_headers", ":", "nil", ")", "response", "=", "create_or_replace_async", "(", "o...
Creates an output or replaces an already existing output under an existing streaming job. @param output [Output] The definition of the output that will be used to create a new output or replace the existing one under the streaming job. @param resource_group_name [String] The name of the resource group that contai...
[ "Creates", "an", "output", "or", "replaces", "an", "already", "existing", "output", "under", "an", "existing", "streaming", "job", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_stream_analytics/lib/2016-03-01/generated/azure_mgmt_stream_analytics/outputs.rb#L46-L49
train
Creates or replaces an existing output.
[ 30522, 13366, 3443, 1035, 2030, 1035, 5672, 1006, 6434, 1010, 7692, 1035, 2177, 1035, 2171, 1010, 3105, 1035, 2171, 1010, 6434, 1035, 2171, 1010, 2065, 1035, 2674, 1024, 9152, 2140, 1010, 2065, 1035, 3904, 1035, 2674, 1024, 9152, 2140, 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...
sensu/sensu
lib/sensu/daemon.rb
Sensu.Daemon.daemonize
def daemonize Kernel.srand exit if Kernel.fork unless Process.setsid @logger.fatal("cannot detach from controlling terminal") @logger.fatal("SENSU NOT RUNNING!") exit 2 end Signal.trap("SIGHUP", "IGNORE") exit if Kernel.fork Dir.chdir("/") ObjectSp...
ruby
def daemonize Kernel.srand exit if Kernel.fork unless Process.setsid @logger.fatal("cannot detach from controlling terminal") @logger.fatal("SENSU NOT RUNNING!") exit 2 end Signal.trap("SIGHUP", "IGNORE") exit if Kernel.fork Dir.chdir("/") ObjectSp...
[ "def", "daemonize", "Kernel", ".", "srand", "exit", "if", "Kernel", ".", "fork", "unless", "Process", ".", "setsid", "@logger", ".", "fatal", "(", "\"cannot detach from controlling terminal\"", ")", "@logger", ".", "fatal", "(", "\"SENSU NOT RUNNING!\"", ")", "exi...
Daemonize the current process. Seed the random number generator, fork (& exit), detach from controlling terminal, ignore SIGHUP, fork (& exit), use root '/' as the current working directory, and close STDIN/OUT/ERR since the process is no longer attached to a terminal.
[ "Daemonize", "the", "current", "process", ".", "Seed", "the", "random", "number", "generator", "fork", "(", "&", "exit", ")", "detach", "from", "controlling", "terminal", "ignore", "SIGHUP", "fork", "(", "&", "exit", ")", "use", "root", "/", "as", "the", ...
51319e4b58c8d9986f101ad71ff729aa3e51e951
https://github.com/sensu/sensu/blob/51319e4b58c8d9986f101ad71ff729aa3e51e951/lib/sensu/daemon.rb#L376-L394
train
daemonize the process
[ 30522, 13366, 12828, 4697, 16293, 1012, 5034, 5685, 6164, 2065, 16293, 1012, 9292, 4983, 2832, 1012, 4520, 3593, 1030, 8833, 4590, 1012, 10611, 1006, 1000, 3685, 20010, 6776, 2013, 9756, 5536, 1000, 1007, 1030, 8833, 4590, 1012, 10611, 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...
roo-rb/roo
lib/roo/open_office.rb
Roo.OpenOffice.label
def label(labelname) read_labels return [nil, nil, nil] if @label.size < 1 || !@label.key?(labelname) [ @label[labelname][1].to_i, ::Roo::Utils.letter_to_number(@label[labelname][2]), @label[labelname][0] ] end
ruby
def label(labelname) read_labels return [nil, nil, nil] if @label.size < 1 || !@label.key?(labelname) [ @label[labelname][1].to_i, ::Roo::Utils.letter_to_number(@label[labelname][2]), @label[labelname][0] ] end
[ "def", "label", "(", "labelname", ")", "read_labels", "return", "[", "nil", ",", "nil", ",", "nil", "]", "if", "@label", ".", "size", "<", "1", "||", "!", "@label", ".", "key?", "(", "labelname", ")", "[", "@label", "[", "labelname", "]", "[", "1",...
returns the row,col values of the labelled cell (nil,nil) if label is not defined
[ "returns", "the", "row", "col", "values", "of", "the", "labelled", "cell", "(", "nil", "nil", ")", "if", "label", "is", "not", "defined" ]
4ec1104f0c3c2a29711c0c907371cd2be12bcc3c
https://github.com/roo-rb/roo/blob/4ec1104f0c3c2a29711c0c907371cd2be12bcc3c/lib/roo/open_office.rb#L178-L186
train
Returns the label for the given labelname.
[ 30522, 13366, 3830, 1006, 3830, 18442, 1007, 3191, 1035, 10873, 2709, 1031, 9152, 2140, 1010, 9152, 2140, 1010, 9152, 2140, 1033, 2065, 1030, 3830, 1012, 2946, 1026, 1015, 1064, 1064, 999, 1030, 3830, 1012, 3145, 1029, 1006, 3830, 18442, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
Shopify/shipit-engine
app/jobs/shipit/destroy_stack_job.rb
Shipit.DestroyStackJob.perform
def perform(stack) Shipit::ApiClient.where(stack_id: stack.id).delete_all commits_ids = Shipit::Commit.where(stack_id: stack.id).pluck(:id) commit_deployments_ids = Shipit::CommitDeployment.where(commit_id: commits_ids).pluck(:id) Shipit::CommitDeploymentStatus.where(commit_deployment_id: commit...
ruby
def perform(stack) Shipit::ApiClient.where(stack_id: stack.id).delete_all commits_ids = Shipit::Commit.where(stack_id: stack.id).pluck(:id) commit_deployments_ids = Shipit::CommitDeployment.where(commit_id: commits_ids).pluck(:id) Shipit::CommitDeploymentStatus.where(commit_deployment_id: commit...
[ "def", "perform", "(", "stack", ")", "Shipit", "::", "ApiClient", ".", "where", "(", "stack_id", ":", "stack", ".", "id", ")", ".", "delete_all", "commits_ids", "=", "Shipit", "::", "Commit", ".", "where", "(", "stack_id", ":", "stack", ".", "id", ")",...
stack +-- api_clients +-- commits | +-- commit_deployments | | +-- statuses | +-- statuses +-- github_hooks +-- hooks +-- pull_requests +-- tasks +-- chunks
[ "stack", "+", "--", "api_clients", "+", "--", "commits", "|", "+", "--", "commit_deployments", "|", "|", "+", "--", "statuses", "|", "+", "--", "statuses", "+", "--", "github_hooks", "+", "--", "hooks", "+", "--", "pull_requests", "+", "--", "tasks", "...
f6b93d8a242962016e0f82e99c2eb223bdc75003
https://github.com/Shopify/shipit-engine/blob/f6b93d8a242962016e0f82e99c2eb223bdc75003/app/jobs/shipit/destroy_stack_job.rb#L17-L34
train
Delete all the resources in the given stack.
[ 30522, 13366, 4685, 30524, 8909, 1024, 9991, 1012, 8909, 1007, 1012, 20228, 12722, 1006, 1024, 8909, 1007, 10797, 1035, 10813, 2015, 1035, 8909, 2015, 1027, 2911, 4183, 1024, 1024, 10797, 3207, 24759, 6977, 3672, 1012, 2073, 1006, 10797, 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...
aws/aws-sdk-ruby
gems/aws-sdk-iam/lib/aws-sdk-iam/instance_profile.rb
Aws::IAM.InstanceProfile.add_role
def add_role(options = {}) options = options.merge(instance_profile_name: @name) resp = @client.add_role_to_instance_profile(options) resp.data end
ruby
def add_role(options = {}) options = options.merge(instance_profile_name: @name) resp = @client.add_role_to_instance_profile(options) resp.data end
[ "def", "add_role", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "instance_profile_name", ":", "@name", ")", "resp", "=", "@client", ".", "add_role_to_instance_profile", "(", "options", ")", "resp", ".", "data", "end" ]
@!group Actions @example Request syntax with placeholder values instance_profile.add_role({ role_name: "roleNameType", # required }) @param [Hash] options ({}) @option options [required, String] :role_name The name of the role to add. This parameter allows (through its [regex pattern][1]) a string...
[ "@!group", "Actions", "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-iam/lib/aws-sdk-iam/instance_profile.rb#L256-L260
train
Add a role to the instance profile
[ 30522, 13366, 5587, 1035, 2535, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 6013, 1035, 6337, 1035, 2171, 1024, 1030, 2171, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 5587, 1035, 2535, 1035, 2000, 1035, 6013, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
puppetlabs/puppet
lib/puppet/util/windows/registry.rb
Puppet::Util::Windows.Registry.values_by_name
def values_by_name(key, names) vals = {} names.each do |name| FFI::Pointer.from_string_to_wide_string(name) do |subkeyname_ptr| begin _, vals[name] = read(key, subkeyname_ptr) rescue Puppet::Util::Windows::Error => e # ignore missing names, but raise other...
ruby
def values_by_name(key, names) vals = {} names.each do |name| FFI::Pointer.from_string_to_wide_string(name) do |subkeyname_ptr| begin _, vals[name] = read(key, subkeyname_ptr) rescue Puppet::Util::Windows::Error => e # ignore missing names, but raise other...
[ "def", "values_by_name", "(", "key", ",", "names", ")", "vals", "=", "{", "}", "names", ".", "each", "do", "|", "name", "|", "FFI", "::", "Pointer", ".", "from_string_to_wide_string", "(", "name", ")", "do", "|", "subkeyname_ptr", "|", "begin", "_", ",...
Retrieve a set of values from a registry key given their names Value names listed but not found in the registry will not be added to the resultant Hashtable @param key [RegistryKey] An open handle to a Registry Key @param names [String[]] An array of names of registry values to return if they exist @return [Hasht...
[ "Retrieve", "a", "set", "of", "values", "from", "a", "registry", "key", "given", "their", "names", "Value", "names", "listed", "but", "not", "found", "in", "the", "registry", "will", "not", "be", "added", "to", "the", "resultant", "Hashtable" ]
4baeed97cbb7571ddc6635f0a24debe2e8b22cd3
https://github.com/puppetlabs/puppet/blob/4baeed97cbb7571ddc6635f0a24debe2e8b22cd3/lib/puppet/util/windows/registry.rb#L75-L88
train
Get the values of a set of keys by name
[ 30522, 13366, 5300, 1035, 2011, 1035, 2171, 1006, 3145, 1010, 3415, 1007, 11748, 2015, 1027, 1063, 1065, 3415, 1012, 2169, 2079, 1064, 2171, 1064, 21461, 2072, 1024, 1024, 20884, 1012, 2013, 1035, 5164, 1035, 2000, 1035, 2898, 1035, 5164, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
abonas/kubeclient
lib/kubeclient/common.rb
Kubeclient.ClientMixin.watch_entities
def watch_entities(resource_name, options = {}) ns = build_namespace_prefix(options[:namespace]) path = "watch/#{ns}#{resource_name}" path += "/#{options[:name]}" if options[:name] uri = @api_endpoint.merge("#{@api_endpoint.path}/#{@api_version}/#{path}") params = {} WATCH_ARGUMENT...
ruby
def watch_entities(resource_name, options = {}) ns = build_namespace_prefix(options[:namespace]) path = "watch/#{ns}#{resource_name}" path += "/#{options[:name]}" if options[:name] uri = @api_endpoint.merge("#{@api_endpoint.path}/#{@api_version}/#{path}") params = {} WATCH_ARGUMENT...
[ "def", "watch_entities", "(", "resource_name", ",", "options", "=", "{", "}", ")", "ns", "=", "build_namespace_prefix", "(", "options", "[", ":namespace", "]", ")", "path", "=", "\"watch/#{ns}#{resource_name}\"", "path", "+=", "\"/#{options[:name]}\"", "if", "opti...
Accepts the following options: :namespace (string) - the namespace of the entity. :name (string) - the name of the entity to watch. :label_selector (string) - a selector to restrict the list of returned objects by labels. :field_selector (string) - a selector to restrict the list of returned objects by fiel...
[ "Accepts", "the", "following", "options", ":", ":", "namespace", "(", "string", ")", "-", "the", "namespace", "of", "the", "entity", ".", ":", "name", "(", "string", ")", "-", "the", "name", "of", "the", "entity", "to", "watch", ".", ":", "label_select...
3630f6c82532fba04f3e1a62d6b99c6cf2910451
https://github.com/abonas/kubeclient/blob/3630f6c82532fba04f3e1a62d6b99c6cf2910451/lib/kubeclient/common.rb#L297-L313
train
Creates a watch stream for the specified resource.
[ 30522, 13366, 3422, 1035, 11422, 1006, 7692, 1035, 2171, 1010, 7047, 1027, 1063, 1065, 1007, 24978, 1027, 3857, 1035, 3415, 15327, 1035, 17576, 1006, 7047, 1031, 1024, 3415, 15327, 1033, 1007, 4130, 1027, 1000, 3422, 1013, 1001, 1063, 24978...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.tags_include
def tags_include(class_names:, value: nil) return unless class_names.is_a? Array class_names.flat_map do |class_name| value ? eles_by_json_visible_contains(class_name, value) : tags(class_name) end end
ruby
def tags_include(class_names:, value: nil) return unless class_names.is_a? Array class_names.flat_map do |class_name| value ? eles_by_json_visible_contains(class_name, value) : tags(class_name) end end
[ "def", "tags_include", "(", "class_names", ":", ",", "value", ":", "nil", ")", "return", "unless", "class_names", ".", "is_a?", "Array", "class_names", ".", "flat_map", "do", "|", "class_name", "|", "value", "?", "eles_by_json_visible_contains", "(", "class_name...
Returns all visible elements matching class_names and value This method calls find_element/s and element.value/text many times. So, if you set many class_names, this method's performance become worse. @param class_names [Array[String]] the class_names to search for @param value [String] the value to search for @r...
[ "Returns", "all", "visible", "elements", "matching", "class_names", "and", "value", "This", "method", "calls", "find_element", "/", "s", "and", "element", ".", "value", "/", "text", "many", "times", ".", "So", "if", "you", "set", "many", "class_names", "this...
1f5898400dd1928bfe42ddd5f842d1f8738f2f76
https://github.com/appium/ruby_lib/blob/1f5898400dd1928bfe42ddd5f842d1f8738f2f76/lib/appium_lib/ios/common/helper.rb#L267-L273
train
Returns an array of the tags that are in the specified class_names.
[ 30522, 13366, 22073, 1035, 2421, 1006, 2465, 1035, 3415, 1024, 1010, 3643, 1024, 9152, 2140, 1007, 2709, 4983, 2465, 1035, 3415, 1012, 2003, 1035, 1037, 1029, 9140, 2465, 1035, 3415, 1012, 4257, 1035, 4949, 2079, 1064, 2465, 1035, 2171, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
heroku/legacy-cli
lib/heroku/command/addons.rb
Heroku::Command.Addons.plans
def plans service = args.shift raise CommandFailed.new("Missing add-on service") if service.nil? service = get_service!(service) display_header("#{service['human_name']} Plans") plans = get_plans(:service => service['id']) plans = plans.sort_by { |p| [(!p['default']).to_s, p['pric...
ruby
def plans service = args.shift raise CommandFailed.new("Missing add-on service") if service.nil? service = get_service!(service) display_header("#{service['human_name']} Plans") plans = get_plans(:service => service['id']) plans = plans.sort_by { |p| [(!p['default']).to_s, p['pric...
[ "def", "plans", "service", "=", "args", ".", "shift", "raise", "CommandFailed", ".", "new", "(", "\"Missing add-on service\"", ")", "if", "service", ".", "nil?", "service", "=", "get_service!", "(", "service", ")", "display_header", "(", "\"#{service['human_name']...
addons:plans SERVICE list all available plans for an add-on service
[ "addons", ":", "plans", "SERVICE" ]
6f18521a258394bfb79e6b36f7160ad8559a8e16
https://github.com/heroku/legacy-cli/blob/6f18521a258394bfb79e6b36f7160ad8559a8e16/lib/heroku/command/addons.rb#L71-L90
train
Get all plans for a service
[ 30522, 13366, 3488, 2326, 1027, 12098, 5620, 1012, 5670, 5333, 3094, 7011, 18450, 1012, 2047, 1006, 1000, 4394, 5587, 1011, 2006, 2326, 1000, 1007, 2065, 2326, 1012, 9152, 2140, 1029, 2326, 1027, 2131, 1035, 2326, 999, 1006, 2326, 1007, 4...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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_container_registry/lib/2017-03-01/generated/azure_mgmt_container_registry/registries.rb
Azure::ContainerRegistry::Mgmt::V2017_03_01.Registries.begin_create_with_http_info
def begin_create_with_http_info(resource_group_name, registry_name, registry_create_parameters, custom_headers:nil) begin_create_async(resource_group_name, registry_name, registry_create_parameters, custom_headers:custom_headers).value! end
ruby
def begin_create_with_http_info(resource_group_name, registry_name, registry_create_parameters, custom_headers:nil) begin_create_async(resource_group_name, registry_name, registry_create_parameters, custom_headers:custom_headers).value! end
[ "def", "begin_create_with_http_info", "(", "resource_group_name", ",", "registry_name", ",", "registry_create_parameters", ",", "custom_headers", ":", "nil", ")", "begin_create_async", "(", "resource_group_name", ",", "registry_name", ",", "registry_create_parameters", ",", ...
Creates a container registry with the specified parameters. @param resource_group_name [String] The name of the resource group to which the container registry belongs. @param registry_name [String] The name of the container registry. @param registry_create_parameters [RegistryCreateParameters] The parameters for ...
[ "Creates", "a", "container", "registry", "with", "the", "specified", "parameters", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_container_registry/lib/2017-03-01/generated/azure_mgmt_container_registry/registries.rb#L901-L903
train
Creates a new container registry.
[ 30522, 13366, 4088, 1035, 3443, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 15584, 1035, 2171, 1010, 15584, 1035, 3443, 1035, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 4088, 1035, 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...
aws/aws-sdk-ruby
gems/aws-sdk-opsworks/lib/aws-sdk-opsworks/stack.rb
Aws::OpsWorks.Stack.delete
def delete(options = {}) options = options.merge(stack_id: @id) resp = @client.delete_stack(options) resp.data end
ruby
def delete(options = {}) options = options.merge(stack_id: @id) resp = @client.delete_stack(options) resp.data end
[ "def", "delete", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "stack_id", ":", "@id", ")", "resp", "=", "@client", ".", "delete_stack", "(", "options", ")", "resp", ".", "data", "end" ]
@example Request syntax with placeholder values stack.delete() @param [Hash] options ({}) @return [EmptyStructure]
[ "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-opsworks/lib/aws-sdk-opsworks/stack.rb#L517-L521
train
Delete a stack
[ 30522, 13366, 3972, 12870, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 9991, 1035, 8909, 1024, 1030, 8909, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 3972, 12870, 1035, 9991, 1006, 7047, 1007, 24501, 2361, 1012,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_customvisiontraining/lib/3.0/generated/azure_cognitiveservices_customvisiontraining/customvisiontraining_client.rb
Azure::CognitiveServices::Customvisiontraining::V3_0.CustomvisiontrainingClient.get_iteration_performance_with_http_info
def get_iteration_performance_with_http_info(project_id, iteration_id, threshold:nil, overlap_threshold:nil, custom_headers:nil) get_iteration_performance_async(project_id, iteration_id, threshold:threshold, overlap_threshold:overlap_threshold, custom_headers:custom_headers).value! end
ruby
def get_iteration_performance_with_http_info(project_id, iteration_id, threshold:nil, overlap_threshold:nil, custom_headers:nil) get_iteration_performance_async(project_id, iteration_id, threshold:threshold, overlap_threshold:overlap_threshold, custom_headers:custom_headers).value! end
[ "def", "get_iteration_performance_with_http_info", "(", "project_id", ",", "iteration_id", ",", "threshold", ":", "nil", ",", "overlap_threshold", ":", "nil", ",", "custom_headers", ":", "nil", ")", "get_iteration_performance_async", "(", "project_id", ",", "iteration_i...
Get detailed performance information about an iteration. @param project_id The id of the project the iteration belongs to. @param iteration_id The id of the iteration to get. @param threshold [Float] The threshold used to determine true predictions. @param overlap_threshold [Float] If applicable, the bounding box ...
[ "Get", "detailed", "performance", "information", "about", "an", "iteration", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_customvisiontraining/lib/3.0/generated/azure_cognitiveservices_customvisiontraining/customvisiontraining_client.rb#L2454-L2456
train
Gets the performance of the iteration.
[ 30522, 13366, 2131, 1035, 27758, 1035, 2836, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 2622, 1035, 8909, 1010, 27758, 1035, 8909, 1010, 11207, 1024, 9152, 2140, 1010, 17702, 1035, 11207, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 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...
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_web_worker_metric_definitions_next
def list_web_worker_metric_definitions_next(next_page_link, custom_headers:nil) response = list_web_worker_metric_definitions_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_web_worker_metric_definitions_next(next_page_link, custom_headers:nil) response = list_web_worker_metric_definitions_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_web_worker_metric_definitions_next", "(", "next_page_link", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_web_worker_metric_definitions_next_async", "(", "next_page_link", ",", "custom_headers", ":custom_headers", ")", ".", "value!", "response", ...
Get metric definitions for a worker pool of an App Service Environment. Get metric definitions for a worker pool of an App Service Environment. @param next_page_link [String] The NextLink from the previous successful call to List operation. @param custom_headers [Hash{String => String}] A hash of custom headers t...
[ "Get", "metric", "definitions", "for", "a", "worker", "pool", "of", "an", "App", "Service", "Environment", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_web/lib/2018-02-01/generated/azure_mgmt_web/app_service_environments.rb#L6754-L6757
train
Gets the metric definitions for a worker.
[ 30522, 13366, 2862, 1035, 4773, 1035, 7309, 1035, 12046, 1035, 15182, 1035, 2279, 1006, 2279, 1035, 3931, 1035, 4957, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 4773, 1035, 7309, 1035, 12046, 1035, 15182,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/request.rb
HTTP.Request.proxy_connect_headers
def proxy_connect_headers connect_headers = HTTP::Headers.coerce( Headers::HOST => headers[Headers::HOST], Headers::USER_AGENT => headers[Headers::USER_AGENT] ) connect_headers[Headers::PROXY_AUTHORIZATION] = proxy_authorization_header if using_authenticated_proxy? conne...
ruby
def proxy_connect_headers connect_headers = HTTP::Headers.coerce( Headers::HOST => headers[Headers::HOST], Headers::USER_AGENT => headers[Headers::USER_AGENT] ) connect_headers[Headers::PROXY_AUTHORIZATION] = proxy_authorization_header if using_authenticated_proxy? conne...
[ "def", "proxy_connect_headers", "connect_headers", "=", "HTTP", "::", "Headers", ".", "coerce", "(", "Headers", "::", "HOST", "=>", "headers", "[", "Headers", "::", "HOST", "]", ",", "Headers", "::", "USER_AGENT", "=>", "headers", "[", "Headers", "::", "USER...
Headers to send with proxy connect request
[ "Headers", "to", "send", "with", "proxy", "connect", "request" ]
f37a10ea4fab3ee411907ea2e4251ddf0ca33a93
https://github.com/httprb/http/blob/f37a10ea4fab3ee411907ea2e4251ddf0ca33a93/lib/http/request.rb#L169-L178
train
Return the connection headers for the proxy
[ 30522, 13366, 24540, 1035, 7532, 1035, 20346, 2015, 7532, 1035, 20346, 2015, 1027, 8299, 1024, 1024, 20346, 2015, 1012, 24873, 19170, 1006, 20346, 2015, 1024, 1024, 3677, 1027, 1028, 20346, 2015, 1031, 20346, 2015, 1024, 1024, 3677, 1033, 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_relay/lib/2016-07-01/generated/azure_mgmt_relay/namespaces.rb
Azure::Relay::Mgmt::V2016_07_01.Namespaces.list_post_authorization_rules_next
def list_post_authorization_rules_next(next_page_link, custom_headers:nil) response = list_post_authorization_rules_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_post_authorization_rules_next(next_page_link, custom_headers:nil) response = list_post_authorization_rules_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_post_authorization_rules_next", "(", "next_page_link", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_post_authorization_rules_next_async", "(", "next_page_link", ",", "custom_headers", ":custom_headers", ")", ".", "value!", "response", ".", "...
Authorization rules for a namespace. @param next_page_link [String] The NextLink from the previous successful call to List operation. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [AuthorizationRuleListResult] operation results.
[ "Authorization", "rules", "for", "a", "namespace", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_relay/lib/2016-07-01/generated/azure_mgmt_relay/namespaces.rb#L1930-L1933
train
Gets the list of post authorization rules.
[ 30522, 13366, 2862, 1035, 2695, 1035, 20104, 1035, 3513, 1035, 2279, 1006, 2279, 1035, 3931, 1035, 4957, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 2695, 1035, 20104, 1035, 3513, 1035, 2279, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ruby2d/ruby2d
lib/ruby2d/window.rb
Ruby2D.Window.add_object
def add_object(o) if !@objects.include?(o) index = @objects.index do |object| object.z > o.z end if index @objects.insert(index, o) else @objects.push(o) end true else false end end
ruby
def add_object(o) if !@objects.include?(o) index = @objects.index do |object| object.z > o.z end if index @objects.insert(index, o) else @objects.push(o) end true else false end end
[ "def", "add_object", "(", "o", ")", "if", "!", "@objects", ".", "include?", "(", "o", ")", "index", "=", "@objects", ".", "index", "do", "|", "object", "|", "object", ".", "z", ">", "o", ".", "z", "end", "if", "index", "@objects", ".", "insert", ...
An an object to the window, used by the public `add` method
[ "An", "an", "object", "to", "the", "window", "used", "by", "the", "public", "add", "method" ]
43ce9805a7ae8b82b7ab8c50bf6d4c845d395dc4
https://github.com/ruby2d/ruby2d/blob/43ce9805a7ae8b82b7ab8c50bf6d4c845d395dc4/lib/ruby2d/window.rb#L419-L433
train
Add an object to the object list
[ 30522, 13366, 5587, 1035, 4874, 1006, 1051, 1007, 2065, 999, 1030, 5200, 1012, 2421, 1029, 1006, 1051, 1007, 5950, 1027, 1030, 5200, 1012, 5950, 2079, 1064, 4874, 1064, 4874, 1012, 1062, 1028, 1051, 1012, 1062, 2203, 2065, 5950, 1030, 520...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/key_pair_info.rb
Aws::EC2.KeyPairInfo.delete
def delete(options = {}) options = options.merge(key_name: @name) resp = @client.delete_key_pair(options) resp.data end
ruby
def delete(options = {}) options = options.merge(key_name: @name) resp = @client.delete_key_pair(options) resp.data end
[ "def", "delete", "(", "options", "=", "{", "}", ")", "options", "=", "options", ".", "merge", "(", "key_name", ":", "@name", ")", "resp", "=", "@client", ".", "delete_key_pair", "(", "options", ")", "resp", ".", "data", "end" ]
@!group Actions @example Request syntax with placeholder values key_pair_info.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 respons...
[ "@!group", "Actions", "@example", "Request", "syntax", "with", "placeholder", "values" ]
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-ec2/lib/aws-sdk-ec2/key_pair_info.rb#L187-L191
train
Delete the key pair
[ 30522, 13366, 3972, 12870, 1006, 7047, 1027, 1063, 1065, 1007, 7047, 1027, 7047, 1012, 13590, 1006, 3145, 1035, 2171, 1024, 1030, 2171, 1007, 24501, 2361, 1027, 1030, 7396, 1012, 3972, 12870, 1035, 3145, 1035, 3940, 1006, 7047, 1007, 24501,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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-initiatives/app/models/decidim/initiatives_vote.rb
Decidim.InitiativesVote.sha1
def sha1 return unless decidim_user_group_id.nil? title = translated_attribute(initiative.title) description = translated_attribute(initiative.description) Digest::SHA1.hexdigest "#{authorization_unique_id}#{title}#{description}" end
ruby
def sha1 return unless decidim_user_group_id.nil? title = translated_attribute(initiative.title) description = translated_attribute(initiative.description) Digest::SHA1.hexdigest "#{authorization_unique_id}#{title}#{description}" end
[ "def", "sha1", "return", "unless", "decidim_user_group_id", ".", "nil?", "title", "=", "translated_attribute", "(", "initiative", ".", "title", ")", "description", "=", "translated_attribute", "(", "initiative", ".", "description", ")", "Digest", "::", "SHA1", "."...
PUBLIC Generates a hashed representation of the initiative support.
[ "PUBLIC" ]
6e2b14e559a63088669904e3c5c49a5180700cf7
https://github.com/decidim/decidim/blob/6e2b14e559a63088669904e3c5c49a5180700cf7/decidim-initiatives/app/models/decidim/initiatives_vote.rb#L34-L41
train
Returns the SHA1 hash of the object
[ 30522, 13366, 21146, 2487, 2709, 4983, 11703, 28173, 2213, 1035, 5310, 1035, 2177, 1035, 8909, 1012, 9152, 2140, 1029, 2516, 1027, 5421, 1035, 17961, 1006, 6349, 1012, 2516, 1007, 6412, 1027, 5421, 1035, 17961, 1006, 6349, 1012, 6412, 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_event_grid/lib/2018-01-01/generated/azure_mgmt_event_grid/event_subscriptions.rb
Azure::EventGrid::Mgmt::V2018_01_01.EventSubscriptions.delete_async
def delete_async(scope, event_subscription_name, custom_headers:nil) # Send request promise = begin_delete_async(scope, event_subscription_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parse...
ruby
def delete_async(scope, event_subscription_name, custom_headers:nil) # Send request promise = begin_delete_async(scope, event_subscription_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parse...
[ "def", "delete_async", "(", "scope", ",", "event_subscription_name", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_delete_async", "(", "scope", ",", "event_subscription_name", ",", "custom_headers", ":custom_headers", ")", "promise", ...
@param scope [String] The scope of the event subscription. The scope can be a subscription, or a resource group, or a top level resource belonging to a resource provider namespace, or an EventGrid topic. For example, use '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourc...
[ "@param", "scope", "[", "String", "]", "The", "scope", "of", "the", "event", "subscription", ".", "The", "scope", "can", "be", "a", "subscription", "or", "a", "resource", "group", "or", "a", "top", "level", "resource", "belonging", "to", "a", "resource", ...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_event_grid/lib/2018-01-01/generated/azure_mgmt_event_grid/event_subscriptions.rb#L264-L278
train
Deletes an event subscription.
[ 30522, 13366, 3972, 12870, 1035, 2004, 6038, 2278, 1006, 9531, 1010, 2724, 1035, 15002, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 1001, 4604, 5227, 4872, 1027, 4088, 30524, 1012, 4078, 11610, 3669, 4371, 1035, 4118,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
cheezy/page-object
lib/page-object/accessors.rb
PageObject.Accessors.text_area
def text_area(name, identifier={:index => 0}, &block) standard_methods(name, identifier, 'text_area_for', &block) define_method(name) do return platform.text_area_value_for identifier.clone unless block_given? self.send("#{name}_element").value end define_method("#{name}=") do |v...
ruby
def text_area(name, identifier={:index => 0}, &block) standard_methods(name, identifier, 'text_area_for', &block) define_method(name) do return platform.text_area_value_for identifier.clone unless block_given? self.send("#{name}_element").value end define_method("#{name}=") do |v...
[ "def", "text_area", "(", "name", ",", "identifier", "=", "{", ":index", "=>", "0", "}", ",", "&", "block", ")", "standard_methods", "(", "name", ",", "identifier", ",", "'text_area_for'", ",", "block", ")", "define_method", "(", "name", ")", "do", "retur...
adds four methods to the page object - one to set text in a text area, another to retrieve text from a text area, another to return the text area element, and another to check the text area's existence. @example text_area(:address, :id => "address") # will generate 'address', 'address=', 'address_element', ...
[ "adds", "four", "methods", "to", "the", "page", "object", "-", "one", "to", "set", "text", "in", "a", "text", "area", "another", "to", "retrieve", "text", "from", "a", "text", "area", "another", "to", "return", "the", "text", "area", "element", "and", ...
850d775bf63768fbb1551a34480195785fe8e193
https://github.com/cheezy/page-object/blob/850d775bf63768fbb1551a34480195785fe8e193/lib/page-object/accessors.rb#L244-L254
train
Define a text area method.
[ 30522, 13366, 3793, 1035, 2181, 1006, 2171, 1010, 8909, 4765, 18095, 1027, 1063, 1024, 5950, 1027, 1028, 1014, 1065, 1010, 1004, 3796, 1007, 3115, 1035, 4725, 1006, 2171, 1010, 8909, 4765, 18095, 1010, 1005, 3793, 1035, 2181, 1035, 2005, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.remove_label
def remove_label(label) unless label.valid? errors.add(:label, "is not valid.") return Trello.logger.warn "Label is not valid." unless label.valid? end client.delete("/cards/#{id}/idLabels/#{label.id}") end
ruby
def remove_label(label) unless label.valid? errors.add(:label, "is not valid.") return Trello.logger.warn "Label is not valid." unless label.valid? end client.delete("/cards/#{id}/idLabels/#{label.id}") end
[ "def", "remove_label", "(", "label", ")", "unless", "label", ".", "valid?", "errors", ".", "add", "(", ":label", ",", "\"is not valid.\"", ")", "return", "Trello", ".", "logger", ".", "warn", "\"Label is not valid.\"", "unless", "label", ".", "valid?", "end", ...
Remove a label
[ "Remove", "a", "label" ]
ad79c9d8152ad5395b3b61c43170908f1912bfb2
https://github.com/jeremytregunna/ruby-trello/blob/ad79c9d8152ad5395b3b61c43170908f1912bfb2/lib/trello/card.rb#L412-L418
train
Remove a label from the card
[ 30522, 13366, 6366, 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...
guard/guard
lib/guard/dsl_describer.rb
Guard.DslDescriber.show
def show # collect metadata groups = Guard.state.session.groups.all objects = [] empty_plugin = OpenStruct.new empty_plugin.options = [["", nil]] groups.each do |group| plugins = Array(Guard.state.session.plugins.all(group: group.name)) plugins = [empty_plugin] if ...
ruby
def show # collect metadata groups = Guard.state.session.groups.all objects = [] empty_plugin = OpenStruct.new empty_plugin.options = [["", nil]] groups.each do |group| plugins = Array(Guard.state.session.plugins.all(group: group.name)) plugins = [empty_plugin] if ...
[ "def", "show", "# collect metadata", "groups", "=", "Guard", ".", "state", ".", "session", ".", "groups", ".", "all", "objects", "=", "[", "]", "empty_plugin", "=", "OpenStruct", ".", "new", "empty_plugin", ".", "options", "=", "[", "[", "\"\"", ",", "ni...
Shows all Guard plugins and their options that are defined in the `Guardfile`. @see CLI#show
[ "Shows", "all", "Guard", "plugins", "and", "their", "options", "that", "are", "defined", "in", "the", "Guardfile", "." ]
e2508cd83badf0d537dbaba35d307adc35d92e4f
https://github.com/guard/guard/blob/e2508cd83badf0d537dbaba35d307adc35d92e4f/lib/guard/dsl_describer.rb#L53-L102
train
show a list of all the available objects in the current session
[ 30522, 13366, 2265, 1001, 8145, 27425, 2967, 1027, 3457, 1012, 2110, 1012, 5219, 1012, 2967, 1012, 2035, 5200, 1027, 1031, 1033, 4064, 1035, 13354, 2378, 1027, 7480, 18300, 1012, 2047, 4064, 1035, 13354, 2378, 1012, 7047, 1027, 1031, 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...
uken/fluent-plugin-elasticsearch
lib/fluent/plugin/out_elasticsearch.rb
Fluent::Plugin.ElasticsearchOutput.create_time_parser
def create_time_parser if @time_key_format begin # Strptime doesn't support all formats, but for those it does it's # blazingly fast. strptime = Strptime.new(@time_key_format) Proc.new { |value| value = convert_numeric_time_into_string(value, @time_key_f...
ruby
def create_time_parser if @time_key_format begin # Strptime doesn't support all formats, but for those it does it's # blazingly fast. strptime = Strptime.new(@time_key_format) Proc.new { |value| value = convert_numeric_time_into_string(value, @time_key_f...
[ "def", "create_time_parser", "if", "@time_key_format", "begin", "# Strptime doesn't support all formats, but for those it does it's", "# blazingly fast.", "strptime", "=", "Strptime", ".", "new", "(", "@time_key_format", ")", "Proc", ".", "new", "{", "|", "value", "|", "v...
once fluent v0.14 is released we might be able to use Fluent::Parser::TimeParser, but it doesn't quite do what we want - if gives [sec,nsec] where as we want something we can call `strftime` on...
[ "once", "fluent", "v0", ".", "14", "is", "released", "we", "might", "be", "able", "to", "use", "Fluent", "::", "Parser", "::", "TimeParser", "but", "it", "doesn", "t", "quite", "do", "what", "we", "want", "-", "if", "gives", "[", "sec", "nsec", "]", ...
9f9e51ddd012acb36c7f9d7a16e00970004098bc
https://github.com/uken/fluent-plugin-elasticsearch/blob/9f9e51ddd012acb36c7f9d7a16e00970004098bc/lib/fluent/plugin/out_elasticsearch.rb#L357-L382
train
Create a new instance of the DateTimeParser class.
[ 30522, 13366, 3443, 1035, 2051, 1035, 11968, 8043, 2065, 1030, 2051, 1035, 3145, 1035, 4289, 4088, 1001, 2358, 14536, 7292, 2987, 1005, 1056, 2490, 2035, 11630, 1010, 2021, 2005, 2216, 2009, 2515, 2009, 1005, 1055, 1001, 17162, 2135, 3435, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/encoding_utils.rb
Sprockets.EncodingUtils.detect_unicode
def detect_unicode(str) str = detect_unicode_bom(str) # Fallback to UTF-8 if str.encoding == Encoding::BINARY str.force_encoding(Encoding::UTF_8) end str end
ruby
def detect_unicode(str) str = detect_unicode_bom(str) # Fallback to UTF-8 if str.encoding == Encoding::BINARY str.force_encoding(Encoding::UTF_8) end str end
[ "def", "detect_unicode", "(", "str", ")", "str", "=", "detect_unicode_bom", "(", "str", ")", "# Fallback to UTF-8", "if", "str", ".", "encoding", "==", "Encoding", "::", "BINARY", "str", ".", "force_encoding", "(", "Encoding", "::", "UTF_8", ")", "end", "str...
Public: Detect Unicode string. Attempts to parse Unicode BOM and falls back to UTF-8. str - ASCII-8BIT encoded String Returns encoded String.
[ "Public", ":", "Detect", "Unicode", "string", "." ]
9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd
https://github.com/rails/sprockets/blob/9e3f0d8e98c44f57e67bc138db87bb8469bf5ddd/lib/sprockets/encoding_utils.rb#L139-L148
train
Detect unicode encoding of a string
[ 30522, 13366, 11487, 1035, 27260, 1006, 2358, 2099, 1007, 2358, 2099, 1027, 11487, 1035, 27260, 1035, 8945, 2213, 1006, 2358, 2099, 1007, 1001, 2991, 5963, 2000, 21183, 2546, 1011, 1022, 2065, 2358, 2099, 1012, 17181, 1027, 1027, 17181, 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...
jekyll/jekyll
lib/jekyll/renderer.rb
Jekyll.Renderer.run
def run Jekyll.logger.debug "Rendering:", document.relative_path assign_pages! assign_current_document! assign_highlighter_options! assign_layout_data! Jekyll.logger.debug "Pre-Render Hooks:", document.relative_path document.trigger_hooks(:pre_render, payload) render_d...
ruby
def run Jekyll.logger.debug "Rendering:", document.relative_path assign_pages! assign_current_document! assign_highlighter_options! assign_layout_data! Jekyll.logger.debug "Pre-Render Hooks:", document.relative_path document.trigger_hooks(:pre_render, payload) render_d...
[ "def", "run", "Jekyll", ".", "logger", ".", "debug", "\"Rendering:\"", ",", "document", ".", "relative_path", "assign_pages!", "assign_current_document!", "assign_highlighter_options!", "assign_layout_data!", "Jekyll", ".", "logger", ".", "debug", "\"Pre-Render Hooks:\"", ...
Prepare payload and render the document Returns String rendered document output
[ "Prepare", "payload", "and", "render", "the", "document" ]
fd74fe3e93a1fb506fa6621a2e271d7b9c5c3e3b
https://github.com/jekyll/jekyll/blob/fd74fe3e93a1fb506fa6621a2e271d7b9c5c3e3b/lib/jekyll/renderer.rb#L52-L64
train
Run the document using the specified parameters.
[ 30522, 13366, 2448, 15333, 4801, 3363, 1012, 8833, 4590, 1012, 2139, 8569, 2290, 1000, 14259, 1024, 1000, 1010, 6254, 1012, 5816, 1035, 4130, 23911, 1035, 5530, 999, 23911, 1035, 2783, 1035, 6254, 999, 23911, 1035, 12944, 2121, 1035, 7047, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
sunspot/sunspot
sunspot/lib/sunspot/setup.rb
Sunspot.Setup.all_more_like_this_fields
def all_more_like_this_fields @more_like_this_field_factories_cache.values.map do |field_factories| field_factories.map { |field_factory| field_factory.build } end.flatten end
ruby
def all_more_like_this_fields @more_like_this_field_factories_cache.values.map do |field_factories| field_factories.map { |field_factory| field_factory.build } end.flatten end
[ "def", "all_more_like_this_fields", "@more_like_this_field_factories_cache", ".", "values", ".", "map", "do", "|", "field_factories", "|", "field_factories", ".", "map", "{", "|", "field_factory", "|", "field_factory", ".", "build", "}", "end", ".", "flatten", "end"...
Return all more_like_this fields
[ "Return", "all", "more_like_this", "fields" ]
31dd76cd7a14a4ef7bd541de97483d8cd72ff685
https://github.com/sunspot/sunspot/blob/31dd76cd7a14a4ef7bd541de97483d8cd72ff685/sunspot/lib/sunspot/setup.rb#L200-L204
train
Returns all the more like this fields
[ 30522, 13366, 2035, 1035, 2062, 1035, 2066, 1035, 2023, 1035, 4249, 1030, 2062, 1035, 2066, 1035, 2023, 1035, 2492, 1035, 11123, 1035, 17053, 1012, 5300, 1012, 4949, 2079, 1064, 2492, 1035, 11123, 1064, 2492, 1035, 11123, 1012, 4949, 1063, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/express_route_cross_connection_peerings.rb
Azure::Network::Mgmt::V2018_07_01.ExpressRouteCrossConnectionPeerings.list
def list(resource_group_name, cross_connection_name, custom_headers:nil) first_page = list_as_lazy(resource_group_name, cross_connection_name, custom_headers:custom_headers) first_page.get_all_items end
ruby
def list(resource_group_name, cross_connection_name, custom_headers:nil) first_page = list_as_lazy(resource_group_name, cross_connection_name, custom_headers:custom_headers) first_page.get_all_items end
[ "def", "list", "(", "resource_group_name", ",", "cross_connection_name", ",", "custom_headers", ":", "nil", ")", "first_page", "=", "list_as_lazy", "(", "resource_group_name", ",", "cross_connection_name", ",", "custom_headers", ":custom_headers", ")", "first_page", "."...
Gets all peerings in a specified ExpressRouteCrossConnection. @param resource_group_name [String] The name of the resource group. @param cross_connection_name [String] The name of the ExpressRouteCrossConnection. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTT...
[ "Gets", "all", "peerings", "in", "a", "specified", "ExpressRouteCrossConnection", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-07-01/generated/azure_mgmt_network/express_route_cross_connection_peerings.rb#L35-L38
train
Gets all the available virtual network endpoints in a cross connection.
[ 30522, 13366, 2862, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2892, 1035, 4434, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2034, 1035, 3931, 1027, 2862, 1035, 2004, 1035, 13971, 1006, 7692, 1035, 2177, 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...
fastlane/fastlane
spaceship/lib/spaceship/client.rb
Spaceship.Client.send_request
def send_request(method, url_or_path, params, headers, &block) with_retry do response = @client.send(method, url_or_path, params, headers, &block) log_response(method, url_or_path, response, headers, &block) resp_hash = response.to_hash if resp_hash[:status] == 401 msg =...
ruby
def send_request(method, url_or_path, params, headers, &block) with_retry do response = @client.send(method, url_or_path, params, headers, &block) log_response(method, url_or_path, response, headers, &block) resp_hash = response.to_hash if resp_hash[:status] == 401 msg =...
[ "def", "send_request", "(", "method", ",", "url_or_path", ",", "params", ",", "headers", ",", "&", "block", ")", "with_retry", "do", "response", "=", "@client", ".", "send", "(", "method", ",", "url_or_path", ",", "params", ",", "headers", ",", "block", ...
Actually sends the request to the remote server Automatically retries the request up to 3 times if something goes wrong
[ "Actually", "sends", "the", "request", "to", "the", "remote", "server", "Automatically", "retries", "the", "request", "up", "to", "3", "times", "if", "something", "goes", "wrong" ]
457c5d647c77f0e078dafa5129da616914e002c5
https://github.com/fastlane/fastlane/blob/457c5d647c77f0e078dafa5129da616914e002c5/spaceship/lib/spaceship/client.rb#L843-L865
train
Send a request to the server
[ 30522, 13366, 4604, 1035, 5227, 1006, 4118, 1010, 24471, 2140, 1035, 2030, 1035, 4130, 1010, 11498, 5244, 1010, 20346, 2015, 1010, 1004, 3796, 1007, 2007, 1035, 2128, 11129, 2079, 3433, 1027, 1030, 7396, 1012, 4604, 1006, 4118, 1010, 24471,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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-07-01/generated/azure_mgmt_storage/blob_containers.rb
Azure::Storage::Mgmt::V2018_07_01.BlobContainers.clear_legal_hold_with_http_info
def clear_legal_hold_with_http_info(resource_group_name, account_name, container_name, legal_hold, custom_headers:nil) clear_legal_hold_async(resource_group_name, account_name, container_name, legal_hold, custom_headers:custom_headers).value! end
ruby
def clear_legal_hold_with_http_info(resource_group_name, account_name, container_name, legal_hold, custom_headers:nil) clear_legal_hold_async(resource_group_name, account_name, container_name, legal_hold, custom_headers:custom_headers).value! end
[ "def", "clear_legal_hold_with_http_info", "(", "resource_group_name", ",", "account_name", ",", "container_name", ",", "legal_hold", ",", "custom_headers", ":", "nil", ")", "clear_legal_hold_async", "(", "resource_group_name", ",", "account_name", ",", "container_name", "...
Clears legal hold tags. Clearing the same or non-existent tag results in an idempotent operation. ClearLegalHold clears out only the specified tags in the request. @param resource_group_name [String] The name of the resource group within the user's subscription. The name is case insensitive. @param account_name [...
[ "Clears", "legal", "hold", "tags", ".", "Clearing", "the", "same", "or", "non", "-", "existent", "tag", "results", "in", "an", "idempotent", "operation", ".", "ClearLegalHold", "clears", "out", "only", "the", "specified", "tags", "in", "the", "request", "." ...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_storage/lib/2018-07-01/generated/azure_mgmt_storage/blob_containers.rb#L866-L868
train
Clear the legal hold of a container.
[ 30522, 13366, 3154, 1035, 3423, 1035, 2907, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 4070, 1035, 2171, 1010, 11661, 1035, 2171, 1010, 3423, 1035, 2907, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_event_hub/lib/2018-01-01-preview/generated/azure_mgmt_event_hub/namespaces.rb
Azure::EventHub::Mgmt::V2018_01_01_preview.Namespaces.create_or_update_async
def create_or_update_async(resource_group_name, namespace_name, parameters, custom_headers:nil) # Send request promise = begin_create_or_update_async(resource_group_name, namespace_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization...
ruby
def create_or_update_async(resource_group_name, namespace_name, parameters, custom_headers:nil) # Send request promise = begin_create_or_update_async(resource_group_name, namespace_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization...
[ "def", "create_or_update_async", "(", "resource_group_name", ",", "namespace_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_create_or_update_async", "(", "resource_group_name", ",", "namespace_name", ",", "parame...
@param resource_group_name [String] Name of the resource group within the Azure subscription. @param namespace_name [String] The Namespace name @param parameters [EHNamespace] Parameters for creating a namespace resource. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to...
[ "@param", "resource_group_name", "[", "String", "]", "Name", "of", "the", "resource", "group", "within", "the", "Azure", "subscription", ".", "@param", "namespace_name", "[", "String", "]", "The", "Namespace", "name", "@param", "parameters", "[", "EHNamespace", ...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_event_hub/lib/2018-01-01-preview/generated/azure_mgmt_event_hub/namespaces.rb#L234-L250
train
Creates or updates a namespace.
[ 30522, 13366, 3443, 1035, 2030, 1035, 10651, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 3415, 15327, 1035, 2171, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 1001, 4604, 5227, 4872, 1027, 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
management/azure_mgmt_storage/lib/2018-07-01/generated/azure_mgmt_storage/blob_containers.rb
Azure::Storage::Mgmt::V2018_07_01.BlobContainers.delete_immutability_policy
def delete_immutability_policy(resource_group_name, account_name, container_name, if_match, custom_headers:nil) response = delete_immutability_policy_async(resource_group_name, account_name, container_name, if_match, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def delete_immutability_policy(resource_group_name, account_name, container_name, if_match, custom_headers:nil) response = delete_immutability_policy_async(resource_group_name, account_name, container_name, if_match, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "delete_immutability_policy", "(", "resource_group_name", ",", "account_name", ",", "container_name", ",", "if_match", ",", "custom_headers", ":", "nil", ")", "response", "=", "delete_immutability_policy_async", "(", "resource_group_name", ",", "account_name", ",",...
Aborts an unlocked immutability policy. The response of delete has immutabilityPeriodSinceCreationInDays set to 0. ETag in If-Match is required for this operation. Deleting a locked immutability policy is not allowed, only way is to delete the container after deleting all blobs inside the container. @param resour...
[ "Aborts", "an", "unlocked", "immutability", "policy", ".", "The", "response", "of", "delete", "has", "immutabilityPeriodSinceCreationInDays", "set", "to", "0", ".", "ETag", "in", "If", "-", "Match", "is", "required", "for", "this", "operation", ".", "Deleting", ...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_storage/lib/2018-07-01/generated/azure_mgmt_storage/blob_containers.rb#L1288-L1291
train
Deletes the immutability policy for the specified container.
[ 30522, 13366, 3972, 12870, 1035, 10047, 28120, 8010, 1035, 3343, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 4070, 1035, 2171, 1010, 11661, 1035, 2171, 1010, 2065, 1035, 2674, 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...
puppetlabs/bolt
lib/bolt/target.rb
Bolt.Target.update_conf
def update_conf(conf) @protocol = conf[:transport] t_conf = conf[:transports][transport.to_sym] || {} # Override url methods @user = t_conf['user'] @password = t_conf['password'] @port = t_conf['port'] @host = t_conf['host'] # Preserve everything in options so we can ea...
ruby
def update_conf(conf) @protocol = conf[:transport] t_conf = conf[:transports][transport.to_sym] || {} # Override url methods @user = t_conf['user'] @password = t_conf['password'] @port = t_conf['port'] @host = t_conf['host'] # Preserve everything in options so we can ea...
[ "def", "update_conf", "(", "conf", ")", "@protocol", "=", "conf", "[", ":transport", "]", "t_conf", "=", "conf", "[", ":transports", "]", "[", "transport", ".", "to_sym", "]", "||", "{", "}", "# Override url methods", "@user", "=", "t_conf", "[", "'user'",...
URI can be passes as nil
[ "URI", "can", "be", "passes", "as", "nil" ]
50689a33699939d262ea7c822a4b24fd8c4f8d8a
https://github.com/puppetlabs/bolt/blob/50689a33699939d262ea7c822a4b24fd8c4f8d8a/lib/bolt/target.rb#L53-L67
train
Update the configuration for this Target.
[ 30522, 13366, 10651, 1035, 9530, 2546, 1006, 9530, 2546, 1007, 1030, 8778, 1027, 9530, 2546, 1031, 1024, 3665, 1033, 1056, 1035, 9530, 2546, 1027, 9530, 2546, 1031, 1024, 19003, 1033, 1031, 3665, 1012, 2000, 1035, 25353, 2213, 1033, 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...
tongueroo/jets
lib/jets/stack/main/extensions/lambda.rb
Jets::Stack::Main::Dsl.Lambda.permission
def permission(id, props={}) defaults = { action: "lambda:InvokeFunction" } props = defaults.merge(props) resource(id, "AWS::Lambda::Permission", props) end
ruby
def permission(id, props={}) defaults = { action: "lambda:InvokeFunction" } props = defaults.merge(props) resource(id, "AWS::Lambda::Permission", props) end
[ "def", "permission", "(", "id", ",", "props", "=", "{", "}", ")", "defaults", "=", "{", "action", ":", "\"lambda:InvokeFunction\"", "}", "props", "=", "defaults", ".", "merge", "(", "props", ")", "resource", "(", "id", ",", "\"AWS::Lambda::Permission\"", "...
Usage: permission(:my_permission, principal: "events.amazonaws.com")
[ "Usage", ":" ]
46943a519224067e58aa3e2d5656e3ca083150f9
https://github.com/tongueroo/jets/blob/46943a519224067e58aa3e2d5656e3ca083150f9/lib/jets/stack/main/extensions/lambda.rb#L72-L76
train
Returns a permission resource
[ 30522, 13366, 6656, 1006, 8909, 1010, 24387, 1027, 1063, 1065, 1007, 12398, 2015, 1027, 1063, 2895, 1024, 1000, 23375, 1024, 1999, 6767, 3489, 11263, 27989, 1000, 1065, 24387, 1027, 12398, 2015, 1012, 13590, 1006, 24387, 1007, 7692, 1006, 8...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/element.rb
Watir.Element.drag_and_drop_by
def drag_and_drop_by(right_by, down_by) element_call(:wait_for_present) do driver.action .drag_and_drop_by(@element, right_by, down_by) .perform end end
ruby
def drag_and_drop_by(right_by, down_by) element_call(:wait_for_present) do driver.action .drag_and_drop_by(@element, right_by, down_by) .perform end end
[ "def", "drag_and_drop_by", "(", "right_by", ",", "down_by", ")", "element_call", "(", ":wait_for_present", ")", "do", "driver", ".", "action", ".", "drag_and_drop_by", "(", "@element", ",", "right_by", ",", "down_by", ")", ".", "perform", "end", "end" ]
Drag and drop this element by the given offsets. Note that browser support may vary. @example browser.div(id: "draggable").drag_and_drop_by 100, -200 @param [Integer] right_by @param [Integer] down_by
[ "Drag", "and", "drop", "this", "element", "by", "the", "given", "offsets", ".", "Note", "that", "browser", "support", "may", "vary", "." ]
2d8db09811c6221ae401b85b2f61f5fa66e463a3
https://github.com/watir/watir/blob/2d8db09811c6221ae401b85b2f61f5fa66e463a3/lib/watir/elements/element.rb#L256-L262
train
Drag and drop the element by the given coordinates.
[ 30522, 13366, 8011, 1035, 1998, 1035, 4530, 1035, 2011, 1006, 2157, 1035, 2011, 1010, 2091, 1035, 2011, 1007, 5783, 1035, 2655, 1006, 1024, 3524, 1035, 2005, 1035, 2556, 1007, 2079, 4062, 1012, 2895, 1012, 8011, 1035, 1998, 1035, 4530, 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_automation/lib/2015-10-31/generated/azure_mgmt_automation/usages.rb
Azure::Automation::Mgmt::V2015_10_31.Usages.list_by_automation_account
def list_by_automation_account(resource_group_name, automation_account_name, custom_headers:nil) response = list_by_automation_account_async(resource_group_name, automation_account_name, custom_headers:custom_headers).value! response.body unless response.nil? end
ruby
def list_by_automation_account(resource_group_name, automation_account_name, custom_headers:nil) response = list_by_automation_account_async(resource_group_name, automation_account_name, custom_headers:custom_headers).value! response.body unless response.nil? end
[ "def", "list_by_automation_account", "(", "resource_group_name", ",", "automation_account_name", ",", "custom_headers", ":", "nil", ")", "response", "=", "list_by_automation_account_async", "(", "resource_group_name", ",", "automation_account_name", ",", "custom_headers", ":c...
Retrieve the usage for the account id. @param resource_group_name [String] Name of an Azure Resource group. @param automation_account_name [String] The name of the automation account. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [UsageLis...
[ "Retrieve", "the", "usage", "for", "the", "account", "id", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_automation/lib/2015-10-31/generated/azure_mgmt_automation/usages.rb#L34-L37
train
Gets the list of all the automation terms of the specified automation account.
[ 30522, 13366, 2862, 1035, 2011, 1035, 19309, 1035, 4070, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 19309, 1035, 4070, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 3433, 1027, 2862, 1035, 2011, 1035, 19309, 1035, 4070, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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.rb
SCSSLint.Linter.source_from_range
def source_from_range(source_range) # rubocop:disable Metrics/AbcSize current_line = source_range.start_pos.line - 1 last_line = source_range.end_pos.line - 1 start_pos = source_range.start_pos.offset - 1 source = if current_line == last_line engine.lines[current_line][s...
ruby
def source_from_range(source_range) # rubocop:disable Metrics/AbcSize current_line = source_range.start_pos.line - 1 last_line = source_range.end_pos.line - 1 start_pos = source_range.start_pos.offset - 1 source = if current_line == last_line engine.lines[current_line][s...
[ "def", "source_from_range", "(", "source_range", ")", "# rubocop:disable Metrics/AbcSize", "current_line", "=", "source_range", ".", "start_pos", ".", "line", "-", "1", "last_line", "=", "source_range", ".", "end_pos", ".", "line", "-", "1", "start_pos", "=", "sou...
Extracts the original source code given a range. @param source_range [Sass::Source::Range] @return [String] the original source code
[ "Extracts", "the", "original", "source", "code", "given", "a", "range", "." ]
e99afe4ede041a431a06e585c12ce82f6ad50116
https://github.com/sds/scss-lint/blob/e99afe4ede041a431a06e585c12ce82f6ad50116/lib/scss_lint/linter.rb#L89-L112
train
Returns the source code from the given source range.
[ 30522, 13366, 3120, 1035, 2013, 1035, 2846, 1006, 3120, 1035, 2846, 1007, 1001, 14548, 24163, 2361, 1024, 4487, 19150, 12046, 2015, 1013, 5925, 5332, 4371, 2783, 1035, 2240, 1027, 3120, 1035, 2846, 1012, 2707, 1035, 13433, 2015, 1012, 2240,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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/transactions_api.rb
SquareConnect.TransactionsApi.void_transaction
def void_transaction(location_id, transaction_id, opts = {}) data, _status_code, _headers = void_transaction_with_http_info(location_id, transaction_id, opts) return data end
ruby
def void_transaction(location_id, transaction_id, opts = {}) data, _status_code, _headers = void_transaction_with_http_info(location_id, transaction_id, opts) return data end
[ "def", "void_transaction", "(", "location_id", ",", "transaction_id", ",", "opts", "=", "{", "}", ")", "data", ",", "_status_code", ",", "_headers", "=", "void_transaction_with_http_info", "(", "location_id", ",", "transaction_id", ",", "opts", ")", "return", "d...
VoidTransaction Cancels a transaction that was created with the [Charge](#endpoint-transactions-charge) endpoint with a `delay_capture` value of `true`. See [Delayed capture transactions](/payments/transactions/overview#delayed-capture) for more information. @param location_id @param transaction_id @param [Hash] o...
[ "VoidTransaction", "Cancels", "a", "transaction", "that", "was", "created", "with", "the", "[", "Charge", "]", "(", "#endpoint", "-", "transactions", "-", "charge", ")", "endpoint", "with", "a", "delay_capture", "value", "of", "true", ".", "See", "[", "Delay...
798eb9ded716f23b9f1518386f1c311a34bca8bf
https://github.com/square/connect-ruby-sdk/blob/798eb9ded716f23b9f1518386f1c311a34bca8bf/lib/square_connect/api/transactions_api.rb#L406-L409
train
Void a single transaction
[ 30522, 13366, 11675, 1035, 12598, 1006, 3295, 1035, 8909, 1010, 12598, 1035, 8909, 1010, 23569, 2015, 1027, 1063, 1065, 1007, 2951, 1010, 1035, 3570, 1035, 3642, 1010, 1035, 20346, 2015, 1027, 11675, 1035, 12598, 1035, 2007, 1035, 8299, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_network/lib/2018-08-01/generated/azure_mgmt_network/service_endpoint_policy_definitions.rb
Azure::Network::Mgmt::V2018_08_01.ServiceEndpointPolicyDefinitions.list_by_resource_group
def list_by_resource_group(resource_group_name, service_endpoint_policy_name, custom_headers:nil) first_page = list_by_resource_group_as_lazy(resource_group_name, service_endpoint_policy_name, custom_headers:custom_headers) first_page.get_all_items end
ruby
def list_by_resource_group(resource_group_name, service_endpoint_policy_name, custom_headers:nil) first_page = list_by_resource_group_as_lazy(resource_group_name, service_endpoint_policy_name, custom_headers:custom_headers) first_page.get_all_items end
[ "def", "list_by_resource_group", "(", "resource_group_name", ",", "service_endpoint_policy_name", ",", "custom_headers", ":", "nil", ")", "first_page", "=", "list_by_resource_group_as_lazy", "(", "resource_group_name", ",", "service_endpoint_policy_name", ",", "custom_headers",...
Gets all service endpoint policy definitions in a service end point policy. @param resource_group_name [String] The name of the resource group. @param service_endpoint_policy_name [String] The name of the service endpoint policy name. @param custom_headers [Hash{String => String}] A hash of custom headers that wi...
[ "Gets", "all", "service", "endpoint", "policy", "definitions", "in", "a", "service", "end", "point", "policy", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_network/lib/2018-08-01/generated/azure_mgmt_network/service_endpoint_policy_definitions.rb#L239-L242
train
Gets all the service endpoint policies in a resource group.
[ 30522, 13366, 2862, 1035, 2011, 1035, 7692, 1035, 2177, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 2326, 1035, 2203, 8400, 1035, 3343, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 2034, 1035, 3931, 1027, 2862, 1035, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
fazibear/colorize
lib/colorize/instance_methods.rb
Colorize.InstanceMethods.colors_from_hash
def colors_from_hash(match, hash) match[0] = mode(hash[:mode]) if mode(hash[:mode]) match[1] = color(hash[:color]) if color(hash[:color]) match[2] = background_color(hash[:background]) if background_color(hash[:background]) end
ruby
def colors_from_hash(match, hash) match[0] = mode(hash[:mode]) if mode(hash[:mode]) match[1] = color(hash[:color]) if color(hash[:color]) match[2] = background_color(hash[:background]) if background_color(hash[:background]) end
[ "def", "colors_from_hash", "(", "match", ",", "hash", ")", "match", "[", "0", "]", "=", "mode", "(", "hash", "[", ":mode", "]", ")", "if", "mode", "(", "hash", "[", ":mode", "]", ")", "match", "[", "1", "]", "=", "color", "(", "hash", "[", ":co...
Set colors from params hash
[ "Set", "colors", "from", "params", "hash" ]
526654c6d7dfc5483b70184d06b994eba8359514
https://github.com/fazibear/colorize/blob/526654c6d7dfc5483b70184d06b994eba8359514/lib/colorize/instance_methods.rb#L71-L75
train
Returns the colors from the hash
[ 30522, 13366, 6087, 1035, 2013, 1035, 23325, 1006, 2674, 1010, 23325, 1007, 2674, 1031, 1014, 1033, 1027, 5549, 1006, 23325, 1031, 1024, 5549, 1033, 1007, 2065, 5549, 1006, 23325, 1031, 1024, 5549, 1033, 1007, 2674, 1031, 1015, 1033, 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...
petergoldstein/dalli
lib/dalli/client.rb
Dalli.Client.stats
def stats(type=nil) type = nil if ![nil, :items,:slabs,:settings].include? type values = {} ring.servers.each do |server| values["#{server.name}"] = server.alive? ? server.request(:stats,type.to_s) : nil end values end
ruby
def stats(type=nil) type = nil if ![nil, :items,:slabs,:settings].include? type values = {} ring.servers.each do |server| values["#{server.name}"] = server.alive? ? server.request(:stats,type.to_s) : nil end values end
[ "def", "stats", "(", "type", "=", "nil", ")", "type", "=", "nil", "if", "!", "[", "nil", ",", ":items", ",", ":slabs", ",", ":settings", "]", ".", "include?", "type", "values", "=", "{", "}", "ring", ".", "servers", ".", "each", "do", "|", "serve...
Collect the stats for each server. You can optionally pass a type including :items, :slabs or :settings to get specific stats Returns a hash like { 'hostname:port' => { 'stat1' => 'value1', ... }, 'hostname2:port' => { ... } }
[ "Collect", "the", "stats", "for", "each", "server", ".", "You", "can", "optionally", "pass", "a", "type", "including", ":", "items", ":", "slabs", "or", ":", "settings", "to", "get", "specific", "stats", "Returns", "a", "hash", "like", "{", "hostname", "...
5755dbfd06e333a8239f976d4b10492b4555b726
https://github.com/petergoldstein/dalli/blob/5755dbfd06e333a8239f976d4b10492b4555b726/lib/dalli/client.rb#L220-L227
train
Get stats for all servers
[ 30522, 13366, 26319, 1006, 2828, 1027, 9152, 2140, 1007, 2828, 1027, 9152, 2140, 2065, 999, 1031, 9152, 2140, 1010, 1024, 5167, 1010, 1024, 28761, 1010, 1024, 10906, 1033, 1012, 2421, 1029, 2828, 5300, 1027, 1063, 1065, 3614, 1012, 14903, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
decidim/decidim
decidim-core/app/helpers/decidim/layout_helper.rb
Decidim.LayoutHelper.icon
def icon(name, options = {}) html_properties = {} html_properties["width"] = options[:width] html_properties["height"] = options[:height] html_properties["aria-label"] = options[:aria_label] html_properties["role"] = options[:role] html_properties["aria-hidden"] = options[:aria_hidd...
ruby
def icon(name, options = {}) html_properties = {} html_properties["width"] = options[:width] html_properties["height"] = options[:height] html_properties["aria-label"] = options[:aria_label] html_properties["role"] = options[:role] html_properties["aria-hidden"] = options[:aria_hidd...
[ "def", "icon", "(", "name", ",", "options", "=", "{", "}", ")", "html_properties", "=", "{", "}", "html_properties", "[", "\"width\"", "]", "=", "options", "[", ":width", "]", "html_properties", "[", "\"height\"", "]", "=", "options", "[", ":height", "]"...
Outputs an SVG-based icon. name - The String with the icon name. options - The Hash options used to customize the icon (default {}): :width - The Number of width in pixels (optional). :height - The Number of height in pixels (optional). :aria_label - The String to set as ar...
[ "Outputs", "an", "SVG", "-", "based", "icon", "." ]
6e2b14e559a63088669904e3c5c49a5180700cf7
https://github.com/decidim/decidim/blob/6e2b14e559a63088669904e3c5c49a5180700cf7/decidim-core/app/helpers/decidim/layout_helper.rb#L30-L44
train
Returns an SVG icon with the given name.
[ 30522, 13366, 12696, 1006, 2171, 1010, 7047, 1027, 1063, 1065, 1007, 16129, 1035, 5144, 1027, 1063, 1065, 16129, 1035, 5144, 1031, 1000, 9381, 1000, 1033, 1027, 7047, 1031, 1024, 9381, 1033, 16129, 1035, 5144, 1031, 1000, 4578, 1000, 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...
sinatra/sinatra
sinatra-contrib/lib/sinatra/link_header.rb
Sinatra.LinkHeader.stylesheet
def stylesheet(*urls) urls << {} unless urls.last.respond_to? :to_hash urls.last[:type] ||= mime_type(:css) link(:stylesheet, *urls) end
ruby
def stylesheet(*urls) urls << {} unless urls.last.respond_to? :to_hash urls.last[:type] ||= mime_type(:css) link(:stylesheet, *urls) end
[ "def", "stylesheet", "(", "*", "urls", ")", "urls", "<<", "{", "}", "unless", "urls", ".", "last", ".", "respond_to?", ":to_hash", "urls", ".", "last", "[", ":type", "]", "||=", "mime_type", "(", ":css", ")", "link", "(", ":stylesheet", ",", "urls", ...
Sets Link HTTP header and returns HTML tags for using stylesheets.
[ "Sets", "Link", "HTTP", "header", "and", "returns", "HTML", "tags", "for", "using", "stylesheets", "." ]
1aa64f9858edc3f93cc8d46e26f724c1ae103b1c
https://github.com/sinatra/sinatra/blob/1aa64f9858edc3f93cc8d46e26f724c1ae103b1c/sinatra-contrib/lib/sinatra/link_header.rb#L65-L69
train
Returns a link to the stylesheet with the given urls.
[ 30522, 13366, 6782, 21030, 2102, 1006, 1008, 24471, 4877, 1007, 24471, 4877, 1026, 1026, 1063, 1065, 4983, 24471, 4877, 1012, 2197, 1012, 6869, 1035, 2000, 1029, 1024, 2000, 1035, 23325, 24471, 4877, 1012, 2197, 1031, 1024, 2828, 1033, 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...
anycable/anycable
lib/anycable/cli.rb
AnyCable.CLI.parse_cli_options!
def parse_cli_options!(args) unknown_opts = [] parser = build_cli_parser begin parser.parse!(args) rescue OptionParser::InvalidOption => e unknown_opts << e.args[0] unless args.size.zero? unknown_opts << args.shift unless args.first.start_with?("-") ...
ruby
def parse_cli_options!(args) unknown_opts = [] parser = build_cli_parser begin parser.parse!(args) rescue OptionParser::InvalidOption => e unknown_opts << e.args[0] unless args.size.zero? unknown_opts << args.shift unless args.first.start_with?("-") ...
[ "def", "parse_cli_options!", "(", "args", ")", "unknown_opts", "=", "[", "]", "parser", "=", "build_cli_parser", "begin", "parser", ".", "parse!", "(", "args", ")", "rescue", "OptionParser", "::", "InvalidOption", "=>", "e", "unknown_opts", "<<", "e", ".", "...
rubocop:disable Metrics/MethodLength
[ "rubocop", ":", "disable", "Metrics", "/", "MethodLength" ]
d7515e8e034d42e86ebeb09786a92aad2a11b25f
https://github.com/anycable/anycable/blob/d7515e8e034d42e86ebeb09786a92aad2a11b25f/lib/anycable/cli.rb#L251-L267
train
Parse the command line options
[ 30522, 13366, 11968, 3366, 1035, 18856, 2072, 1035, 7047, 999, 1006, 12098, 5620, 1007, 4242, 1035, 23569, 2015, 1027, 1031, 1033, 11968, 8043, 1027, 3857, 1035, 18856, 2072, 1035, 11968, 8043, 4088, 11968, 8043, 1012, 11968, 3366, 999, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aws/aws-sdk-ruby
gems/aws-sdk-glacier/lib/aws-sdk-glacier/client.rb
Aws::Glacier.Client.get_job_output
def get_job_output(params = {}, options = {}, &block) req = build_request(:get_job_output, params) req.send_request(options, &block) end
ruby
def get_job_output(params = {}, options = {}, &block) req = build_request(:get_job_output, params) req.send_request(options, &block) end
[ "def", "get_job_output", "(", "params", "=", "{", "}", ",", "options", "=", "{", "}", ",", "&", "block", ")", "req", "=", "build_request", "(", ":get_job_output", ",", "params", ")", "req", ".", "send_request", "(", "options", ",", "block", ")", "end" ...
This operation downloads the output of the job you initiated using InitiateJob. Depending on the job type you specified when you initiated the job, the output will be either the content of an archive or a vault inventory. You can download all the job output or download a portion of the output by specifying a byte...
[ "This", "operation", "downloads", "the", "output", "of", "the", "job", "you", "initiated", "using", "InitiateJob", ".", "Depending", "on", "the", "job", "type", "you", "specified", "when", "you", "initiated", "the", "job", "the", "output", "will", "be", "eit...
e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d
https://github.com/aws/aws-sdk-ruby/blob/e28b8d320ddf7b6ee0161bdd9d00fb786d99b63d/gems/aws-sdk-glacier/lib/aws-sdk-glacier/client.rb#L1448-L1451
train
Get the output of a job
[ 30522, 13366, 2131, 1035, 3105, 1035, 6434, 1006, 11498, 5244, 1027, 1063, 1065, 1010, 7047, 1027, 1063, 1065, 1010, 1004, 3796, 1007, 2128, 4160, 1027, 3857, 1035, 5227, 1006, 1024, 2131, 1035, 3105, 1035, 6434, 1010, 11498, 5244, 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_compute/lib/2016-04-30-preview/generated/azure_mgmt_compute/virtual_machines.rb
Azure::Compute::Mgmt::V2016_04_30_preview.VirtualMachines.delete_async
def delete_async(resource_group_name, vm_name, custom_headers:nil) # Send request promise = begin_delete_async(resource_group_name, vm_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_re...
ruby
def delete_async(resource_group_name, vm_name, custom_headers:nil) # Send request promise = begin_delete_async(resource_group_name, vm_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_re...
[ "def", "delete_async", "(", "resource_group_name", ",", "vm_name", ",", "custom_headers", ":", "nil", ")", "# Send request", "promise", "=", "begin_delete_async", "(", "resource_group_name", ",", "vm_name", ",", "custom_headers", ":custom_headers", ")", "promise", "="...
@param resource_group_name [String] The name of the resource group. @param vm_name [String] The name of the virtual machine. @param custom_headers [Hash{String => String}] A hash of custom headers that will be added to the HTTP request. @return [Concurrent::Promise] promise which provides async access to http res...
[ "@param", "resource_group_name", "[", "String", "]", "The", "name", "of", "the", "resource", "group", ".", "@param", "vm_name", "[", "String", "]", "The", "name", "of", "the", "virtual", "machine", ".", "@param", "custom_headers", "[", "Hash", "{", "String",...
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_compute/lib/2016-04-30-preview/generated/azure_mgmt_compute/virtual_machines.rb#L239-L255
train
Deletes a virtual machine.
[ 30522, 13366, 3972, 12870, 1035, 2004, 6038, 2278, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 1058, 2213, 1035, 2171, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 1001, 4604, 5227, 4872, 1027, 4088, 1035, 3972, 12870, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Azure/azure-sdk-for-ruby
data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/versions.rb
Azure::CognitiveServices::LuisAuthoring::V2_0.Versions.import_with_http_info
def import_with_http_info(app_id, luis_app, version_id:nil, custom_headers:nil) import_async(app_id, luis_app, version_id:version_id, custom_headers:custom_headers).value! end
ruby
def import_with_http_info(app_id, luis_app, version_id:nil, custom_headers:nil) import_async(app_id, luis_app, version_id:version_id, custom_headers:custom_headers).value! end
[ "def", "import_with_http_info", "(", "app_id", ",", "luis_app", ",", "version_id", ":", "nil", ",", "custom_headers", ":", "nil", ")", "import_async", "(", "app_id", ",", "luis_app", ",", "version_id", ":version_id", ",", "custom_headers", ":custom_headers", ")", ...
Imports a new version into a LUIS application. @param app_id The application ID. @param luis_app [LuisApp] A LUIS application structure. @param version_id [String] The new versionId to import. If not specified, the versionId will be read from the imported object. @param custom_headers [Hash{String => String}] A h...
[ "Imports", "a", "new", "version", "into", "a", "LUIS", "application", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/data/azure_cognitiveservices_luisauthoring/lib/2.0/generated/azure_cognitiveservices_luisauthoring/versions.rb#L662-L664
train
Import a luis specification into a LUIS specification.
[ 30522, 13366, 12324, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 10439, 1035, 8909, 1010, 6446, 1035, 10439, 1010, 2544, 1035, 8909, 1024, 9152, 2140, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 12324, 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...
Azure/azure-sdk-for-ruby
management/azure_mgmt_datalake_analytics/lib/2016-11-01/generated/azure_mgmt_datalake_analytics/storage_accounts.rb
Azure::DataLakeAnalytics::Mgmt::V2016_11_01.StorageAccounts.add_with_http_info
def add_with_http_info(resource_group_name, account_name, storage_account_name, parameters, custom_headers:nil) add_async(resource_group_name, account_name, storage_account_name, parameters, custom_headers:custom_headers).value! end
ruby
def add_with_http_info(resource_group_name, account_name, storage_account_name, parameters, custom_headers:nil) add_async(resource_group_name, account_name, storage_account_name, parameters, custom_headers:custom_headers).value! end
[ "def", "add_with_http_info", "(", "resource_group_name", ",", "account_name", ",", "storage_account_name", ",", "parameters", ",", "custom_headers", ":", "nil", ")", "add_async", "(", "resource_group_name", ",", "account_name", ",", "storage_account_name", ",", "paramet...
Updates the specified Data Lake Analytics account to add an Azure Storage account. @param resource_group_name [String] The name of the Azure resource group. @param account_name [String] The name of the Data Lake Analytics account. @param storage_account_name [String] The name of the Azure Storage account to add ...
[ "Updates", "the", "specified", "Data", "Lake", "Analytics", "account", "to", "add", "an", "Azure", "Storage", "account", "." ]
78eedacf8f8cbd65c2d8a2af421405eaa4373d8e
https://github.com/Azure/azure-sdk-for-ruby/blob/78eedacf8f8cbd65c2d8a2af421405eaa4373d8e/management/azure_mgmt_datalake_analytics/lib/2016-11-01/generated/azure_mgmt_datalake_analytics/storage_accounts.rb#L200-L202
train
Adds a new chunk of data to the specified storage account.
[ 30522, 13366, 5587, 1035, 2007, 1035, 8299, 1035, 18558, 1006, 7692, 1035, 2177, 1035, 2171, 1010, 4070, 1035, 2171, 1010, 5527, 1035, 4070, 1035, 2171, 1010, 11709, 1010, 7661, 1035, 20346, 2015, 1024, 9152, 2140, 1007, 5587, 1035, 2004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
meew0/discordrb
lib/discordrb/commands/command_bot.rb
Discordrb::Commands.CommandBot.permission?
def permission?(user, level, server) determined_level = if user.webhook? || server.nil? 0 else user.roles.reduce(0) do |memo, role| [@permissions[:roles][role.id] || 0, memo].max ...
ruby
def permission?(user, level, server) determined_level = if user.webhook? || server.nil? 0 else user.roles.reduce(0) do |memo, role| [@permissions[:roles][role.id] || 0, memo].max ...
[ "def", "permission?", "(", "user", ",", "level", ",", "server", ")", "determined_level", "=", "if", "user", ".", "webhook?", "||", "server", ".", "nil?", "0", "else", "user", ".", "roles", ".", "reduce", "(", "0", ")", "do", "|", "memo", ",", "role",...
Check if a user has permission to do something @param user [User] The user to check @param level [Integer] The minimum permission level the user should have (inclusive) @param server [Server] The server on which to check @return [true, false] whether or not the user has the given permission
[ "Check", "if", "a", "user", "has", "permission", "to", "do", "something" ]
764298a1ff0be69a1853b510d736f21c2b91a2fe
https://github.com/meew0/discordrb/blob/764298a1ff0be69a1853b510d736f21c2b91a2fe/lib/discordrb/commands/command_bot.rb#L353-L363
train
Check if the user has permission to the user
[ 30522, 13366, 6656, 1029, 1006, 5310, 1010, 2504, 1010, 8241, 1007, 4340, 1035, 2504, 1027, 2065, 5310, 1012, 4773, 6806, 6559, 1029, 1064, 1064, 8241, 1012, 9152, 2140, 1029, 1014, 2842, 5310, 1012, 4395, 1012, 5547, 1006, 1014, 1007, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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...
plataformatec/responders
lib/responders/collection_responder.rb
Responders.CollectionResponder.navigation_location
def navigation_location return options[:location] if options[:location] klass = resources.last.class if klass.respond_to?(:model_name) resources[0...-1] << klass.model_name.route_key.to_sym else resources end end
ruby
def navigation_location return options[:location] if options[:location] klass = resources.last.class if klass.respond_to?(:model_name) resources[0...-1] << klass.model_name.route_key.to_sym else resources end end
[ "def", "navigation_location", "return", "options", "[", ":location", "]", "if", "options", "[", ":location", "]", "klass", "=", "resources", ".", "last", ".", "class", "if", "klass", ".", "respond_to?", "(", ":model_name", ")", "resources", "[", "0", "...", ...
Returns the collection location for redirecting after POST/PUT/DELETE. This method, converts the following resources array to the following: [:admin, @post] #=> [:admin, :posts] [@user, @post] #=> [@user, :posts] When these new arrays are given to redirect_to, it will generate the proper URL pointing to the...
[ "Returns", "the", "collection", "location", "for", "redirecting", "after", "POST", "/", "PUT", "/", "DELETE", ".", "This", "method", "converts", "the", "following", "resources", "array", "to", "the", "following", ":" ]
a1a2706091d4ffcbbe387407ddfc5671a59ad842
https://github.com/plataformatec/responders/blob/a1a2706091d4ffcbbe387407ddfc5671a59ad842/lib/responders/collection_responder.rb#L19-L28
train
Returns the location of the current page.
[ 30522, 13366, 9163, 1035, 3295, 2709, 7047, 1031, 1024, 3295, 1033, 2065, 7047, 1031, 1024, 3295, 1033, 1047, 27102, 1027, 4219, 1012, 2197, 1012, 2465, 2065, 1047, 27102, 1012, 6869, 1035, 2000, 1029, 1006, 1024, 2944, 1035, 2171, 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...