repository_name
stringlengths
7
58
func_path_in_repository
stringlengths
11
218
func_name
stringlengths
4
140
whole_func_string
stringlengths
153
5.32k
language
stringclasses
1 value
func_code_string
stringlengths
72
4k
func_code_tokens
listlengths
20
832
func_documentation_string
stringlengths
61
2k
func_documentation_tokens
listlengths
1
647
split_name
stringclasses
1 value
func_code_url
stringlengths
102
339
UrielCh/ovh-java-sdk
ovh-java-sdk-domain/src/main/java/net/minidev/ovh/api/ApiOvhDomain.java
ApiOvhDomain.data_smd_GET
public ArrayList<Long> data_smd_GET(String protectedLabels_label) throws IOException { """ List all your SMD files REST: GET /domain/data/smd @param protectedLabels_label [required] Filter the value of protectedLabels.label property (=) """ String qPath = "/domain/data/smd"; StringBuilder sb = path(qPa...
java
public ArrayList<Long> data_smd_GET(String protectedLabels_label) throws IOException { String qPath = "/domain/data/smd"; StringBuilder sb = path(qPath); query(sb, "protectedLabels.label", protectedLabels_label); String resp = exec(qPath, "GET", sb.toString(), null); return convertTo(resp, t1); }
[ "public", "ArrayList", "<", "Long", ">", "data_smd_GET", "(", "String", "protectedLabels_label", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/domain/data/smd\"", ";", "StringBuilder", "sb", "=", "path", "(", "qPath", ")", ";", "query", "(", "...
List all your SMD files REST: GET /domain/data/smd @param protectedLabels_label [required] Filter the value of protectedLabels.label property (=)
[ "List", "all", "your", "SMD", "files" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-domain/src/main/java/net/minidev/ovh/api/ApiOvhDomain.java#L112-L118
cdapio/tigon
tigon-yarn/src/main/java/co/cask/tigon/conf/Configuration.java
Configuration.getEnum
public <T extends Enum<T>> T getEnum(String name, Class<T> declaringClass) { """ Return value matching this enumerated type. @param name Property name @throws NullPointerException if the configuration property does not exist @throws IllegalArgumentException If mapping is illegal for the type provided """ ...
java
public <T extends Enum<T>> T getEnum(String name, Class<T> declaringClass) { final String val = get(name); Preconditions.checkNotNull(val); return Enum.valueOf(declaringClass, val); }
[ "public", "<", "T", "extends", "Enum", "<", "T", ">", ">", "T", "getEnum", "(", "String", "name", ",", "Class", "<", "T", ">", "declaringClass", ")", "{", "final", "String", "val", "=", "get", "(", "name", ")", ";", "Preconditions", ".", "checkNotNul...
Return value matching this enumerated type. @param name Property name @throws NullPointerException if the configuration property does not exist @throws IllegalArgumentException If mapping is illegal for the type provided
[ "Return", "value", "matching", "this", "enumerated", "type", "." ]
train
https://github.com/cdapio/tigon/blob/5be6dffd7c79519d1211bb08f75be7dcfbbad392/tigon-yarn/src/main/java/co/cask/tigon/conf/Configuration.java#L910-L914
pressgang-ccms/PressGangCCMSContentSpec
src/main/java/org/jboss/pressgang/ccms/contentspec/utils/FixedURLGenerator.java
FixedURLGenerator.setFixedURL
protected static void setFixedURL(final SpecNode specNode, final String fixedURL, final Set<String> existingFixedUrls) { """ Sets the fixed URL property on the node. @param specNode The spec node to update. @param fixedURL The fixed url to apply to the node. @param existingFixedUrls A list o...
java
protected static void setFixedURL(final SpecNode specNode, final String fixedURL, final Set<String> existingFixedUrls) { specNode.setFixedUrl(fixedURL); // Add the fixed url to the processed file names existingFixedUrls.add(fixedURL); }
[ "protected", "static", "void", "setFixedURL", "(", "final", "SpecNode", "specNode", ",", "final", "String", "fixedURL", ",", "final", "Set", "<", "String", ">", "existingFixedUrls", ")", "{", "specNode", ".", "setFixedUrl", "(", "fixedURL", ")", ";", "// Add t...
Sets the fixed URL property on the node. @param specNode The spec node to update. @param fixedURL The fixed url to apply to the node. @param existingFixedUrls A list of file names that already exist in the spec.
[ "Sets", "the", "fixed", "URL", "property", "on", "the", "node", "." ]
train
https://github.com/pressgang-ccms/PressGangCCMSContentSpec/blob/2bc02e2971e4522b47a130fb7ae5a0f5ad377df1/src/main/java/org/jboss/pressgang/ccms/contentspec/utils/FixedURLGenerator.java#L251-L256
akarnokd/akarnokd-xml
src/main/java/hu/akarnokd/xml/XNElement.java
XNElement.longValue
public long longValue(String name, String namespace) { """ Returns a long value of the supplied child or throws an exception if missing. @param name the child element name @param namespace the element namespace @return the value """ String s = childValue(name, namespace); if (s != null) { ...
java
public long longValue(String name, String namespace) { String s = childValue(name, namespace); if (s != null) { return Long.parseLong(s); } throw new IllegalArgumentException(this + ": content: " + name); }
[ "public", "long", "longValue", "(", "String", "name", ",", "String", "namespace", ")", "{", "String", "s", "=", "childValue", "(", "name", ",", "namespace", ")", ";", "if", "(", "s", "!=", "null", ")", "{", "return", "Long", ".", "parseLong", "(", "s...
Returns a long value of the supplied child or throws an exception if missing. @param name the child element name @param namespace the element namespace @return the value
[ "Returns", "a", "long", "value", "of", "the", "supplied", "child", "or", "throws", "an", "exception", "if", "missing", "." ]
train
https://github.com/akarnokd/akarnokd-xml/blob/57466a5a9cb455a13d7121557c165287b31ee870/src/main/java/hu/akarnokd/xml/XNElement.java#L1011-L1017
deeplearning4j/deeplearning4j
deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/SparkComputationGraph.java
SparkComputationGraph.doEvaluation
@SuppressWarnings("unchecked") public <T extends IEvaluation> T doEvaluation(JavaRDD<DataSet> data, T emptyEvaluation, int evalBatchSize) { """ Perform distributed evaluation of any type of {@link IEvaluation}. For example, {@link Evaluation}, {@link RegressionEvaluation}, {@link ROC}, {@link ROCMultiClass} e...
java
@SuppressWarnings("unchecked") public <T extends IEvaluation> T doEvaluation(JavaRDD<DataSet> data, T emptyEvaluation, int evalBatchSize) { IEvaluation[] arr = new IEvaluation[] {emptyEvaluation}; return (T) doEvaluation(data, evalBatchSize, arr)[0]; }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "public", "<", "T", "extends", "IEvaluation", ">", "T", "doEvaluation", "(", "JavaRDD", "<", "DataSet", ">", "data", ",", "T", "emptyEvaluation", ",", "int", "evalBatchSize", ")", "{", "IEvaluation", "[", "...
Perform distributed evaluation of any type of {@link IEvaluation}. For example, {@link Evaluation}, {@link RegressionEvaluation}, {@link ROC}, {@link ROCMultiClass} etc. @param data Data to evaluate on @param emptyEvaluation Empty evaluation instance. This is the starting point (serialized/duplicated, then ...
[ "Perform", "distributed", "evaluation", "of", "any", "type", "of", "{", "@link", "IEvaluation", "}", ".", "For", "example", "{", "@link", "Evaluation", "}", "{", "@link", "RegressionEvaluation", "}", "{", "@link", "ROC", "}", "{", "@link", "ROCMultiClass", "...
train
https://github.com/deeplearning4j/deeplearning4j/blob/effce52f2afd7eeb53c5bcca699fcd90bd06822f/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/SparkComputationGraph.java#L793-L797
jbossws/jbossws-cxf
modules/server/src/main/java/org/jboss/wsf/stack/cxf/configuration/BusHolder.java
BusHolder.createServerConfigurer
public Configurer createServerConfigurer(BindingCustomization customization, WSDLFilePublisher wsdlPublisher, ArchiveDeployment dep) { """ A convenient method for getting a jbossws cxf server configurer @param customization The binding customization to set in the configurer, if any @param wsdlPublisher T...
java
public Configurer createServerConfigurer(BindingCustomization customization, WSDLFilePublisher wsdlPublisher, ArchiveDeployment dep) { ServerBeanCustomizer customizer = new ServerBeanCustomizer(); customizer.setBindingCustomization(customization); customizer.setWsdlPublisher(wsdlPublisher); c...
[ "public", "Configurer", "createServerConfigurer", "(", "BindingCustomization", "customization", ",", "WSDLFilePublisher", "wsdlPublisher", ",", "ArchiveDeployment", "dep", ")", "{", "ServerBeanCustomizer", "customizer", "=", "new", "ServerBeanCustomizer", "(", ")", ";", "...
A convenient method for getting a jbossws cxf server configurer @param customization The binding customization to set in the configurer, if any @param wsdlPublisher The wsdl file publisher to set in the configurer, if any @param dep The deployment @return The new jbossws cxf configurer
[ "A", "convenient", "method", "for", "getting", "a", "jbossws", "cxf", "server", "configurer" ]
train
https://github.com/jbossws/jbossws-cxf/blob/e1d5df3664cbc2482ebc83cafd355a4d60d12150/modules/server/src/main/java/org/jboss/wsf/stack/cxf/configuration/BusHolder.java#L342-L349
pac4j/pac4j
pac4j-saml/src/main/java/org/pac4j/saml/util/SAML2Utils.java
SAML2Utils.normalizePortNumbersInUri
private static URI normalizePortNumbersInUri(final URI uri) throws URISyntaxException { """ Normalizes a URI. If it contains the default port for the used scheme, the method replaces the port with "default". @param uri The URI to normalize. @return A normalized URI. @throws URISyntaxException If a URI c...
java
private static URI normalizePortNumbersInUri(final URI uri) throws URISyntaxException { int port = uri.getPort(); final String scheme = uri.getScheme(); if (SCHEME_HTTP.equals(scheme) && port == DEFAULT_HTTP_PORT) { port = -1; } if (SCHEME_HTTPS.equals(scheme) && por...
[ "private", "static", "URI", "normalizePortNumbersInUri", "(", "final", "URI", "uri", ")", "throws", "URISyntaxException", "{", "int", "port", "=", "uri", ".", "getPort", "(", ")", ";", "final", "String", "scheme", "=", "uri", ".", "getScheme", "(", ")", ";...
Normalizes a URI. If it contains the default port for the used scheme, the method replaces the port with "default". @param uri The URI to normalize. @return A normalized URI. @throws URISyntaxException If a URI cannot be created because of wrong syntax.
[ "Normalizes", "a", "URI", ".", "If", "it", "contains", "the", "default", "port", "for", "the", "used", "scheme", "the", "method", "replaces", "the", "port", "with", "default", "." ]
train
https://github.com/pac4j/pac4j/blob/d9cd029f8783792b31dd48bf1e32f80628f2c4a3/pac4j-saml/src/main/java/org/pac4j/saml/util/SAML2Utils.java#L79-L92
aws/aws-sdk-java
aws-java-sdk-s3/src/main/java/com/amazonaws/services/s3/AmazonS3Client.java
AmazonS3Client.createRequest
protected <X extends AmazonWebServiceRequest> Request<X> createRequest(String bucketName, String key, X originalRequest, HttpMethodName httpMethod) { """ Creates and initializes a new request object for the specified S3 resource. This method is responsible for determining the right way to address resources. For ...
java
protected <X extends AmazonWebServiceRequest> Request<X> createRequest(String bucketName, String key, X originalRequest, HttpMethodName httpMethod) { return createRequest(bucketName, key, originalRequest, httpMethod, endpoint); }
[ "protected", "<", "X", "extends", "AmazonWebServiceRequest", ">", "Request", "<", "X", ">", "createRequest", "(", "String", "bucketName", ",", "String", "key", ",", "X", "originalRequest", ",", "HttpMethodName", "httpMethod", ")", "{", "return", "createRequest", ...
Creates and initializes a new request object for the specified S3 resource. This method is responsible for determining the right way to address resources. For example, bucket names that are not DNS addressable cannot be addressed in V2, virtual host, style, and instead must use V1, path style. The returned request obje...
[ "Creates", "and", "initializes", "a", "new", "request", "object", "for", "the", "specified", "S3", "resource", ".", "This", "method", "is", "responsible", "for", "determining", "the", "right", "way", "to", "address", "resources", ".", "For", "example", "bucket...
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-s3/src/main/java/com/amazonaws/services/s3/AmazonS3Client.java#L4629-L4631
Azure/azure-sdk-for-java
cognitiveservices/data-plane/language/textanalytics/src/main/java/com/microsoft/azure/cognitiveservices/language/textanalytics/TextAnalyticsManager.java
TextAnalyticsManager.authenticate
public static TextAnalyticsAPI authenticate(AzureRegions region, ServiceClientCredentials credentials) { """ Initializes an instance of Text Analytics API client. @param region Supported Azure regions for Cognitive Services endpoints. @param credentials the management credentials for Azure @return the Text An...
java
public static TextAnalyticsAPI authenticate(AzureRegions region, ServiceClientCredentials credentials) { return authenticate("https://{AzureRegion}.api.cognitive.microsoft.com/text/analytics/", credentials) .withAzureRegion(region); }
[ "public", "static", "TextAnalyticsAPI", "authenticate", "(", "AzureRegions", "region", ",", "ServiceClientCredentials", "credentials", ")", "{", "return", "authenticate", "(", "\"https://{AzureRegion}.api.cognitive.microsoft.com/text/analytics/\"", ",", "credentials", ")", ".",...
Initializes an instance of Text Analytics API client. @param region Supported Azure regions for Cognitive Services endpoints. @param credentials the management credentials for Azure @return the Text Analytics API client
[ "Initializes", "an", "instance", "of", "Text", "Analytics", "API", "client", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/cognitiveservices/data-plane/language/textanalytics/src/main/java/com/microsoft/azure/cognitiveservices/language/textanalytics/TextAnalyticsManager.java#L72-L75
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/db/QueryRecord.java
QueryRecord.addSelectParams
public String addSelectParams(String seekSign, int areaDesc, boolean bAddOnlyMods, boolean bIncludeFileName, boolean bUseCurrentValues, Vector<BaseField> vParamList, boolean bForceUniqueKey, boolean bIncludeTempFields) { """ Add to this SQL Key Filter. @param seekSign The seek sign. @param bAddOnlyMods Add only ...
java
public String addSelectParams(String seekSign, int areaDesc, boolean bAddOnlyMods, boolean bIncludeFileName, boolean bUseCurrentValues, Vector<BaseField> vParamList, boolean bForceUniqueKey, boolean bIncludeTempFields) { String sFilter = super.addSelectParams(seekSign, areaDesc, bAddOnlyMods, bIncludeFileNa...
[ "public", "String", "addSelectParams", "(", "String", "seekSign", ",", "int", "areaDesc", ",", "boolean", "bAddOnlyMods", ",", "boolean", "bIncludeFileName", ",", "boolean", "bUseCurrentValues", ",", "Vector", "<", "BaseField", ">", "vParamList", ",", "boolean", "...
Add to this SQL Key Filter. @param seekSign The seek sign. @param bAddOnlyMods Add only the keys which have modified? @param bIncludeFileName Include the file name in the string? @param bUseCurrentValues Use current values? @param vParamList The parameter list. @param bForceUniqueKey If params must be unique, if they a...
[ "Add", "to", "this", "SQL", "Key", "Filter", "." ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/db/QueryRecord.java#L191-L203
b3dgs/lionengine
lionengine-game/src/main/java/com/b3dgs/lionengine/game/feature/tile/map/transition/TransitionsConfig.java
TransitionsConfig.exports
public static void exports(Media media, Collection<Media> levels, Media sheetsMedia, Media groupsMedia) { """ Export all transitions to media. @param media The export media output (must not be <code>null</code>). @param levels The level rips used (must not be <code>null</code>). @param sheetsMedia The sheets ...
java
public static void exports(Media media, Collection<Media> levels, Media sheetsMedia, Media groupsMedia) { Check.notNull(media); Check.notNull(levels); Check.notNull(sheetsMedia); Check.notNull(groupsMedia); final TransitionsExtractor extractor = new TransitionsExtract...
[ "public", "static", "void", "exports", "(", "Media", "media", ",", "Collection", "<", "Media", ">", "levels", ",", "Media", "sheetsMedia", ",", "Media", "groupsMedia", ")", "{", "Check", ".", "notNull", "(", "media", ")", ";", "Check", ".", "notNull", "(...
Export all transitions to media. @param media The export media output (must not be <code>null</code>). @param levels The level rips used (must not be <code>null</code>). @param sheetsMedia The sheets media (must not be <code>null</code>). @param groupsMedia The groups media (must not be <code>null</code>). @throws Lio...
[ "Export", "all", "transitions", "to", "media", "." ]
train
https://github.com/b3dgs/lionengine/blob/cac3d5578532cf11724a737b9f09e71bf9995ab2/lionengine-game/src/main/java/com/b3dgs/lionengine/game/feature/tile/map/transition/TransitionsConfig.java#L96-L108
stickfigure/batchfb
src/main/java/com/googlecode/batchfb/util/RequestBuilder.java
RequestBuilder.addParam
public void addParam(String name, InputStream stream, String contentType, String filename) { """ Adds a binary attachment. Request method must be POST; causes the type to be multipart/form-data """ if (this.method != HttpMethod.POST) throw new IllegalStateException("May only add binary attachment to POS...
java
public void addParam(String name, InputStream stream, String contentType, String filename) { if (this.method != HttpMethod.POST) throw new IllegalStateException("May only add binary attachment to POST, not to " + this.method); this.params.put(name, new BinaryAttachment(stream, contentType, filename)); ...
[ "public", "void", "addParam", "(", "String", "name", ",", "InputStream", "stream", ",", "String", "contentType", ",", "String", "filename", ")", "{", "if", "(", "this", ".", "method", "!=", "HttpMethod", ".", "POST", ")", "throw", "new", "IllegalStateExcepti...
Adds a binary attachment. Request method must be POST; causes the type to be multipart/form-data
[ "Adds", "a", "binary", "attachment", ".", "Request", "method", "must", "be", "POST", ";", "causes", "the", "type", "to", "be", "multipart", "/", "form", "-", "data" ]
train
https://github.com/stickfigure/batchfb/blob/ceeda78aa6d8397eec032ab1d8997adb7378e9e2/src/main/java/com/googlecode/batchfb/util/RequestBuilder.java#L110-L116
looly/hutool
hutool-core/src/main/java/cn/hutool/core/io/FileUtil.java
FileUtil.createRandomAccessFile
public static RandomAccessFile createRandomAccessFile(File file, FileMode mode) { """ 创建{@link RandomAccessFile} @param file 文件 @param mode 模式,见{@link FileMode} @return {@link RandomAccessFile} @since 4.5.2 """ try { return new RandomAccessFile(file, mode.name()); } catch (FileNotFoundException...
java
public static RandomAccessFile createRandomAccessFile(File file, FileMode mode) { try { return new RandomAccessFile(file, mode.name()); } catch (FileNotFoundException e) { throw new IORuntimeException(e); } }
[ "public", "static", "RandomAccessFile", "createRandomAccessFile", "(", "File", "file", ",", "FileMode", "mode", ")", "{", "try", "{", "return", "new", "RandomAccessFile", "(", "file", ",", "mode", ".", "name", "(", ")", ")", ";", "}", "catch", "(", "FileNo...
创建{@link RandomAccessFile} @param file 文件 @param mode 模式,见{@link FileMode} @return {@link RandomAccessFile} @since 4.5.2
[ "创建", "{", "@link", "RandomAccessFile", "}" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/io/FileUtil.java#L3457-L3463
actframework/actframework
src/main/java/act/ws/WebSocketConnectionRegistry.java
WebSocketConnectionRegistry.signIn
public void signIn(String key, Collection<WebSocketConnection> connections) { """ Sign in a group of connections to the registry by key @param key the key @param connections a collection of websocket connections """ if (connections.isEmpty()) { return; } Map<WebSocketC...
java
public void signIn(String key, Collection<WebSocketConnection> connections) { if (connections.isEmpty()) { return; } Map<WebSocketConnection, WebSocketConnection> newMap = new HashMap<>(); for (WebSocketConnection conn : connections) { newMap.put(conn, conn); ...
[ "public", "void", "signIn", "(", "String", "key", ",", "Collection", "<", "WebSocketConnection", ">", "connections", ")", "{", "if", "(", "connections", ".", "isEmpty", "(", ")", ")", "{", "return", ";", "}", "Map", "<", "WebSocketConnection", ",", "WebSoc...
Sign in a group of connections to the registry by key @param key the key @param connections a collection of websocket connections
[ "Sign", "in", "a", "group", "of", "connections", "to", "the", "registry", "by", "key" ]
train
https://github.com/actframework/actframework/blob/55a8f8b45e71159a79ec6e157c02f71700f8cd54/src/main/java/act/ws/WebSocketConnectionRegistry.java#L156-L166
aws/aws-sdk-java
aws-java-sdk-s3/src/main/java/com/amazonaws/services/s3/internal/crypto/ContentCryptoMaterial.java
ContentCryptoMaterial.toObjectMetadata
ObjectMetadata toObjectMetadata(ObjectMetadata metadata, CryptoMode mode) { """ Returns the given metadata updated with this content crypto material. """ return mode == CryptoMode.EncryptionOnly && !usesKMSKey() ? toObjectMetadataEO(metadata) : toObjectMetadata(metadata); ...
java
ObjectMetadata toObjectMetadata(ObjectMetadata metadata, CryptoMode mode) { return mode == CryptoMode.EncryptionOnly && !usesKMSKey() ? toObjectMetadataEO(metadata) : toObjectMetadata(metadata); }
[ "ObjectMetadata", "toObjectMetadata", "(", "ObjectMetadata", "metadata", ",", "CryptoMode", "mode", ")", "{", "return", "mode", "==", "CryptoMode", ".", "EncryptionOnly", "&&", "!", "usesKMSKey", "(", ")", "?", "toObjectMetadataEO", "(", "metadata", ")", ":", "t...
Returns the given metadata updated with this content crypto material.
[ "Returns", "the", "given", "metadata", "updated", "with", "this", "content", "crypto", "material", "." ]
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-s3/src/main/java/com/amazonaws/services/s3/internal/crypto/ContentCryptoMaterial.java#L117-L121
UrielCh/ovh-java-sdk
ovh-java-sdk-me/src/main/java/net/minidev/ovh/api/ApiOvhMe.java
ApiOvhMe.ipOrganisation_organisationId_PUT
public void ipOrganisation_organisationId_PUT(String organisationId, OvhIpv4Org body) throws IOException { """ Alter this object properties REST: PUT /me/ipOrganisation/{organisationId} @param body [required] New object properties @param organisationId [required] """ String qPath = "/me/ipOrganisation/{...
java
public void ipOrganisation_organisationId_PUT(String organisationId, OvhIpv4Org body) throws IOException { String qPath = "/me/ipOrganisation/{organisationId}"; StringBuilder sb = path(qPath, organisationId); exec(qPath, "PUT", sb.toString(), body); }
[ "public", "void", "ipOrganisation_organisationId_PUT", "(", "String", "organisationId", ",", "OvhIpv4Org", "body", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/me/ipOrganisation/{organisationId}\"", ";", "StringBuilder", "sb", "=", "path", "(", "qPath"...
Alter this object properties REST: PUT /me/ipOrganisation/{organisationId} @param body [required] New object properties @param organisationId [required]
[ "Alter", "this", "object", "properties" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-me/src/main/java/net/minidev/ovh/api/ApiOvhMe.java#L2210-L2214
Azure/azure-sdk-for-java
compute/resource-manager/v2017_03_30/src/main/java/com/microsoft/azure/management/compute/v2017_03_30/implementation/SnapshotsInner.java
SnapshotsInner.beginRevokeAccessAsync
public Observable<OperationStatusResponseInner> beginRevokeAccessAsync(String resourceGroupName, String snapshotName) { """ Revokes access to a snapshot. @param resourceGroupName The name of the resource group. @param snapshotName The name of the snapshot that is being created. The name can't be changed after ...
java
public Observable<OperationStatusResponseInner> beginRevokeAccessAsync(String resourceGroupName, String snapshotName) { return beginRevokeAccessWithServiceResponseAsync(resourceGroupName, snapshotName).map(new Func1<ServiceResponse<OperationStatusResponseInner>, OperationStatusResponseInner>() { @Ov...
[ "public", "Observable", "<", "OperationStatusResponseInner", ">", "beginRevokeAccessAsync", "(", "String", "resourceGroupName", ",", "String", "snapshotName", ")", "{", "return", "beginRevokeAccessWithServiceResponseAsync", "(", "resourceGroupName", ",", "snapshotName", ")", ...
Revokes access to a snapshot. @param resourceGroupName The name of the resource group. @param snapshotName The name of the snapshot that is being created. The name can't be changed after the snapshot is created. Supported characters for the name are a-z, A-Z, 0-9 and _. The max name length is 80 characters. @throws Il...
[ "Revokes", "access", "to", "a", "snapshot", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/compute/resource-manager/v2017_03_30/src/main/java/com/microsoft/azure/management/compute/v2017_03_30/implementation/SnapshotsInner.java#L1218-L1225
deeplearning4j/deeplearning4j
nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/org/nd4j/autodiff/samediff/SDVariable.java
SDVariable.neq
public SDVariable neq(String name, SDVariable other) { """ Not equal to operation: elementwise {@code this != y}<br> If x and y arrays have equal shape, the output shape is the same as the inputs.<br> Supports broadcasting: if x and y have different shapes and are broadcastable, the output shape is broadcast.<br...
java
public SDVariable neq(String name, SDVariable other){ return sameDiff.neq(name, this, other); }
[ "public", "SDVariable", "neq", "(", "String", "name", ",", "SDVariable", "other", ")", "{", "return", "sameDiff", ".", "neq", "(", "name", ",", "this", ",", "other", ")", ";", "}" ]
Not equal to operation: elementwise {@code this != y}<br> If x and y arrays have equal shape, the output shape is the same as the inputs.<br> Supports broadcasting: if x and y have different shapes and are broadcastable, the output shape is broadcast.<br> Returns an array with values 1 where condition is satisfied, or ...
[ "Not", "equal", "to", "operation", ":", "elementwise", "{", "@code", "this", "!", "=", "y", "}", "<br", ">", "If", "x", "and", "y", "arrays", "have", "equal", "shape", "the", "output", "shape", "is", "the", "same", "as", "the", "inputs", ".", "<br", ...
train
https://github.com/deeplearning4j/deeplearning4j/blob/effce52f2afd7eeb53c5bcca699fcd90bd06822f/nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/org/nd4j/autodiff/samediff/SDVariable.java#L609-L611
TheHortonMachine/hortonmachine
gears/src/main/java/org/hortonmachine/gears/utils/coverage/CoverageUtilities.java
CoverageUtilities.doProfile
public static List<ProfilePoint> doProfile( RandomIter mapIter, GridGeometry2D gridGeometry, Coordinate... coordinates ) throws TransformException { """ Calculates the profile of a raster map between given {@link Coordinate coordinates}. <p>Note that novalues and points outside of the given raster r...
java
public static List<ProfilePoint> doProfile( RandomIter mapIter, GridGeometry2D gridGeometry, Coordinate... coordinates ) throws TransformException { List<ProfilePoint> profilePointsList = new ArrayList<ProfilePoint>(); GridEnvelope2D gridRange = gridGeometry.getGridRange2D(); int ro...
[ "public", "static", "List", "<", "ProfilePoint", ">", "doProfile", "(", "RandomIter", "mapIter", ",", "GridGeometry2D", "gridGeometry", ",", "Coordinate", "...", "coordinates", ")", "throws", "TransformException", "{", "List", "<", "ProfilePoint", ">", "profilePoint...
Calculates the profile of a raster map between given {@link Coordinate coordinates}. <p>Note that novalues and points outside of the given raster region are added to the list with a {@link HMConstants#doubleNovalue novalue} elevation. @param mapIter the {@link RandomIter map iterator}. @param gridGeometry the gridgeo...
[ "Calculates", "the", "profile", "of", "a", "raster", "map", "between", "given", "{", "@link", "Coordinate", "coordinates", "}", "." ]
train
https://github.com/TheHortonMachine/hortonmachine/blob/d2b436bbdf951dc1fda56096a42dbc0eae4d35a5/gears/src/main/java/org/hortonmachine/gears/utils/coverage/CoverageUtilities.java#L1194-L1227
litsec/swedish-eid-shibboleth-base
shibboleth-base/shibboleth-extensions/src/main/java/se/litsec/shibboleth/idp/authn/controller/AbstractExternalAuthenticationController.java
AbstractExternalAuthenticationController.getRelayState
protected String getRelayState(ProfileRequestContext<?, ?> context) { """ Utility method that may be used to obtain the Relay State for the request. @param context the profile context @return the relay state @see #getRelayState(HttpServletRequest) """ SAMLBindingContext samlBinding = this.samlBinding...
java
protected String getRelayState(ProfileRequestContext<?, ?> context) { SAMLBindingContext samlBinding = this.samlBindingContextLookupStrategy.apply(context); return samlBinding != null ? samlBinding.getRelayState() : null; }
[ "protected", "String", "getRelayState", "(", "ProfileRequestContext", "<", "?", ",", "?", ">", "context", ")", "{", "SAMLBindingContext", "samlBinding", "=", "this", ".", "samlBindingContextLookupStrategy", ".", "apply", "(", "context", ")", ";", "return", "samlBi...
Utility method that may be used to obtain the Relay State for the request. @param context the profile context @return the relay state @see #getRelayState(HttpServletRequest)
[ "Utility", "method", "that", "may", "be", "used", "to", "obtain", "the", "Relay", "State", "for", "the", "request", "." ]
train
https://github.com/litsec/swedish-eid-shibboleth-base/blob/aaaa467ff61f07d7dfa31627fb36851a37da6804/shibboleth-base/shibboleth-extensions/src/main/java/se/litsec/shibboleth/idp/authn/controller/AbstractExternalAuthenticationController.java#L643-L646
OpenLiberty/open-liberty
dev/com.ibm.ws.ejbcontainer.core/src/com/ibm/ejs/container/EJSContainer.java
EJSContainer.setCustomFinderAccessIntentThreadState
public void setCustomFinderAccessIntentThreadState(boolean cfwithupdateaccess, boolean readonly, String methodname) { """ d112604.5 Method called after first set of 25 CMP11 entities returned during a ...
java
public void setCustomFinderAccessIntentThreadState(boolean cfwithupdateaccess, boolean readonly, String methodname) { final boolean isTraceOn = TraceComponent.isAnyTracingEnabled(); // d532639.2 ...
[ "public", "void", "setCustomFinderAccessIntentThreadState", "(", "boolean", "cfwithupdateaccess", ",", "boolean", "readonly", ",", "String", "methodname", ")", "{", "final", "boolean", "isTraceOn", "=", "TraceComponent", ".", "isAnyTracingEnabled", "(", ")", ";", "// ...
d112604.5 Method called after first set of 25 CMP11 entities returned during a lazy enumeration custom finder execution. Called for each set of instances to be hydrated via the RemoteEnumerator code path.
[ "d112604", ".", "5" ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.ejbcontainer.core/src/com/ibm/ejs/container/EJSContainer.java#L1047-L1066
wildfly/wildfly-build-tools
provisioning/src/main/java/org/wildfly/build/util/ZipFileSubsystemInputStreamSources.java
ZipFileSubsystemInputStreamSources.addAllSubsystemFileSourcesFromModule
public void addAllSubsystemFileSourcesFromModule(FeaturePack.Module module, ArtifactFileResolver artifactFileResolver, boolean transitive) throws IOException { """ Adds all file sources in the specified module's artifacts. @param module @param artifactFileResolver @param transitive @throws IOException """ ...
java
public void addAllSubsystemFileSourcesFromModule(FeaturePack.Module module, ArtifactFileResolver artifactFileResolver, boolean transitive) throws IOException { // the subsystem templates are included in module artifacts files for (ModuleParseResult.ArtifactName artifactName : module.getModuleParseResult...
[ "public", "void", "addAllSubsystemFileSourcesFromModule", "(", "FeaturePack", ".", "Module", "module", ",", "ArtifactFileResolver", "artifactFileResolver", ",", "boolean", "transitive", ")", "throws", "IOException", "{", "// the subsystem templates are included in module artifact...
Adds all file sources in the specified module's artifacts. @param module @param artifactFileResolver @param transitive @throws IOException
[ "Adds", "all", "file", "sources", "in", "the", "specified", "module", "s", "artifacts", "." ]
train
https://github.com/wildfly/wildfly-build-tools/blob/520a5f2e58e6a24097d63fd65c51a8fc29847a61/provisioning/src/main/java/org/wildfly/build/util/ZipFileSubsystemInputStreamSources.java#L110-L128
google/closure-compiler
src/com/google/javascript/jscomp/GoogleCodingConvention.java
GoogleCodingConvention.isExported
@Override public boolean isExported(String name, boolean local) { """ {@inheritDoc} <p>In Google code, any global name starting with an underscore is considered exported. """ return super.isExported(name, local) || (!local && name.startsWith("_")); }
java
@Override public boolean isExported(String name, boolean local) { return super.isExported(name, local) || (!local && name.startsWith("_")); }
[ "@", "Override", "public", "boolean", "isExported", "(", "String", "name", ",", "boolean", "local", ")", "{", "return", "super", ".", "isExported", "(", "name", ",", "local", ")", "||", "(", "!", "local", "&&", "name", ".", "startsWith", "(", "\"_\"", ...
{@inheritDoc} <p>In Google code, any global name starting with an underscore is considered exported.
[ "{", "@inheritDoc", "}" ]
train
https://github.com/google/closure-compiler/blob/d81e36740f6a9e8ac31a825ee8758182e1dc5aae/src/com/google/javascript/jscomp/GoogleCodingConvention.java#L147-L150
aws/aws-sdk-java
aws-java-sdk-codestar/src/main/java/com/amazonaws/services/codestar/model/Toolchain.java
Toolchain.withStackParameters
public Toolchain withStackParameters(java.util.Map<String, String> stackParameters) { """ <p> The list of parameter overrides to be passed into the toolchain template during stack provisioning, if any. </p> @param stackParameters The list of parameter overrides to be passed into the toolchain template during...
java
public Toolchain withStackParameters(java.util.Map<String, String> stackParameters) { setStackParameters(stackParameters); return this; }
[ "public", "Toolchain", "withStackParameters", "(", "java", ".", "util", ".", "Map", "<", "String", ",", "String", ">", "stackParameters", ")", "{", "setStackParameters", "(", "stackParameters", ")", ";", "return", "this", ";", "}" ]
<p> The list of parameter overrides to be passed into the toolchain template during stack provisioning, if any. </p> @param stackParameters The list of parameter overrides to be passed into the toolchain template during stack provisioning, if any. @return Returns a reference to this object so that method calls can be ...
[ "<p", ">", "The", "list", "of", "parameter", "overrides", "to", "be", "passed", "into", "the", "toolchain", "template", "during", "stack", "provisioning", "if", "any", ".", "<", "/", "p", ">" ]
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-codestar/src/main/java/com/amazonaws/services/codestar/model/Toolchain.java#L176-L179
fhoeben/hsac-fitnesse-fixtures
src/main/java/nl/hsac/fitnesse/fixture/slim/StringFixture.java
StringFixture.replaceAllInWith
public String replaceAllInWith(String regEx, String value, String replace) { """ Replaces all occurrences of the regular expression in the value with the replacement value. @param regEx regular expression to match. @param value value to replace in. @param replace replacement pattern. @return result. """ ...
java
public String replaceAllInWith(String regEx, String value, String replace) { String result = null; if (value != null) { if (replace == null) { // empty cell in table is sent as null replace = ""; } result = getMatcher(regEx, value).repl...
[ "public", "String", "replaceAllInWith", "(", "String", "regEx", ",", "String", "value", ",", "String", "replace", ")", "{", "String", "result", "=", "null", ";", "if", "(", "value", "!=", "null", ")", "{", "if", "(", "replace", "==", "null", ")", "{", ...
Replaces all occurrences of the regular expression in the value with the replacement value. @param regEx regular expression to match. @param value value to replace in. @param replace replacement pattern. @return result.
[ "Replaces", "all", "occurrences", "of", "the", "regular", "expression", "in", "the", "value", "with", "the", "replacement", "value", "." ]
train
https://github.com/fhoeben/hsac-fitnesse-fixtures/blob/4e9018d7386a9aa65bfcbf07eb28ae064edd1732/src/main/java/nl/hsac/fitnesse/fixture/slim/StringFixture.java#L166-L176
FedericoPecora/meta-csp-framework
src/main/java/org/metacsp/utility/logging/LinePainter.java
LinePainter.setLighter
public void setLighter(Color color) { """ /* Calculate the line color by making the selection color lighter @return the color of the background line """ int red = Math.min(255, (int)(color.getRed() * 1.2)); int green = Math.min(255, (int)(color.getGreen() * 1.2)); int blue = Math.min(255, (int)(co...
java
public void setLighter(Color color) { int red = Math.min(255, (int)(color.getRed() * 1.2)); int green = Math.min(255, (int)(color.getGreen() * 1.2)); int blue = Math.min(255, (int)(color.getBlue() * 1.2)); setColor(new Color(red, green, blue)); }
[ "public", "void", "setLighter", "(", "Color", "color", ")", "{", "int", "red", "=", "Math", ".", "min", "(", "255", ",", "(", "int", ")", "(", "color", ".", "getRed", "(", ")", "*", "1.2", ")", ")", ";", "int", "green", "=", "Math", ".", "min",...
/* Calculate the line color by making the selection color lighter @return the color of the background line
[ "/", "*", "Calculate", "the", "line", "color", "by", "making", "the", "selection", "color", "lighter" ]
train
https://github.com/FedericoPecora/meta-csp-framework/blob/42aaef2e2b76d0f738427f0dd9653c4f62b40517/src/main/java/org/metacsp/utility/logging/LinePainter.java#L84-L90
dejv78/javafx-commons
jfx-controls/src/main/java/dejv/jfx/controls/radialmenu1/internal/RadialMenuItem.java
RadialMenuItem.setupMenuButton
public static void setupMenuButton(ButtonBase button, RadialMenuParams params, Node graphic, String tooltip, boolean addStyle) { """ Setup the round button. @param button Button to setup @param params Customization parameters @param graphic Graphics contents @param tooltip Tooltip text """ butt...
java
public static void setupMenuButton(ButtonBase button, RadialMenuParams params, Node graphic, String tooltip, boolean addStyle) { button.minWidthProperty().bind(params.buttonSizeProperty()); button.minHeightProperty().bind(params.buttonSizeProperty()); button.prefWidthProperty().bind(params.butto...
[ "public", "static", "void", "setupMenuButton", "(", "ButtonBase", "button", ",", "RadialMenuParams", "params", ",", "Node", "graphic", ",", "String", "tooltip", ",", "boolean", "addStyle", ")", "{", "button", ".", "minWidthProperty", "(", ")", ".", "bind", "("...
Setup the round button. @param button Button to setup @param params Customization parameters @param graphic Graphics contents @param tooltip Tooltip text
[ "Setup", "the", "round", "button", "." ]
train
https://github.com/dejv78/javafx-commons/blob/ea846eeeb4ed43a7628a40931a3e6f27d513592f/jfx-controls/src/main/java/dejv/jfx/controls/radialmenu1/internal/RadialMenuItem.java#L176-L192
JRebirth/JRebirth
org.jrebirth.af/core/src/main/java/org/jrebirth/af/core/concurrent/JRebirth.java
JRebirth.runIntoJATSync
public static void runIntoJATSync(final String runnableName, final Runnable runnable, final long... timeout) { """ Run the task into the JavaFX Application Thread [JAT] <b>Synchronously</b>. @param runnableName the name of the runnable for logging purpose @param runnable the task to run @param timeout the opt...
java
public static void runIntoJATSync(final String runnableName, final Runnable runnable, final long... timeout) { runIntoJATSync(new JrbReferenceRunnable(runnableName, runnable), timeout); }
[ "public", "static", "void", "runIntoJATSync", "(", "final", "String", "runnableName", ",", "final", "Runnable", "runnable", ",", "final", "long", "...", "timeout", ")", "{", "runIntoJATSync", "(", "new", "JrbReferenceRunnable", "(", "runnableName", ",", "runnable"...
Run the task into the JavaFX Application Thread [JAT] <b>Synchronously</b>. @param runnableName the name of the runnable for logging purpose @param runnable the task to run @param timeout the optional timeout value after which the thread will be released (default is 1000 ms)
[ "Run", "the", "task", "into", "the", "JavaFX", "Application", "Thread", "[", "JAT", "]", "<b", ">", "Synchronously<", "/", "b", ">", "." ]
train
https://github.com/JRebirth/JRebirth/blob/93f4fc087b83c73db540333b9686e97b4cec694d/org.jrebirth.af/core/src/main/java/org/jrebirth/af/core/concurrent/JRebirth.java#L186-L188
threerings/nenya
core/src/main/java/com/threerings/util/DirectionUtil.java
DirectionUtil.rotateCW
public static int rotateCW (int direction, int ticks) { """ Rotates the requested <em>fine</em> direction constant clockwise by the requested number of ticks. """ for (int ii = 0; ii < ticks; ii++) { direction = FINE_CW_ROTATE[direction]; } return direction; }
java
public static int rotateCW (int direction, int ticks) { for (int ii = 0; ii < ticks; ii++) { direction = FINE_CW_ROTATE[direction]; } return direction; }
[ "public", "static", "int", "rotateCW", "(", "int", "direction", ",", "int", "ticks", ")", "{", "for", "(", "int", "ii", "=", "0", ";", "ii", "<", "ticks", ";", "ii", "++", ")", "{", "direction", "=", "FINE_CW_ROTATE", "[", "direction", "]", ";", "}...
Rotates the requested <em>fine</em> direction constant clockwise by the requested number of ticks.
[ "Rotates", "the", "requested", "<em", ">", "fine<", "/", "em", ">", "direction", "constant", "clockwise", "by", "the", "requested", "number", "of", "ticks", "." ]
train
https://github.com/threerings/nenya/blob/3165a012fd859009db3367f87bd2a5b820cc760a/core/src/main/java/com/threerings/util/DirectionUtil.java#L105-L111
thelinmichael/spotify-web-api-java
src/main/java/com/wrapper/spotify/SpotifyApi.java
SpotifyApi.uploadCustomPlaylistCoverImage
@Deprecated public UploadCustomPlaylistCoverImageRequest.Builder uploadCustomPlaylistCoverImage(String user_id, String playlist_id) { """ Replace the image used to represent a specific playlist. @deprecated Playlist IDs are unique for themselves. This parameter is thus no longer used. (https://developer.spot...
java
@Deprecated public UploadCustomPlaylistCoverImageRequest.Builder uploadCustomPlaylistCoverImage(String user_id, String playlist_id) { return new UploadCustomPlaylistCoverImageRequest.Builder(accessToken) .setDefaults(httpManager, scheme, host, port) .user_id(user_id) .playlist_...
[ "@", "Deprecated", "public", "UploadCustomPlaylistCoverImageRequest", ".", "Builder", "uploadCustomPlaylistCoverImage", "(", "String", "user_id", ",", "String", "playlist_id", ")", "{", "return", "new", "UploadCustomPlaylistCoverImageRequest", ".", "Builder", "(", "accessTo...
Replace the image used to represent a specific playlist. @deprecated Playlist IDs are unique for themselves. This parameter is thus no longer used. (https://developer.spotify.com/community/news/2018/06/12/changes-to-playlist-uris/) @param user_id The users Spotify user ID. @param playlist_id The Spotify ID for the...
[ "Replace", "the", "image", "used", "to", "represent", "a", "specific", "playlist", "." ]
train
https://github.com/thelinmichael/spotify-web-api-java/blob/c06b8512344c0310d0c1df362fa267879021da2e/src/main/java/com/wrapper/spotify/SpotifyApi.java#L1447-L1453
UrielCh/ovh-java-sdk
ovh-java-sdk-telephony/src/main/java/net/minidev/ovh/api/ApiOvhTelephony.java
ApiOvhTelephony.billingAccount_redirect_serviceName_PUT
public void billingAccount_redirect_serviceName_PUT(String billingAccount, String serviceName, OvhRedirect body) throws IOException { """ Alter this object properties REST: PUT /telephony/{billingAccount}/redirect/{serviceName} @param body [required] New object properties @param billingAccount [required] The ...
java
public void billingAccount_redirect_serviceName_PUT(String billingAccount, String serviceName, OvhRedirect body) throws IOException { String qPath = "/telephony/{billingAccount}/redirect/{serviceName}"; StringBuilder sb = path(qPath, billingAccount, serviceName); exec(qPath, "PUT", sb.toString(), body); }
[ "public", "void", "billingAccount_redirect_serviceName_PUT", "(", "String", "billingAccount", ",", "String", "serviceName", ",", "OvhRedirect", "body", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/telephony/{billingAccount}/redirect/{serviceName}\"", ";", ...
Alter this object properties REST: PUT /telephony/{billingAccount}/redirect/{serviceName} @param body [required] New object properties @param billingAccount [required] The name of your billingAccount @param serviceName [required]
[ "Alter", "this", "object", "properties" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-telephony/src/main/java/net/minidev/ovh/api/ApiOvhTelephony.java#L8300-L8304
Azure/azure-sdk-for-java
compute/resource-manager/v2018_04_01/src/main/java/com/microsoft/azure/management/compute/v2018_04_01/implementation/DisksInner.java
DisksInner.beginCreateOrUpdateAsync
public Observable<DiskInner> beginCreateOrUpdateAsync(String resourceGroupName, String diskName, DiskInner disk) { """ Creates or updates a disk. @param resourceGroupName The name of the resource group. @param diskName The name of the managed disk that is being created. The name can't be changed after the disk...
java
public Observable<DiskInner> beginCreateOrUpdateAsync(String resourceGroupName, String diskName, DiskInner disk) { return beginCreateOrUpdateWithServiceResponseAsync(resourceGroupName, diskName, disk).map(new Func1<ServiceResponse<DiskInner>, DiskInner>() { @Override public DiskInner cal...
[ "public", "Observable", "<", "DiskInner", ">", "beginCreateOrUpdateAsync", "(", "String", "resourceGroupName", ",", "String", "diskName", ",", "DiskInner", "disk", ")", "{", "return", "beginCreateOrUpdateWithServiceResponseAsync", "(", "resourceGroupName", ",", "diskName"...
Creates or updates a disk. @param resourceGroupName The name of the resource group. @param diskName The name of the managed disk that is being created. The name can't be changed after the disk is created. Supported characters for the name are a-z, A-Z, 0-9 and _. The maximum name length is 80 characters. @param disk D...
[ "Creates", "or", "updates", "a", "disk", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/compute/resource-manager/v2018_04_01/src/main/java/com/microsoft/azure/management/compute/v2018_04_01/implementation/DisksInner.java#L248-L255
google/error-prone-javac
src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/HtmlDocletWriter.java
HtmlDocletWriter.getDocLink
public Content getDocLink(LinkInfoImpl.Kind context, ClassDoc classDoc, MemberDoc doc, String label, boolean strong, boolean isProperty) { """ Return the link for the given member. @param context the id of the context where the link will be printed. @param classDoc the classDoc that we should link ...
java
public Content getDocLink(LinkInfoImpl.Kind context, ClassDoc classDoc, MemberDoc doc, String label, boolean strong, boolean isProperty) { return getDocLink(context, classDoc, doc, new StringContent(check(label)), strong, isProperty); }
[ "public", "Content", "getDocLink", "(", "LinkInfoImpl", ".", "Kind", "context", ",", "ClassDoc", "classDoc", ",", "MemberDoc", "doc", ",", "String", "label", ",", "boolean", "strong", ",", "boolean", "isProperty", ")", "{", "return", "getDocLink", "(", "contex...
Return the link for the given member. @param context the id of the context where the link will be printed. @param classDoc the classDoc that we should link to. This is not necessarily equal to doc.containingClass(). We may be inheriting comments. @param doc the member being linked to. @param label the label for the ...
[ "Return", "the", "link", "for", "the", "given", "member", "." ]
train
https://github.com/google/error-prone-javac/blob/a53d069bbdb2c60232ed3811c19b65e41c3e60e0/src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/HtmlDocletWriter.java#L1227-L1230
joniles/mpxj
src/main/java/net/sf/mpxj/mpp/GanttChartView.java
GanttChartView.getFontStyle
protected FontStyle getFontStyle(byte[] data, int offset, Map<Integer, FontBase> fontBases) { """ Retrieve font details from a block of property data. @param data property data @param offset offset into property data @param fontBases map of font bases @return FontStyle instance """ Integer index = ...
java
protected FontStyle getFontStyle(byte[] data, int offset, Map<Integer, FontBase> fontBases) { Integer index = Integer.valueOf(MPPUtility.getByte(data, offset)); FontBase fontBase = fontBases.get(index); int style = MPPUtility.getByte(data, offset + 1); ColorType color = ColorType.getInstance(...
[ "protected", "FontStyle", "getFontStyle", "(", "byte", "[", "]", "data", ",", "int", "offset", ",", "Map", "<", "Integer", ",", "FontBase", ">", "fontBases", ")", "{", "Integer", "index", "=", "Integer", ".", "valueOf", "(", "MPPUtility", ".", "getByte", ...
Retrieve font details from a block of property data. @param data property data @param offset offset into property data @param fontBases map of font bases @return FontStyle instance
[ "Retrieve", "font", "details", "from", "a", "block", "of", "property", "data", "." ]
train
https://github.com/joniles/mpxj/blob/143ea0e195da59cd108f13b3b06328e9542337e8/src/main/java/net/sf/mpxj/mpp/GanttChartView.java#L1135-L1149
sebastiangraf/treetank
interfacemodules/xml/src/main/java/org/treetank/service/xml/xpath/PipelineBuilder.java
PipelineBuilder.addLiteral
public void addLiteral(final INodeReadTrx pTrans, final AtomicValue pVal) { """ Adds a literal expression to the pipeline. @param pTrans Transaction to operate with. @param pVal key of the literal expression. """ getExpression().add(new LiteralExpr(pTrans, AbsAxis.addAtomicToItemList(pTrans, pVal...
java
public void addLiteral(final INodeReadTrx pTrans, final AtomicValue pVal) { getExpression().add(new LiteralExpr(pTrans, AbsAxis.addAtomicToItemList(pTrans, pVal))); }
[ "public", "void", "addLiteral", "(", "final", "INodeReadTrx", "pTrans", ",", "final", "AtomicValue", "pVal", ")", "{", "getExpression", "(", ")", ".", "add", "(", "new", "LiteralExpr", "(", "pTrans", ",", "AbsAxis", ".", "addAtomicToItemList", "(", "pTrans", ...
Adds a literal expression to the pipeline. @param pTrans Transaction to operate with. @param pVal key of the literal expression.
[ "Adds", "a", "literal", "expression", "to", "the", "pipeline", "." ]
train
https://github.com/sebastiangraf/treetank/blob/9b96d631b6c2a8502a0cc958dcb02bd6a6fd8b60/interfacemodules/xml/src/main/java/org/treetank/service/xml/xpath/PipelineBuilder.java#L485-L487
google/j2objc
jre_emul/android/platform/external/okhttp/okio/okio/src/main/java/okio/Segment.java
Segment.writeTo
public void writeTo(Segment sink, int byteCount) { """ Moves {@code byteCount} bytes from this segment to {@code sink}. """ if (!sink.owner) throw new IllegalArgumentException(); if (sink.limit + byteCount > SIZE) { // We can't fit byteCount bytes at the sink's current position. Shift sink first....
java
public void writeTo(Segment sink, int byteCount) { if (!sink.owner) throw new IllegalArgumentException(); if (sink.limit + byteCount > SIZE) { // We can't fit byteCount bytes at the sink's current position. Shift sink first. if (sink.shared) throw new IllegalArgumentException(); if (sink.limit...
[ "public", "void", "writeTo", "(", "Segment", "sink", ",", "int", "byteCount", ")", "{", "if", "(", "!", "sink", ".", "owner", ")", "throw", "new", "IllegalArgumentException", "(", ")", ";", "if", "(", "sink", ".", "limit", "+", "byteCount", ">", "SIZE"...
Moves {@code byteCount} bytes from this segment to {@code sink}.
[ "Moves", "{" ]
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/okhttp/okio/okio/src/main/java/okio/Segment.java#L134-L148
thelinmichael/spotify-web-api-java
src/main/java/com/wrapper/spotify/SpotifyApi.java
SpotifyApi.checkUsersFollowPlaylist
public CheckUsersFollowPlaylistRequest.Builder checkUsersFollowPlaylist( String owner_id, String playlist_id, String[] ids) { """ Check to see if one or more Spotify users are following a specified playlist. @param owner_id The Spotify User ID of the person who owns the playlist. @param playlist_i...
java
public CheckUsersFollowPlaylistRequest.Builder checkUsersFollowPlaylist( String owner_id, String playlist_id, String[] ids) { return new CheckUsersFollowPlaylistRequest.Builder(accessToken) .setDefaults(httpManager, scheme, host, port) .owner_id(owner_id) .playlist_id(p...
[ "public", "CheckUsersFollowPlaylistRequest", ".", "Builder", "checkUsersFollowPlaylist", "(", "String", "owner_id", ",", "String", "playlist_id", ",", "String", "[", "]", "ids", ")", "{", "return", "new", "CheckUsersFollowPlaylistRequest", ".", "Builder", "(", "access...
Check to see if one or more Spotify users are following a specified playlist. @param owner_id The Spotify User ID of the person who owns the playlist. @param playlist_id The Spotify ID of the playlist. @param ids A list of Spotify User IDs; the IDs of the users that you want to check to see if they follow t...
[ "Check", "to", "see", "if", "one", "or", "more", "Spotify", "users", "are", "following", "a", "specified", "playlist", "." ]
train
https://github.com/thelinmichael/spotify-web-api-java/blob/c06b8512344c0310d0c1df362fa267879021da2e/src/main/java/com/wrapper/spotify/SpotifyApi.java#L630-L637
fozziethebeat/S-Space
src/main/java/edu/ucla/sspace/common/Similarity.java
Similarity.tanimotoCoefficient
@SuppressWarnings("unchecked") public static double tanimotoCoefficient(IntegerVector a, IntegerVector b) { """ Returns the Tanimoto Coefficient of the two {@code IntegerVector} instances @throws IllegalArgumentException when the length of the two vectors are not the same. """ check(a,b); ...
java
@SuppressWarnings("unchecked") public static double tanimotoCoefficient(IntegerVector a, IntegerVector b) { check(a,b); // IMPLEMENTATION NOTE: The Tanimoto coefficient uses the squart of the // vector magnitudes, which we could compute by just summing the square // of the vector va...
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "public", "static", "double", "tanimotoCoefficient", "(", "IntegerVector", "a", ",", "IntegerVector", "b", ")", "{", "check", "(", "a", ",", "b", ")", ";", "// IMPLEMENTATION NOTE: The Tanimoto coefficient uses the s...
Returns the Tanimoto Coefficient of the two {@code IntegerVector} instances @throws IllegalArgumentException when the length of the two vectors are not the same.
[ "Returns", "the", "Tanimoto", "Coefficient", "of", "the", "two", "{", "@code", "IntegerVector", "}", "instances" ]
train
https://github.com/fozziethebeat/S-Space/blob/a608102737dfd3d59038a9ead33fe60356bc6029/src/main/java/edu/ucla/sspace/common/Similarity.java#L2349-L2372
Waikato/moa
moa/src/main/java/weka/gui/MOAClassOptionEditor.java
MOAClassOptionEditor.paintValue
public void paintValue(Graphics gfx, Rectangle box) { """ Paints a representation of the current Object. @param gfx the graphics context to use @param box the area we are allowed to paint into """ FontMetrics fm; int vpad; String val; fm = gfx.getFontMetrics(); vpad = (bo...
java
public void paintValue(Graphics gfx, Rectangle box) { FontMetrics fm; int vpad; String val; fm = gfx.getFontMetrics(); vpad = (box.height - fm.getHeight()) / 2 ; val = ((ClassOption) getValue()).getValueAsCLIString(); gfx.drawString(val, 2, fm.getHeight() + vpad); }
[ "public", "void", "paintValue", "(", "Graphics", "gfx", ",", "Rectangle", "box", ")", "{", "FontMetrics", "fm", ";", "int", "vpad", ";", "String", "val", ";", "fm", "=", "gfx", ".", "getFontMetrics", "(", ")", ";", "vpad", "=", "(", "box", ".", "heig...
Paints a representation of the current Object. @param gfx the graphics context to use @param box the area we are allowed to paint into
[ "Paints", "a", "representation", "of", "the", "current", "Object", "." ]
train
https://github.com/Waikato/moa/blob/395982e5100bfe75a3a4d26115462ce2cc74cbb0/moa/src/main/java/weka/gui/MOAClassOptionEditor.java#L117-L126
lightbend/config
config/src/main/java/com/typesafe/config/ConfigRenderOptions.java
ConfigRenderOptions.setComments
public ConfigRenderOptions setComments(boolean value) { """ Returns options with comments toggled. This controls human-written comments but not the autogenerated "origin of this setting" comments, which are controlled by {@link ConfigRenderOptions#setOriginComments}. @param value true to include comments in ...
java
public ConfigRenderOptions setComments(boolean value) { if (value == comments) return this; else return new ConfigRenderOptions(originComments, value, formatted, json); }
[ "public", "ConfigRenderOptions", "setComments", "(", "boolean", "value", ")", "{", "if", "(", "value", "==", "comments", ")", "return", "this", ";", "else", "return", "new", "ConfigRenderOptions", "(", "originComments", ",", "value", ",", "formatted", ",", "js...
Returns options with comments toggled. This controls human-written comments but not the autogenerated "origin of this setting" comments, which are controlled by {@link ConfigRenderOptions#setOriginComments}. @param value true to include comments in the render @return options with requested setting for comments
[ "Returns", "options", "with", "comments", "toggled", ".", "This", "controls", "human", "-", "written", "comments", "but", "not", "the", "autogenerated", "origin", "of", "this", "setting", "comments", "which", "are", "controlled", "by", "{", "@link", "ConfigRende...
train
https://github.com/lightbend/config/blob/68cebfde5e861e9a5fdc75ceff366ed95e17d475/config/src/main/java/com/typesafe/config/ConfigRenderOptions.java#L63-L68
alkacon/opencms-core
src-modules/org/opencms/workplace/help/CmsHelpNavigationListView.java
CmsHelpNavigationListView.createNavigationInternal
private void createNavigationInternal(StringBuffer buffer, List<CmsJspNavElement> navElements) { """ Creates the HTML for the internal help.<p> @param buffer the StringBuffer to which the Navigation will be appended @param navElements the navigation elements to build the navigation for """ // take...
java
private void createNavigationInternal(StringBuffer buffer, List<CmsJspNavElement> navElements) { // take the element to render. CmsJspNavElement element = navElements.remove(0); int elementLevel = element.getNavTreeLevel(); String spacing = getSpaces(elementLevel * 2); // render...
[ "private", "void", "createNavigationInternal", "(", "StringBuffer", "buffer", ",", "List", "<", "CmsJspNavElement", ">", "navElements", ")", "{", "// take the element to render.", "CmsJspNavElement", "element", "=", "navElements", ".", "remove", "(", "0", ")", ";", ...
Creates the HTML for the internal help.<p> @param buffer the StringBuffer to which the Navigation will be appended @param navElements the navigation elements to build the navigation for
[ "Creates", "the", "HTML", "for", "the", "internal", "help", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src-modules/org/opencms/workplace/help/CmsHelpNavigationListView.java#L212-L253
mapfish/mapfish-print
core/src/main/java/org/mapfish/print/wrapper/json/PJsonArray.java
PJsonArray.getJSONObject
public final PJsonObject getJSONObject(final int i) { """ Get the element at the index as a json object. @param i the index of the object to access """ JSONObject val = this.array.optJSONObject(i); final String context = "[" + i + "]"; if (val == null) { throw new ObjectM...
java
public final PJsonObject getJSONObject(final int i) { JSONObject val = this.array.optJSONObject(i); final String context = "[" + i + "]"; if (val == null) { throw new ObjectMissingException(this, context); } return new PJsonObject(this, val, context); }
[ "public", "final", "PJsonObject", "getJSONObject", "(", "final", "int", "i", ")", "{", "JSONObject", "val", "=", "this", ".", "array", ".", "optJSONObject", "(", "i", ")", ";", "final", "String", "context", "=", "\"[\"", "+", "i", "+", "\"]\"", ";", "i...
Get the element at the index as a json object. @param i the index of the object to access
[ "Get", "the", "element", "at", "the", "index", "as", "a", "json", "object", "." ]
train
https://github.com/mapfish/mapfish-print/blob/25a452cb39f592bd8a53b20db1037703898e1e22/core/src/main/java/org/mapfish/print/wrapper/json/PJsonArray.java#L52-L59
overturetool/overture
ide/plugins/poviewer/src/main/java/org/overture/ide/plugins/poviewer/view/PoTableView.java
PoTableView.createPartControl
@Override public void createPartControl(Composite parent) { """ This is a callback that will allow us to create the viewer and initialize it. """ viewer = new StyledText(parent, SWT.WRAP | SWT.V_SCROLL|SWT.READ_ONLY); viewer.setFont(font); }
java
@Override public void createPartControl(Composite parent) { viewer = new StyledText(parent, SWT.WRAP | SWT.V_SCROLL|SWT.READ_ONLY); viewer.setFont(font); }
[ "@", "Override", "public", "void", "createPartControl", "(", "Composite", "parent", ")", "{", "viewer", "=", "new", "StyledText", "(", "parent", ",", "SWT", ".", "WRAP", "|", "SWT", ".", "V_SCROLL", "|", "SWT", ".", "READ_ONLY", ")", ";", "viewer", ".", ...
This is a callback that will allow us to create the viewer and initialize it.
[ "This", "is", "a", "callback", "that", "will", "allow", "us", "to", "create", "the", "viewer", "and", "initialize", "it", "." ]
train
https://github.com/overturetool/overture/blob/83175dc6c24fa171cde4fcf61ecb648eba3bdbc1/ide/plugins/poviewer/src/main/java/org/overture/ide/plugins/poviewer/view/PoTableView.java#L72-L78
deeplearning4j/deeplearning4j
deeplearning4j/deeplearning4j-nn/src/main/java/org/deeplearning4j/nn/layers/convolution/CnnLossLayer.java
CnnLossLayer.computeScoreForExamples
@Override public INDArray computeScoreForExamples(double fullNetRegTerm, LayerWorkspaceMgr workspaceMgr) { """ Compute the score for each example individually, after labels and input have been set. @param fullNetRegTerm Regularization score term for the entire network (or, 0.0 to not include regularization)...
java
@Override public INDArray computeScoreForExamples(double fullNetRegTerm, LayerWorkspaceMgr workspaceMgr) { //For CNN: need to sum up the score over each x/y location before returning if (input == null || labels == null) throw new IllegalStateException("Cannot calculate score without inp...
[ "@", "Override", "public", "INDArray", "computeScoreForExamples", "(", "double", "fullNetRegTerm", ",", "LayerWorkspaceMgr", "workspaceMgr", ")", "{", "//For CNN: need to sum up the score over each x/y location before returning", "if", "(", "input", "==", "null", "||", "label...
Compute the score for each example individually, after labels and input have been set. @param fullNetRegTerm Regularization score term for the entire network (or, 0.0 to not include regularization) @return A column INDArray of shape [numExamples,1], where entry i is the score of the ith example
[ "Compute", "the", "score", "for", "each", "example", "individually", "after", "labels", "and", "input", "have", "been", "set", "." ]
train
https://github.com/deeplearning4j/deeplearning4j/blob/effce52f2afd7eeb53c5bcca699fcd90bd06822f/deeplearning4j/deeplearning4j-nn/src/main/java/org/deeplearning4j/nn/layers/convolution/CnnLossLayer.java#L219-L248
yanzhenjie/Album
album/src/main/java/com/yanzhenjie/album/util/AlbumUtils.java
AlbumUtils.getTintDrawable
@NonNull public static Drawable getTintDrawable(@NonNull Drawable drawable, @ColorInt int color) { """ Specifies a tint for {@code drawable}. @param drawable drawable target, mutate. @param color color. @return convert drawable. """ drawable = DrawableCompat.wrap(drawable.mutate()); ...
java
@NonNull public static Drawable getTintDrawable(@NonNull Drawable drawable, @ColorInt int color) { drawable = DrawableCompat.wrap(drawable.mutate()); DrawableCompat.setTint(drawable, color); return drawable; }
[ "@", "NonNull", "public", "static", "Drawable", "getTintDrawable", "(", "@", "NonNull", "Drawable", "drawable", ",", "@", "ColorInt", "int", "color", ")", "{", "drawable", "=", "DrawableCompat", ".", "wrap", "(", "drawable", ".", "mutate", "(", ")", ")", "...
Specifies a tint for {@code drawable}. @param drawable drawable target, mutate. @param color color. @return convert drawable.
[ "Specifies", "a", "tint", "for", "{", "@code", "drawable", "}", "." ]
train
https://github.com/yanzhenjie/Album/blob/b17506440d32909d42aba41f6a388041a25c8363/album/src/main/java/com/yanzhenjie/album/util/AlbumUtils.java#L316-L321
gitblit/fathom
fathom-security/src/main/java/fathom/realm/Account.java
Account.checkPermissions
public void checkPermissions(Collection<String> permissions) throws AuthorizationException { """ Ensures this Account {@link fathom.authz.Permission#implies(fathom.authz.Permission) implies} all of the specified permission strings. <p> If this Account's existing associated permissions do not {@link fathom.aut...
java
public void checkPermissions(Collection<String> permissions) throws AuthorizationException { if (!isPermittedAll(permissions)) { throw new AuthorizationException("'{}' does not have the permissions {}", toString(), permissions); } }
[ "public", "void", "checkPermissions", "(", "Collection", "<", "String", ">", "permissions", ")", "throws", "AuthorizationException", "{", "if", "(", "!", "isPermittedAll", "(", "permissions", ")", ")", "{", "throw", "new", "AuthorizationException", "(", "\"'{}' do...
Ensures this Account {@link fathom.authz.Permission#implies(fathom.authz.Permission) implies} all of the specified permission strings. <p> If this Account's existing associated permissions do not {@link fathom.authz.Permission#implies(fathom.authz.Permission) imply} all of the given permissions, an {@link fathom.authz....
[ "Ensures", "this", "Account", "{", "@link", "fathom", ".", "authz", ".", "Permission#implies", "(", "fathom", ".", "authz", ".", "Permission", ")", "implies", "}", "all", "of", "the", "specified", "permission", "strings", ".", "<p", ">", "If", "this", "Acc...
train
https://github.com/gitblit/fathom/blob/f2f820eb16e9fea1e36ad4eda4ed51b35f056538/fathom-security/src/main/java/fathom/realm/Account.java#L350-L354
deephacks/confit
provider-hbase-filter/src/main/java/org/deephacks/confit/internal/hbase/Bytes.java
Bytes.setInt
public static void setInt(final byte[] b, final int n, final int offset) { """ Writes a big-endian 4-byte int at an offset in the given array. @param b The array to write to. @param offset The offset in the array to start writing at. @throws IndexOutOfBoundsException if the byte array is too small. """ ...
java
public static void setInt(final byte[] b, final int n, final int offset) { b[offset + 0] = (byte) (n >>> 24); b[offset + 1] = (byte) (n >>> 16); b[offset + 2] = (byte) (n >>> 8); b[offset + 3] = (byte) (n >>> 0); }
[ "public", "static", "void", "setInt", "(", "final", "byte", "[", "]", "b", ",", "final", "int", "n", ",", "final", "int", "offset", ")", "{", "b", "[", "offset", "+", "0", "]", "=", "(", "byte", ")", "(", "n", ">>>", "24", ")", ";", "b", "[",...
Writes a big-endian 4-byte int at an offset in the given array. @param b The array to write to. @param offset The offset in the array to start writing at. @throws IndexOutOfBoundsException if the byte array is too small.
[ "Writes", "a", "big", "-", "endian", "4", "-", "byte", "int", "at", "an", "offset", "in", "the", "given", "array", "." ]
train
https://github.com/deephacks/confit/blob/4e6d4ee5fed32cbc5104433e61de1bcf1b360832/provider-hbase-filter/src/main/java/org/deephacks/confit/internal/hbase/Bytes.java#L185-L190
acromusashi/acromusashi-stream
src/main/java/acromusashi/stream/config/StormConfigUtil.java
StormConfigUtil.getStringValue
public static String getStringValue(Config stormConf, String key, String defaultValue) { """ Storm設定オブジェクトから文字列型の設定値を取得する。<br> 存在しない場合はデフォルト値を返す。 @param stormConf Storm設定オブジェクト @param key 設定値のキー @param defaultValue デフォルト値 @return 個別設定値(String型) """ Object config = stormConf.get(key); ...
java
public static String getStringValue(Config stormConf, String key, String defaultValue) { Object config = stormConf.get(key); if (config == null) { return defaultValue; } return config.toString(); }
[ "public", "static", "String", "getStringValue", "(", "Config", "stormConf", ",", "String", "key", ",", "String", "defaultValue", ")", "{", "Object", "config", "=", "stormConf", ".", "get", "(", "key", ")", ";", "if", "(", "config", "==", "null", ")", "{"...
Storm設定オブジェクトから文字列型の設定値を取得する。<br> 存在しない場合はデフォルト値を返す。 @param stormConf Storm設定オブジェクト @param key 設定値のキー @param defaultValue デフォルト値 @return 個別設定値(String型)
[ "Storm設定オブジェクトから文字列型の設定値を取得する。<br", ">", "存在しない場合はデフォルト値を返す。" ]
train
https://github.com/acromusashi/acromusashi-stream/blob/65b1f335d771d657c5640a2056ab5c8546eddec9/src/main/java/acromusashi/stream/config/StormConfigUtil.java#L43-L53
jenkinsci/email-ext-plugin
src/main/java/hudson/plugins/emailext/plugins/recipients/UpstreamComitterRecipientProvider.java
UpstreamComitterRecipientProvider.addUserFromChangeSet
private void addUserFromChangeSet(ChangeLogSet.Entry change, Set<InternetAddress> to, Set<InternetAddress> cc, Set<InternetAddress> bcc, EnvVars env, final ExtendedEmailPublisherContext context, RecipientProviderUtilities.IDebug debug) { """ Adds a user to the recipients list based on a specific SCM change set @p...
java
private void addUserFromChangeSet(ChangeLogSet.Entry change, Set<InternetAddress> to, Set<InternetAddress> cc, Set<InternetAddress> bcc, EnvVars env, final ExtendedEmailPublisherContext context, RecipientProviderUtilities.IDebug debug) { User user = change.getAuthor(); RecipientProviderUtilities.addUser...
[ "private", "void", "addUserFromChangeSet", "(", "ChangeLogSet", ".", "Entry", "change", ",", "Set", "<", "InternetAddress", ">", "to", ",", "Set", "<", "InternetAddress", ">", "cc", ",", "Set", "<", "InternetAddress", ">", "bcc", ",", "EnvVars", "env", ",", ...
Adds a user to the recipients list based on a specific SCM change set @param change The ChangeLogSet.Entry to get the user information from @param to The list of to addresses to add to @param cc The list of cc addresses to add to @param bcc The list of bcc addresses to add to @param env The build environment @param lis...
[ "Adds", "a", "user", "to", "the", "recipients", "list", "based", "on", "a", "specific", "SCM", "change", "set" ]
train
https://github.com/jenkinsci/email-ext-plugin/blob/21fbd402665848a18205b26751424149e51e86e4/src/main/java/hudson/plugins/emailext/plugins/recipients/UpstreamComitterRecipientProvider.java#L112-L115
asterisk-java/asterisk-java
src/main/java/org/asteriskjava/live/internal/AsteriskChannelImpl.java
AsteriskChannelImpl.stateChanged
synchronized void stateChanged(Date date, ChannelState state) { """ Changes the state of this channel. @param date when the state change occurred. @param state the new state of this channel. """ final ChannelStateHistoryEntry historyEntry; final ChannelState oldState = this.state; ...
java
synchronized void stateChanged(Date date, ChannelState state) { final ChannelStateHistoryEntry historyEntry; final ChannelState oldState = this.state; if (oldState == state) { return; } // System.err.println(id + " state change: " + oldState + " => " + s...
[ "synchronized", "void", "stateChanged", "(", "Date", "date", ",", "ChannelState", "state", ")", "{", "final", "ChannelStateHistoryEntry", "historyEntry", ";", "final", "ChannelState", "oldState", "=", "this", ".", "state", ";", "if", "(", "oldState", "==", "stat...
Changes the state of this channel. @param date when the state change occurred. @param state the new state of this channel.
[ "Changes", "the", "state", "of", "this", "channel", "." ]
train
https://github.com/asterisk-java/asterisk-java/blob/cdc9849270d97ef75afa447a02c5194ed29121eb/src/main/java/org/asteriskjava/live/internal/AsteriskChannelImpl.java#L303-L323
groovy/groovy-core
src/main/org/codehaus/groovy/runtime/StringGroovyMethods.java
StringGroovyMethods.getAt
public static CharSequence getAt(CharSequence text, Range range) { """ Support the range subscript operator for CharSequence @param text a CharSequence @param range a Range @return the subsequence CharSequence @since 1.0 """ RangeInfo info = subListBorders(text.length(), range); CharSequ...
java
public static CharSequence getAt(CharSequence text, Range range) { RangeInfo info = subListBorders(text.length(), range); CharSequence sequence = text.subSequence(info.from, info.to); return info.reverse ? reverse(sequence) : sequence; }
[ "public", "static", "CharSequence", "getAt", "(", "CharSequence", "text", ",", "Range", "range", ")", "{", "RangeInfo", "info", "=", "subListBorders", "(", "text", ".", "length", "(", ")", ",", "range", ")", ";", "CharSequence", "sequence", "=", "text", "....
Support the range subscript operator for CharSequence @param text a CharSequence @param range a Range @return the subsequence CharSequence @since 1.0
[ "Support", "the", "range", "subscript", "operator", "for", "CharSequence" ]
train
https://github.com/groovy/groovy-core/blob/01309f9d4be34ddf93c4a9943b5a97843bff6181/src/main/org/codehaus/groovy/runtime/StringGroovyMethods.java#L1289-L1293
jglobus/JGlobus
gss/src/main/java/org/globus/gsi/gssapi/SSLUtil.java
SSLUtil.toInt
public static int toInt(byte[] buf, int off) { """ Converts 4 bytes to an <code>int</code> at the specified offset in the given byte array. @param buf the byte array containing the 4 bytes to be converted to an <code>int</code>. @param off offset in the byte array @return the <code>int</code> value of the 4...
java
public static int toInt(byte[] buf, int off) { int lg = (buf[off] & 0xff) << 24; lg |= (buf[off+1] & 0xff) << 16; lg |= (buf[off+2] & 0xff) << 8; lg |= (buf[off+3] & 0xff); return lg; }
[ "public", "static", "int", "toInt", "(", "byte", "[", "]", "buf", ",", "int", "off", ")", "{", "int", "lg", "=", "(", "buf", "[", "off", "]", "&", "0xff", ")", "<<", "24", ";", "lg", "|=", "(", "buf", "[", "off", "+", "1", "]", "&", "0xff",...
Converts 4 bytes to an <code>int</code> at the specified offset in the given byte array. @param buf the byte array containing the 4 bytes to be converted to an <code>int</code>. @param off offset in the byte array @return the <code>int</code> value of the 4 bytes.
[ "Converts", "4", "bytes", "to", "an", "<code", ">", "int<", "/", "code", ">", "at", "the", "specified", "offset", "in", "the", "given", "byte", "array", "." ]
train
https://github.com/jglobus/JGlobus/blob/e14f6f6636544fd84298f9cec749d626ea971930/gss/src/main/java/org/globus/gsi/gssapi/SSLUtil.java#L166-L172
maven-nar/nar-maven-plugin
src/main/java/com/github/maven_nar/cpptasks/gcc/cross/GppLinker.java
GppLinker.decorateLinkerOption
@Override public String decorateLinkerOption(final StringBuffer buf, final String arg) { """ Allows drived linker to decorate linker option. Override by GppLinker to prepend a "-Wl," to pass option to through gcc to linker. @param buf buffer that may be used and abused in the decoration process, must not b...
java
@Override public String decorateLinkerOption(final StringBuffer buf, final String arg) { String decoratedArg = arg; if (arg.length() > 1 && arg.charAt(0) == '-') { switch (arg.charAt(1)) { // // passed automatically by GCC // case 'g': case 'f': case 'F': ...
[ "@", "Override", "public", "String", "decorateLinkerOption", "(", "final", "StringBuffer", "buf", ",", "final", "String", "arg", ")", "{", "String", "decoratedArg", "=", "arg", ";", "if", "(", "arg", ".", "length", "(", ")", ">", "1", "&&", "arg", ".", ...
Allows drived linker to decorate linker option. Override by GppLinker to prepend a "-Wl," to pass option to through gcc to linker. @param buf buffer that may be used and abused in the decoration process, must not be null. @param arg linker argument
[ "Allows", "drived", "linker", "to", "decorate", "linker", "option", ".", "Override", "by", "GppLinker", "to", "prepend", "a", "-", "Wl", "to", "pass", "option", "to", "through", "gcc", "to", "linker", "." ]
train
https://github.com/maven-nar/nar-maven-plugin/blob/3c622e2024296b4203431bbae3bde290a01dac00/src/main/java/com/github/maven_nar/cpptasks/gcc/cross/GppLinker.java#L128-L165
OpenTSDB/opentsdb
src/tsd/client/MetricForm.java
MetricForm.setSelectedItem
private void setSelectedItem(final ListBox list, final String item) { """ If the given item is in the list, mark it as selected. @param list The list to manipulate. @param item The item to select if present. """ final int nitems = list.getItemCount(); for (int i = 0; i < nitems; i++) { if (item...
java
private void setSelectedItem(final ListBox list, final String item) { final int nitems = list.getItemCount(); for (int i = 0; i < nitems; i++) { if (item.equals(list.getValue(i))) { list.setSelectedIndex(i); return; } } }
[ "private", "void", "setSelectedItem", "(", "final", "ListBox", "list", ",", "final", "String", "item", ")", "{", "final", "int", "nitems", "=", "list", ".", "getItemCount", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "nitems", ";"...
If the given item is in the list, mark it as selected. @param list The list to manipulate. @param item The item to select if present.
[ "If", "the", "given", "item", "is", "in", "the", "list", "mark", "it", "as", "selected", "." ]
train
https://github.com/OpenTSDB/opentsdb/blob/3fc2d491c3c1ad397252c0a80203a69a3f9e3ef3/src/tsd/client/MetricForm.java#L689-L697
alkacon/opencms-core
src/org/opencms/ugc/CmsUgcSession.java
CmsUgcSession.deleteResourceFromProject
private void deleteResourceFromProject(CmsObject cms, CmsResource res) throws CmsException { """ Deletes the given resource which is part of a form session project.<p> @param cms the CMS context to use @param res the resource to delete @throws CmsException if something goes wrong """ CmsLock l...
java
private void deleteResourceFromProject(CmsObject cms, CmsResource res) throws CmsException { CmsLock lock = cms.getLock(res); if (lock.isUnlocked() || lock.isLockableBy(cms.getRequestContext().getCurrentUser())) { cms.lockResourceTemporary(res); } else { cms.changeLock(r...
[ "private", "void", "deleteResourceFromProject", "(", "CmsObject", "cms", ",", "CmsResource", "res", ")", "throws", "CmsException", "{", "CmsLock", "lock", "=", "cms", ".", "getLock", "(", "res", ")", ";", "if", "(", "lock", ".", "isUnlocked", "(", ")", "||...
Deletes the given resource which is part of a form session project.<p> @param cms the CMS context to use @param res the resource to delete @throws CmsException if something goes wrong
[ "Deletes", "the", "given", "resource", "which", "is", "part", "of", "a", "form", "session", "project", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/ugc/CmsUgcSession.java#L766-L775
buschmais/jqa-maven3-plugin
src/main/java/com/buschmais/jqassistant/plugin/maven3/impl/scanner/MavenProjectScannerPlugin.java
MavenProjectScannerPlugin.addModules
private void addModules(MavenProject project, MavenProjectDirectoryDescriptor projectDescriptor, ScannerContext scannerContext) { """ Add relations to the modules. @param project The project. @param projectDescriptor The project descriptor. @param scannerContext The scanner context. """ File pr...
java
private void addModules(MavenProject project, MavenProjectDirectoryDescriptor projectDescriptor, ScannerContext scannerContext) { File projectDirectory = project.getBasedir(); Set<File> modules = new HashSet<>(); for (String moduleName : project.getModules()) { File module = new File...
[ "private", "void", "addModules", "(", "MavenProject", "project", ",", "MavenProjectDirectoryDescriptor", "projectDescriptor", ",", "ScannerContext", "scannerContext", ")", "{", "File", "projectDirectory", "=", "project", ".", "getBasedir", "(", ")", ";", "Set", "<", ...
Add relations to the modules. @param project The project. @param projectDescriptor The project descriptor. @param scannerContext The scanner context.
[ "Add", "relations", "to", "the", "modules", "." ]
train
https://github.com/buschmais/jqa-maven3-plugin/blob/6c6e2dca56de6d5b8ceeb2f28982fb6d7c98778f/src/main/java/com/buschmais/jqassistant/plugin/maven3/impl/scanner/MavenProjectScannerPlugin.java#L255-L268
lastaflute/lastaflute
src/main/java/org/lastaflute/web/login/TypicalLoginAssist.java
TypicalLoginAssist.doRememberMe
protected boolean doRememberMe(ID userId, String expireDate, RememberMeLoginSpecifiedOption option) { """ Do actually remember-me for the user. @param userId The ID of the login user, used by identity login. (NotNull) @param expireDate The string expression for expire date of remember-me access token. (NotNull) ...
java
protected boolean doRememberMe(ID userId, String expireDate, RememberMeLoginSpecifiedOption option) { final boolean updateToken = option.isUpdateToken(); final boolean silentLogin = option.isSilentLogin(); if (logger.isDebugEnabled()) { final StringBuilder sb = new StringBuilder(); ...
[ "protected", "boolean", "doRememberMe", "(", "ID", "userId", ",", "String", "expireDate", ",", "RememberMeLoginSpecifiedOption", "option", ")", "{", "final", "boolean", "updateToken", "=", "option", ".", "isUpdateToken", "(", ")", ";", "final", "boolean", "silentL...
Do actually remember-me for the user. @param userId The ID of the login user, used by identity login. (NotNull) @param expireDate The string expression for expire date of remember-me access token. (NotNull) @param option The option of remember-me login specified by caller. (NotNull) @return Is the remember-me success?
[ "Do", "actually", "remember", "-", "me", "for", "the", "user", "." ]
train
https://github.com/lastaflute/lastaflute/blob/17b56dda8322e4c6d79043532c1dda917d6b60a8/src/main/java/org/lastaflute/web/login/TypicalLoginAssist.java#L635-L660
Netflix/zuul
zuul-core/src/main/java/com/netflix/zuul/stats/StatsManager.java
StatsManager.incrementNamedCountingMonitor
protected void incrementNamedCountingMonitor(String name, ConcurrentMap<String, NamedCountingMonitor> map) { """ helper method to create new monitor, place into map, and register wtih Epic, if necessary """ NamedCountingMonitor monitor = map.get(name); if (monitor == null) { monitor...
java
protected void incrementNamedCountingMonitor(String name, ConcurrentMap<String, NamedCountingMonitor> map) { NamedCountingMonitor monitor = map.get(name); if (monitor == null) { monitor = new NamedCountingMonitor(name); NamedCountingMonitor conflict = map.putIfAbsent(name, monito...
[ "protected", "void", "incrementNamedCountingMonitor", "(", "String", "name", ",", "ConcurrentMap", "<", "String", ",", "NamedCountingMonitor", ">", "map", ")", "{", "NamedCountingMonitor", "monitor", "=", "map", ".", "get", "(", "name", ")", ";", "if", "(", "m...
helper method to create new monitor, place into map, and register wtih Epic, if necessary
[ "helper", "method", "to", "create", "new", "monitor", "place", "into", "map", "and", "register", "wtih", "Epic", "if", "necessary" ]
train
https://github.com/Netflix/zuul/blob/01bc777cf05e3522d37c9ed902ae13eb38a19692/zuul-core/src/main/java/com/netflix/zuul/stats/StatsManager.java#L187-L196
forge/furnace
container-api/src/main/java/org/jboss/forge/furnace/util/Strings.java
Strings.trimLeadingCharacter
public static String trimLeadingCharacter(String str, final char leadingCharacter) { """ Trim all occurences of the supplied leading character from the given String. @param str the string to check @param leadingCharacter the leading character to be trimmed @return the trimmed String """ return trimL...
java
public static String trimLeadingCharacter(String str, final char leadingCharacter) { return trimLeadingCharacter(str, new CharacterFilter() { @Override public boolean isCharacterLegal(char character) { return character == leadingCharacter; } }); }
[ "public", "static", "String", "trimLeadingCharacter", "(", "String", "str", ",", "final", "char", "leadingCharacter", ")", "{", "return", "trimLeadingCharacter", "(", "str", ",", "new", "CharacterFilter", "(", ")", "{", "@", "Override", "public", "boolean", "isC...
Trim all occurences of the supplied leading character from the given String. @param str the string to check @param leadingCharacter the leading character to be trimmed @return the trimmed String
[ "Trim", "all", "occurences", "of", "the", "supplied", "leading", "character", "from", "the", "given", "String", "." ]
train
https://github.com/forge/furnace/blob/bbe6deaa3c0d85ba43daa3e2f7d486f2dad21e0a/container-api/src/main/java/org/jboss/forge/furnace/util/Strings.java#L1216-L1226
JM-Lab/utils-java8
src/main/java/kr/jm/utils/datastructure/JMMap.java
JMMap.newFilteredChangedKeyValueWithEntryMap
public static <K, V, NK, NV> Map<NK, NV> newFilteredChangedKeyValueWithEntryMap(Map<K, V> map, Predicate<? super Entry<K, V>> filter, Function<Entry<K, V>, NK> changingKeyFunction, Function<Entry<K, V>, NV> changingValueFunction) { """ New filtered changed key value with ent...
java
public static <K, V, NK, NV> Map<NK, NV> newFilteredChangedKeyValueWithEntryMap(Map<K, V> map, Predicate<? super Entry<K, V>> filter, Function<Entry<K, V>, NK> changingKeyFunction, Function<Entry<K, V>, NV> changingValueFunction) { return getEntryStreamWithFilter(map, fil...
[ "public", "static", "<", "K", ",", "V", ",", "NK", ",", "NV", ">", "Map", "<", "NK", ",", "NV", ">", "newFilteredChangedKeyValueWithEntryMap", "(", "Map", "<", "K", ",", "V", ">", "map", ",", "Predicate", "<", "?", "super", "Entry", "<", "K", ",", ...
New filtered changed key value with entry map map. @param <K> the type parameter @param <V> the type parameter @param <NK> the type parameter @param <NV> the type parameter @param map the map @param filter the filter...
[ "New", "filtered", "changed", "key", "value", "with", "entry", "map", "map", "." ]
train
https://github.com/JM-Lab/utils-java8/blob/9e407b3f28a7990418a1e877229fa8344f4d78a5/src/main/java/kr/jm/utils/datastructure/JMMap.java#L367-L374
apache/incubator-shardingsphere
sharding-proxy/sharding-proxy-backend/src/main/java/org/apache/shardingsphere/shardingproxy/backend/text/TextProtocolBackendHandlerFactory.java
TextProtocolBackendHandlerFactory.newInstance
public static TextProtocolBackendHandler newInstance(final String sql, final BackendConnection backendConnection) { """ Create new instance of text protocol backend handler. @param sql SQL to be executed @param backendConnection backend connection @return instance of text protocol backend handler """ ...
java
public static TextProtocolBackendHandler newInstance(final String sql, final BackendConnection backendConnection) { if (sql.toUpperCase().startsWith(ShardingCTLBackendHandlerFactory.SCTL)) { return ShardingCTLBackendHandlerFactory.newInstance(sql, backendConnection); } // TODO use sq...
[ "public", "static", "TextProtocolBackendHandler", "newInstance", "(", "final", "String", "sql", ",", "final", "BackendConnection", "backendConnection", ")", "{", "if", "(", "sql", ".", "toUpperCase", "(", ")", ".", "startsWith", "(", "ShardingCTLBackendHandlerFactory"...
Create new instance of text protocol backend handler. @param sql SQL to be executed @param backendConnection backend connection @return instance of text protocol backend handler
[ "Create", "new", "instance", "of", "text", "protocol", "backend", "handler", "." ]
train
https://github.com/apache/incubator-shardingsphere/blob/f88fd29fc345dfb31fdce12e9e96cbfa0fd2402d/sharding-proxy/sharding-proxy-backend/src/main/java/org/apache/shardingsphere/shardingproxy/backend/text/TextProtocolBackendHandlerFactory.java#L61-L75
lessthanoptimal/BoofCV
main/boofcv-recognition/src/main/java/boofcv/alg/fiducial/qrcode/QrCodePositionPatternDetector.java
QrCodePositionPatternDetector.process
public void process(T gray, GrayU8 binary ) { """ Detects position patterns inside the image and forms a graph. @param gray Gray scale input image @param binary Thresholed version of gray image. """ configureContourDetector(gray); recycleData(); positionPatterns.reset(); interpolate.setImage(gray); ...
java
public void process(T gray, GrayU8 binary ) { configureContourDetector(gray); recycleData(); positionPatterns.reset(); interpolate.setImage(gray); // detect squares squareDetector.process(gray,binary); long time0 = System.nanoTime(); squaresToPositionList(); long time1 = System.nanoTime(); // Cr...
[ "public", "void", "process", "(", "T", "gray", ",", "GrayU8", "binary", ")", "{", "configureContourDetector", "(", "gray", ")", ";", "recycleData", "(", ")", ";", "positionPatterns", ".", "reset", "(", ")", ";", "interpolate", ".", "setImage", "(", "gray",...
Detects position patterns inside the image and forms a graph. @param gray Gray scale input image @param binary Thresholed version of gray image.
[ "Detects", "position", "patterns", "inside", "the", "image", "and", "forms", "a", "graph", "." ]
train
https://github.com/lessthanoptimal/BoofCV/blob/f01c0243da0ec086285ee722183804d5923bc3ac/main/boofcv-recognition/src/main/java/boofcv/alg/fiducial/qrcode/QrCodePositionPatternDetector.java#L121-L149
alkacon/opencms-core
src-setup/org/opencms/setup/CmsSetupBean.java
CmsSetupBean.backupConfiguration
public void backupConfiguration(String filename, String originalFilename) { """ Restores the opencms.xml either to or from a backup file, depending whether the setup wizard is executed the first time (the backup does not exist) or not (the backup exists). @param filename something like e.g. "opencms.xml" @pa...
java
public void backupConfiguration(String filename, String originalFilename) { // ensure backup folder exists File backupFolder = new File(m_configRfsPath + FOLDER_BACKUP); if (!backupFolder.exists()) { backupFolder.mkdirs(); } // copy file to (or from) backup folder ...
[ "public", "void", "backupConfiguration", "(", "String", "filename", ",", "String", "originalFilename", ")", "{", "// ensure backup folder exists", "File", "backupFolder", "=", "new", "File", "(", "m_configRfsPath", "+", "FOLDER_BACKUP", ")", ";", "if", "(", "!", "...
Restores the opencms.xml either to or from a backup file, depending whether the setup wizard is executed the first time (the backup does not exist) or not (the backup exists). @param filename something like e.g. "opencms.xml" @param originalFilename the configurations real file name, e.g. "opencms.xml.ori"
[ "Restores", "the", "opencms", ".", "xml", "either", "to", "or", "from", "a", "backup", "file", "depending", "whether", "the", "setup", "wizard", "is", "executed", "the", "first", "time", "(", "the", "backup", "does", "not", "exist", ")", "or", "not", "("...
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src-setup/org/opencms/setup/CmsSetupBean.java#L324-L340
fernandospr/javapns-jdk16
src/main/java/javapns/notification/Payload.java
Payload.validateMaximumPayloadSize
private void validateMaximumPayloadSize(int currentPayloadSize) throws PayloadMaxSizeExceededException { """ Validate that the payload does not exceed the maximum size allowed. If the limit is exceeded, a PayloadMaxSizeExceededException is thrown. @param currentPayloadSize the total size of the payload in byte...
java
private void validateMaximumPayloadSize(int currentPayloadSize) throws PayloadMaxSizeExceededException { int maximumPayloadSize = getMaximumPayloadSize(); if (currentPayloadSize > maximumPayloadSize) { throw new PayloadMaxSizeExceededException(maximumPayloadSize, currentPayloadSize); } }
[ "private", "void", "validateMaximumPayloadSize", "(", "int", "currentPayloadSize", ")", "throws", "PayloadMaxSizeExceededException", "{", "int", "maximumPayloadSize", "=", "getMaximumPayloadSize", "(", ")", ";", "if", "(", "currentPayloadSize", ">", "maximumPayloadSize", ...
Validate that the payload does not exceed the maximum size allowed. If the limit is exceeded, a PayloadMaxSizeExceededException is thrown. @param currentPayloadSize the total size of the payload in bytes @throws PayloadMaxSizeExceededException if the payload exceeds the maximum size allowed
[ "Validate", "that", "the", "payload", "does", "not", "exceed", "the", "maximum", "size", "allowed", ".", "If", "the", "limit", "is", "exceeded", "a", "PayloadMaxSizeExceededException", "is", "thrown", "." ]
train
https://github.com/fernandospr/javapns-jdk16/blob/84de6d9328ab01af92f77cc60c4554de02420909/src/main/java/javapns/notification/Payload.java#L249-L254
Stratio/stratio-cassandra
src/java/org/apache/cassandra/hadoop/ConfigHelper.java
ConfigHelper.setInputSlicePredicate
public static void setInputSlicePredicate(Configuration conf, SlicePredicate predicate) { """ Set the predicate that determines what columns will be selected from each row. @param conf Job configuration you are about to run @param predicate """ conf.set(INPUT_PREDICATE_CONFIG, thriftToString(p...
java
public static void setInputSlicePredicate(Configuration conf, SlicePredicate predicate) { conf.set(INPUT_PREDICATE_CONFIG, thriftToString(predicate)); }
[ "public", "static", "void", "setInputSlicePredicate", "(", "Configuration", "conf", ",", "SlicePredicate", "predicate", ")", "{", "conf", ".", "set", "(", "INPUT_PREDICATE_CONFIG", ",", "thriftToString", "(", "predicate", ")", ")", ";", "}" ]
Set the predicate that determines what columns will be selected from each row. @param conf Job configuration you are about to run @param predicate
[ "Set", "the", "predicate", "that", "determines", "what", "columns", "will", "be", "selected", "from", "each", "row", "." ]
train
https://github.com/Stratio/stratio-cassandra/blob/f6416b43ad5309083349ad56266450fa8c6a2106/src/java/org/apache/cassandra/hadoop/ConfigHelper.java#L198-L201
nguillaumin/slick2d-maven
slick2d-core/src/main/java/org/newdawn/slick/Graphics.java
Graphics.drawAnimation
public void drawAnimation(Animation anim, float x, float y) { """ Draw an animation to this graphics context @param anim The animation to be drawn @param x The x position to draw the animation at @param y The y position to draw the animation at """ drawAnimation(anim, x, y, Color.white); }
java
public void drawAnimation(Animation anim, float x, float y) { drawAnimation(anim, x, y, Color.white); }
[ "public", "void", "drawAnimation", "(", "Animation", "anim", ",", "float", "x", ",", "float", "y", ")", "{", "drawAnimation", "(", "anim", ",", "x", ",", "y", ",", "Color", ".", "white", ")", ";", "}" ]
Draw an animation to this graphics context @param anim The animation to be drawn @param x The x position to draw the animation at @param y The y position to draw the animation at
[ "Draw", "an", "animation", "to", "this", "graphics", "context" ]
train
https://github.com/nguillaumin/slick2d-maven/blob/8251f88a0ed6a70e726d2468842455cd1f80893f/slick2d-core/src/main/java/org/newdawn/slick/Graphics.java#L1399-L1401
phax/ph-commons
ph-commons/src/main/java/com/helger/commons/typeconvert/TypeConverter.java
TypeConverter.convertToDouble
public static double convertToDouble (@Nullable final Object aSrcValue, final double dDefault) { """ Convert the passed source value to double @param aSrcValue The source value. May be <code>null</code>. @param dDefault The default value to be returned if an error occurs during type conversion. @return The...
java
public static double convertToDouble (@Nullable final Object aSrcValue, final double dDefault) { final Double aValue = convert (aSrcValue, Double.class, null); return aValue == null ? dDefault : aValue.doubleValue (); }
[ "public", "static", "double", "convertToDouble", "(", "@", "Nullable", "final", "Object", "aSrcValue", ",", "final", "double", "dDefault", ")", "{", "final", "Double", "aValue", "=", "convert", "(", "aSrcValue", ",", "Double", ".", "class", ",", "null", ")",...
Convert the passed source value to double @param aSrcValue The source value. May be <code>null</code>. @param dDefault The default value to be returned if an error occurs during type conversion. @return The converted value. @throws RuntimeException If the converter itself throws an exception @see TypeConverterProvider...
[ "Convert", "the", "passed", "source", "value", "to", "double" ]
train
https://github.com/phax/ph-commons/blob/d28c03565f44a0b804d96028d0969f9bb38c4313/ph-commons/src/main/java/com/helger/commons/typeconvert/TypeConverter.java#L255-L259
UrielCh/ovh-java-sdk
ovh-java-sdk-emailexchange/src/main/java/net/minidev/ovh/api/ApiOvhEmailexchange.java
ApiOvhEmailexchange.organizationName_service_exchangeService_resourceAccount_POST
public OvhTask organizationName_service_exchangeService_resourceAccount_POST(String organizationName, String exchangeService, Boolean addOrganizerToSubject, Boolean allowConflict, Long bookingWindow, Long capacity, Boolean deleteComments, Boolean deleteSubject, String displayName, String location, Long maximumDuration,...
java
public OvhTask organizationName_service_exchangeService_resourceAccount_POST(String organizationName, String exchangeService, Boolean addOrganizerToSubject, Boolean allowConflict, Long bookingWindow, Long capacity, Boolean deleteComments, Boolean deleteSubject, String displayName, String location, Long maximumDuration,...
[ "public", "OvhTask", "organizationName_service_exchangeService_resourceAccount_POST", "(", "String", "organizationName", ",", "String", "exchangeService", ",", "Boolean", "addOrganizerToSubject", ",", "Boolean", "allowConflict", ",", "Long", "bookingWindow", ",", "Long", "cap...
create new resource account in exchange server REST: POST /email/exchange/{organizationName}/service/{exchangeService}/resourceAccount @param bookingWindow [required] maximum number of days in advance that the resource can be reserved @param resourceEmailAddress [required] resource address @param type [required] type ...
[ "create", "new", "resource", "account", "in", "exchange", "server" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-emailexchange/src/main/java/net/minidev/ovh/api/ApiOvhEmailexchange.java#L2542-L2560
Coveros/selenified
src/main/java/com/coveros/selenified/Selenified.java
Selenified.addHeaders
protected static void addHeaders(Selenified clazz, ITestContext context, Map<String, Object> headers) { """ Sets any additional headers for the web services calls for each instance of the test suite being executed. @param clazz - the test suite class, used for making threadsafe storage of application, allowi...
java
protected static void addHeaders(Selenified clazz, ITestContext context, Map<String, Object> headers) { context.setAttribute(clazz.getClass().getName() + "Headers", headers); }
[ "protected", "static", "void", "addHeaders", "(", "Selenified", "clazz", ",", "ITestContext", "context", ",", "Map", "<", "String", ",", "Object", ">", "headers", ")", "{", "context", ".", "setAttribute", "(", "clazz", ".", "getClass", "(", ")", ".", "getN...
Sets any additional headers for the web services calls for each instance of the test suite being executed. @param clazz - the test suite class, used for making threadsafe storage of application, allowing suites to have independent applications under test, run at the same time @param context - the TestNG context asso...
[ "Sets", "any", "additional", "headers", "for", "the", "web", "services", "calls", "for", "each", "instance", "of", "the", "test", "suite", "being", "executed", "." ]
train
https://github.com/Coveros/selenified/blob/396cc1f010dd69eed33cc5061c41253de246a4cd/src/main/java/com/coveros/selenified/Selenified.java#L193-L195
RobotiumTech/robotium
robotium-solo/src/main/java/com/robotium/solo/Waiter.java
Waiter.waitForView
public View waitForView(Object tag, int index, int timeout) { """ Waits for a certain view. @param tag the tag of the view to wait for @param index the index of the {@link View}. {@code 0} if only one is available @param timeout the timeout in milliseconds @return the specified View """ if(timeout == 0...
java
public View waitForView(Object tag, int index, int timeout){ if(timeout == 0){ timeout = Timeout.getSmallTimeout(); } return waitForView(tag, index, timeout, false); }
[ "public", "View", "waitForView", "(", "Object", "tag", ",", "int", "index", ",", "int", "timeout", ")", "{", "if", "(", "timeout", "==", "0", ")", "{", "timeout", "=", "Timeout", ".", "getSmallTimeout", "(", ")", ";", "}", "return", "waitForView", "(",...
Waits for a certain view. @param tag the tag of the view to wait for @param index the index of the {@link View}. {@code 0} if only one is available @param timeout the timeout in milliseconds @return the specified View
[ "Waits", "for", "a", "certain", "view", "." ]
train
https://github.com/RobotiumTech/robotium/blob/75e567c38f26a6a87dc8bef90b3886a20e28d291/robotium-solo/src/main/java/com/robotium/solo/Waiter.java#L431-L436
mercadopago/dx-java
src/main/java/com/mercadopago/net/MPRestClient.java
MPRestClient.getClient
private HttpClient getClient(int retries, int connectionTimeout, int socketTimeout) { """ Returns a DefaultHttpClient instance with retries and timeouts settings If proxy information exists, its setted on the client. @param retries int with the retries for the api request @param connectionTi...
java
private HttpClient getClient(int retries, int connectionTimeout, int socketTimeout) { HttpClient httpClient = new DefaultHttpClient(); HttpParams httpParams = httpClient.getParams(); // Retries if (retries > 0) { DefaultHttpRequestRetryHandler retryHandler = new DefaultHttpR...
[ "private", "HttpClient", "getClient", "(", "int", "retries", ",", "int", "connectionTimeout", ",", "int", "socketTimeout", ")", "{", "HttpClient", "httpClient", "=", "new", "DefaultHttpClient", "(", ")", ";", "HttpParams", "httpParams", "=", "httpClient", ".", "...
Returns a DefaultHttpClient instance with retries and timeouts settings If proxy information exists, its setted on the client. @param retries int with the retries for the api request @param connectionTimeout int with the connection timeout for the api request expressed in milliseconds @param ...
[ "Returns", "a", "DefaultHttpClient", "instance", "with", "retries", "and", "timeouts", "settings", "If", "proxy", "information", "exists", "its", "setted", "on", "the", "client", "." ]
train
https://github.com/mercadopago/dx-java/blob/9df65a6bfb4db0c1fddd7699a5b109643961b03f/src/main/java/com/mercadopago/net/MPRestClient.java#L146-L171
opsgenie/opsgenieclient
sdk-swagger/src/main/java/com/ifountain/opsgenie/client/swagger/api/AlertApi.java
AlertApi.listRecipients
public ListAlertRecipientsResponse listRecipients(String identifier, String identifierType) throws ApiException { """ List Alert Recipients List alert recipients for the given alert identifier @param identifier Identifier of alert which could be alert id, tiny id or alert alias (required) @param identifierType ...
java
public ListAlertRecipientsResponse listRecipients(String identifier, String identifierType) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'identifier' is set if (identifier == null) { throw new ApiException(400, "Missing the required parameter 'identifier' w...
[ "public", "ListAlertRecipientsResponse", "listRecipients", "(", "String", "identifier", ",", "String", "identifierType", ")", "throws", "ApiException", "{", "Object", "localVarPostBody", "=", "null", ";", "// verify the required parameter 'identifier' is set", "if", "(", "i...
List Alert Recipients List alert recipients for the given alert identifier @param identifier Identifier of alert which could be alert id, tiny id or alert alias (required) @param identifierType Type of the identifier that is provided as an in-line parameter. Possible values are &#39;id&#39;, &#39;alias&#39; or &#39;tin...
[ "List", "Alert", "Recipients", "List", "alert", "recipients", "for", "the", "given", "alert", "identifier", "@param", "identifier", "Identifier", "of", "alert", "which", "could", "be", "alert", "id", "tiny", "id", "or", "alert", "alias", "(", "required", ")", ...
train
https://github.com/opsgenie/opsgenieclient/blob/6d94efb16bbc74be189c86e9329af510ac8a048c/sdk-swagger/src/main/java/com/ifountain/opsgenie/client/swagger/api/AlertApi.java#L1349-L1386
raphw/byte-buddy
byte-buddy-dep/src/main/java/net/bytebuddy/matcher/ElementMatchers.java
ElementMatchers.hasDescriptor
public static <T extends ByteCodeElement> ElementMatcher.Junction<T> hasDescriptor(String descriptor) { """ Matches a {@link ByteCodeElement}'s descriptor against a given value. @param descriptor The expected descriptor. @param <T> The type of the matched object. @return A matcher for the given {@code ...
java
public static <T extends ByteCodeElement> ElementMatcher.Junction<T> hasDescriptor(String descriptor) { return new DescriptorMatcher<T>(new StringMatcher(descriptor, StringMatcher.Mode.EQUALS_FULLY)); }
[ "public", "static", "<", "T", "extends", "ByteCodeElement", ">", "ElementMatcher", ".", "Junction", "<", "T", ">", "hasDescriptor", "(", "String", "descriptor", ")", "{", "return", "new", "DescriptorMatcher", "<", "T", ">", "(", "new", "StringMatcher", "(", ...
Matches a {@link ByteCodeElement}'s descriptor against a given value. @param descriptor The expected descriptor. @param <T> The type of the matched object. @return A matcher for the given {@code descriptor}.
[ "Matches", "a", "{", "@link", "ByteCodeElement", "}", "s", "descriptor", "against", "a", "given", "value", "." ]
train
https://github.com/raphw/byte-buddy/blob/4d2dac80efb6bed89367567260f6811c2f712d12/byte-buddy-dep/src/main/java/net/bytebuddy/matcher/ElementMatchers.java#L767-L769
looly/hutool
hutool-poi/src/main/java/cn/hutool/poi/excel/StyleSet.java
StyleSet.setBorder
public StyleSet setBorder(BorderStyle borderSize, IndexedColors colorIndex) { """ 定义所有单元格的边框类型 @param borderSize 边框粗细{@link BorderStyle}枚举 @param colorIndex 颜色的short值 @return this @since 4.0.0 """ StyleUtil.setBorder(this.headCellStyle, borderSize, colorIndex); StyleUtil.setBorder(this.cellStyle, b...
java
public StyleSet setBorder(BorderStyle borderSize, IndexedColors colorIndex) { StyleUtil.setBorder(this.headCellStyle, borderSize, colorIndex); StyleUtil.setBorder(this.cellStyle, borderSize, colorIndex); StyleUtil.setBorder(this.cellStyleForNumber, borderSize, colorIndex); StyleUtil.setBorder(this.cellStyle...
[ "public", "StyleSet", "setBorder", "(", "BorderStyle", "borderSize", ",", "IndexedColors", "colorIndex", ")", "{", "StyleUtil", ".", "setBorder", "(", "this", ".", "headCellStyle", ",", "borderSize", ",", "colorIndex", ")", ";", "StyleUtil", ".", "setBorder", "(...
定义所有单元格的边框类型 @param borderSize 边框粗细{@link BorderStyle}枚举 @param colorIndex 颜色的short值 @return this @since 4.0.0
[ "定义所有单元格的边框类型" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-poi/src/main/java/cn/hutool/poi/excel/StyleSet.java#L98-L104
Impetus/Kundera
src/kundera-cassandra/cassandra-core/src/main/java/com/impetus/client/cassandra/thrift/ThriftClient.java
ThriftClient.executeQuery
@Override public List executeQuery(Class clazz, List<String> relationalField, boolean isNative, String cqlQuery) { """ Query related methods. @param clazz the clazz @param relationalField the relational field @param isNative the is native @param cqlQuery the cql query @return the list """ ...
java
@Override public List executeQuery(Class clazz, List<String> relationalField, boolean isNative, String cqlQuery) { if (clazz == null) { return super.executeScalarQuery(cqlQuery); } return super.executeSelectQuery(clazz, relationalField, dataHandler, isNative, cqlQuery...
[ "@", "Override", "public", "List", "executeQuery", "(", "Class", "clazz", ",", "List", "<", "String", ">", "relationalField", ",", "boolean", "isNative", ",", "String", "cqlQuery", ")", "{", "if", "(", "clazz", "==", "null", ")", "{", "return", "super", ...
Query related methods. @param clazz the clazz @param relationalField the relational field @param isNative the is native @param cqlQuery the cql query @return the list
[ "Query", "related", "methods", "." ]
train
https://github.com/Impetus/Kundera/blob/268958ab1ec09d14ec4d9184f0c8ded7a9158908/src/kundera-cassandra/cassandra-core/src/main/java/com/impetus/client/cassandra/thrift/ThriftClient.java#L1055-L1063
ReactiveX/RxJavaGuava
src/main/java/rx/transformer/GuavaTransformers.java
GuavaTransformers.toImmutableMap
public static <T,K,V> Observable.Transformer<T,ImmutableMap<K,V>> toImmutableMap(final Func1<T,K> keyMapper, final Func1<T,V> valueMapper) { """ Returns a Transformer&lt;T,ImmutableMap&lt;K,V&gt;&gt that maps an Observable&lt;T&gt; to an Observable&lt;ImmutableMap&lt;K,V&gt;&gt><br><br> with a given Func1&lt;T,K&...
java
public static <T,K,V> Observable.Transformer<T,ImmutableMap<K,V>> toImmutableMap(final Func1<T,K> keyMapper, final Func1<T,V> valueMapper) { return new Observable.Transformer<T,ImmutableMap<K,V>>() { @Override public Observable<ImmutableMap<K, V>> call(Observable<T> observable) { ...
[ "public", "static", "<", "T", ",", "K", ",", "V", ">", "Observable", ".", "Transformer", "<", "T", ",", "ImmutableMap", "<", "K", ",", "V", ">", ">", "toImmutableMap", "(", "final", "Func1", "<", "T", ",", "K", ">", "keyMapper", ",", "final", "Func...
Returns a Transformer&lt;T,ImmutableMap&lt;K,V&gt;&gt that maps an Observable&lt;T&gt; to an Observable&lt;ImmutableMap&lt;K,V&gt;&gt><br><br> with a given Func1&lt;T,K&gt; keyMapper and Func1&lt;T,V&gt; valueMapper
[ "Returns", "a", "Transformer&lt", ";", "T", "ImmutableMap&lt", ";", "K", "V&gt", ";", "&gt", "that", "maps", "an", "Observable&lt", ";", "T&gt", ";", "to", "an", "Observable&lt", ";", "ImmutableMap&lt", ";", "K", "V&gt", ";", "&gt", ">", "<br", ">", "<br...
train
https://github.com/ReactiveX/RxJavaGuava/blob/bfb5da6e073364a96da23d57f47c6b706fb733aa/src/main/java/rx/transformer/GuavaTransformers.java#L93-L116
UrielCh/ovh-java-sdk
ovh-java-sdk-emaildomain/src/main/java/net/minidev/ovh/api/ApiOvhEmaildomain.java
ApiOvhEmaildomain.domain_task_mailinglist_id_GET
public OvhTaskMl domain_task_mailinglist_id_GET(String domain, Long id) throws IOException { """ Get this object properties REST: GET /email/domain/{domain}/task/mailinglist/{id} @param domain [required] Name of your domain name @param id [required] """ String qPath = "/email/domain/{domain}/task/mailin...
java
public OvhTaskMl domain_task_mailinglist_id_GET(String domain, Long id) throws IOException { String qPath = "/email/domain/{domain}/task/mailinglist/{id}"; StringBuilder sb = path(qPath, domain, id); String resp = exec(qPath, "GET", sb.toString(), null); return convertTo(resp, OvhTaskMl.class); }
[ "public", "OvhTaskMl", "domain_task_mailinglist_id_GET", "(", "String", "domain", ",", "Long", "id", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/email/domain/{domain}/task/mailinglist/{id}\"", ";", "StringBuilder", "sb", "=", "path", "(", "qPath", "...
Get this object properties REST: GET /email/domain/{domain}/task/mailinglist/{id} @param domain [required] Name of your domain name @param id [required]
[ "Get", "this", "object", "properties" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-emaildomain/src/main/java/net/minidev/ovh/api/ApiOvhEmaildomain.java#L1129-L1134
albfernandez/itext2
src/main/java/com/lowagie/text/pdf/PdfContentByte.java
PdfContentByte.drawTextField
public void drawTextField(float llx, float lly, float urx, float ury) { """ Draws a TextField. @param llx @param lly @param urx @param ury """ if (llx > urx) { float x = llx; llx = urx; urx = x; } if (lly > ury) { float y = lly; lly = ury; ury = y; } // silver rectangle not filled ...
java
public void drawTextField(float llx, float lly, float urx, float ury) { if (llx > urx) { float x = llx; llx = urx; urx = x; } if (lly > ury) { float y = lly; lly = ury; ury = y; } // silver rectangle not filled setColorStroke(new Color(0xC0, 0xC0, 0xC0)); setLineWidth(1); ...
[ "public", "void", "drawTextField", "(", "float", "llx", ",", "float", "lly", ",", "float", "urx", ",", "float", "ury", ")", "{", "if", "(", "llx", ">", "urx", ")", "{", "float", "x", "=", "llx", ";", "llx", "=", "urx", ";", "urx", "=", "x", ";"...
Draws a TextField. @param llx @param lly @param urx @param ury
[ "Draws", "a", "TextField", "." ]
train
https://github.com/albfernandez/itext2/blob/438fc1899367fd13dfdfa8dfdca9a3c1a7783b84/src/main/java/com/lowagie/text/pdf/PdfContentByte.java#L2695-L2734
contentful/contentful-management.java
src/main/java/com/contentful/java/cma/ModuleUiExtensions.java
ModuleUiExtensions.fetchOne
public CMAUiExtension fetchOne(String spaceId, String environmentId, String extensionId) { """ Fetch one extension from the given space. <p> This method will override the configuration specified through {@link CMAClient.Builder#setSpaceId(String)} and will ignore {@link CMAClient.Builder#setEnvironmentId(Strin...
java
public CMAUiExtension fetchOne(String spaceId, String environmentId, String extensionId) { assertNotNull(spaceId, "spaceId"); assertNotNull(environmentId, "spaceId"); assertNotNull(extensionId, "extensionId"); return service.fetchOne(spaceId, environmentId, extensionId).blockingFirst(); }
[ "public", "CMAUiExtension", "fetchOne", "(", "String", "spaceId", ",", "String", "environmentId", ",", "String", "extensionId", ")", "{", "assertNotNull", "(", "spaceId", ",", "\"spaceId\"", ")", ";", "assertNotNull", "(", "environmentId", ",", "\"spaceId\"", ")",...
Fetch one extension from the given space. <p> This method will override the configuration specified through {@link CMAClient.Builder#setSpaceId(String)} and will ignore {@link CMAClient.Builder#setEnvironmentId(String)}. @param spaceId the id of the space this is valid on. @param environmentId the id of the envi...
[ "Fetch", "one", "extension", "from", "the", "given", "space", ".", "<p", ">", "This", "method", "will", "override", "the", "configuration", "specified", "through", "{", "@link", "CMAClient", ".", "Builder#setSpaceId", "(", "String", ")", "}", "and", "will", ...
train
https://github.com/contentful/contentful-management.java/blob/ca310fb9ea9577fcff0ca57949ab7c2315fa2534/src/main/java/com/contentful/java/cma/ModuleUiExtensions.java#L91-L97
geomajas/geomajas-project-client-gwt
client/src/main/java/org/geomajas/gwt/client/gfx/context/SvgGraphicsContext.java
SvgGraphicsContext.drawCircle
public void drawCircle(Object parent, String name, Coordinate position, double radius, ShapeStyle style) { """ Draw a circle on the <code>GraphicsContext</code>. @param parent parent group object @param name The circle's name. @param position The center position as a coordinate. @param radius The circle'...
java
public void drawCircle(Object parent, String name, Coordinate position, double radius, ShapeStyle style) { if (isAttached()) { Element circle = helper.createOrUpdateElement(parent, name, "circle", style); Dom.setElementAttribute(circle, "cx", Integer.toString((int) position.getX())); Dom.setElementAttribute(...
[ "public", "void", "drawCircle", "(", "Object", "parent", ",", "String", "name", ",", "Coordinate", "position", ",", "double", "radius", ",", "ShapeStyle", "style", ")", "{", "if", "(", "isAttached", "(", ")", ")", "{", "Element", "circle", "=", "helper", ...
Draw a circle on the <code>GraphicsContext</code>. @param parent parent group object @param name The circle's name. @param position The center position as a coordinate. @param radius The circle's radius. @param style The styling object by which the circle should be drawn.
[ "Draw", "a", "circle", "on", "the", "<code", ">", "GraphicsContext<", "/", "code", ">", "." ]
train
https://github.com/geomajas/geomajas-project-client-gwt/blob/1c1adc48deb192ed825265eebcc74d70bbf45670/client/src/main/java/org/geomajas/gwt/client/gfx/context/SvgGraphicsContext.java#L136-L143
line/armeria
core/src/main/java/com/linecorp/armeria/client/ClientOptions.java
ClientOptions.of
public static ClientOptions of(ClientOptions baseOptions, ClientOptionValue<?>... options) { """ Merges the specified {@link ClientOptions} and {@link ClientOptionValue}s. @return the merged {@link ClientOptions} """ // TODO(trustin): Reduce the cost of creating a derived ClientOptions. requ...
java
public static ClientOptions of(ClientOptions baseOptions, ClientOptionValue<?>... options) { // TODO(trustin): Reduce the cost of creating a derived ClientOptions. requireNonNull(baseOptions, "baseOptions"); requireNonNull(options, "options"); if (options.length == 0) { retur...
[ "public", "static", "ClientOptions", "of", "(", "ClientOptions", "baseOptions", ",", "ClientOptionValue", "<", "?", ">", "...", "options", ")", "{", "// TODO(trustin): Reduce the cost of creating a derived ClientOptions.", "requireNonNull", "(", "baseOptions", ",", "\"baseO...
Merges the specified {@link ClientOptions} and {@link ClientOptionValue}s. @return the merged {@link ClientOptions}
[ "Merges", "the", "specified", "{", "@link", "ClientOptions", "}", "and", "{", "@link", "ClientOptionValue", "}", "s", "." ]
train
https://github.com/line/armeria/blob/67d29e019fd35a35f89c45cc8f9119ff9b12b44d/core/src/main/java/com/linecorp/armeria/client/ClientOptions.java#L110-L118
gmessner/gitlab4j-api
src/main/java/org/gitlab4j/api/EpicsApi.java
EpicsApi.createEpic
public Epic createEpic(Object groupIdOrPath, Epic epic) throws GitLabApiException { """ Creates a new epic using the information contained in the provided Epic instance. Only the following fields from the Epic instance are used: <pre><code> title - the title of the epic (required) labels - comma separated lis...
java
public Epic createEpic(Object groupIdOrPath, Epic epic) throws GitLabApiException { Form formData = new GitLabApiForm() .withParam("title", epic.getTitle(), true) .withParam("labels", epic.getLabels()) .withParam("description", epic.getDescription()) ...
[ "public", "Epic", "createEpic", "(", "Object", "groupIdOrPath", ",", "Epic", "epic", ")", "throws", "GitLabApiException", "{", "Form", "formData", "=", "new", "GitLabApiForm", "(", ")", ".", "withParam", "(", "\"title\"", ",", "epic", ".", "getTitle", "(", "...
Creates a new epic using the information contained in the provided Epic instance. Only the following fields from the Epic instance are used: <pre><code> title - the title of the epic (required) labels - comma separated list of labels (optional) description - the description of the epic (optional) startDate - the start...
[ "Creates", "a", "new", "epic", "using", "the", "information", "contained", "in", "the", "provided", "Epic", "instance", ".", "Only", "the", "following", "fields", "from", "the", "Epic", "instance", "are", "used", ":", "<pre", ">", "<code", ">", "title", "-...
train
https://github.com/gmessner/gitlab4j-api/blob/ab045070abac0a8f4ccbf17b5ed9bfdef5723eed/src/main/java/org/gitlab4j/api/EpicsApi.java#L260-L270
Carbonado/Carbonado
src/main/java/com/amazon/carbonado/raw/KeyDecoder.java
KeyDecoder.decodeLongObjDesc
public static Long decodeLongObjDesc(byte[] src, int srcOffset) throws CorruptEncodingException { """ Decodes a signed Long object from exactly 1 or 9 bytes, as encoded for descending order. If null is returned, then 1 byte was read. @param src source of encoded bytes @param srcOffset offset into sou...
java
public static Long decodeLongObjDesc(byte[] src, int srcOffset) throws CorruptEncodingException { try { int b = src[srcOffset]; if (b == NULL_BYTE_HIGH || b == NULL_BYTE_LOW) { return null; } return decodeLongDesc(src, srcOffset...
[ "public", "static", "Long", "decodeLongObjDesc", "(", "byte", "[", "]", "src", ",", "int", "srcOffset", ")", "throws", "CorruptEncodingException", "{", "try", "{", "int", "b", "=", "src", "[", "srcOffset", "]", ";", "if", "(", "b", "==", "NULL_BYTE_HIGH", ...
Decodes a signed Long object from exactly 1 or 9 bytes, as encoded for descending order. If null is returned, then 1 byte was read. @param src source of encoded bytes @param srcOffset offset into source array @return signed Long object or null
[ "Decodes", "a", "signed", "Long", "object", "from", "exactly", "1", "or", "9", "bytes", "as", "encoded", "for", "descending", "order", ".", "If", "null", "is", "returned", "then", "1", "byte", "was", "read", "." ]
train
https://github.com/Carbonado/Carbonado/blob/eee29b365a61c8f03e1a1dc6bed0692e6b04b1db/src/main/java/com/amazon/carbonado/raw/KeyDecoder.java#L94-L106
aws/aws-sdk-java
aws-java-sdk-kms/src/main/java/com/amazonaws/services/kms/model/GrantConstraints.java
GrantConstraints.withEncryptionContextEquals
public GrantConstraints withEncryptionContextEquals(java.util.Map<String, String> encryptionContextEquals) { """ <p> A list of key-value pairs that must be present in the encryption context of certain subsequent operations that the grant allows. When certain subsequent operations allowed by the grant include enc...
java
public GrantConstraints withEncryptionContextEquals(java.util.Map<String, String> encryptionContextEquals) { setEncryptionContextEquals(encryptionContextEquals); return this; }
[ "public", "GrantConstraints", "withEncryptionContextEquals", "(", "java", ".", "util", ".", "Map", "<", "String", ",", "String", ">", "encryptionContextEquals", ")", "{", "setEncryptionContextEquals", "(", "encryptionContextEquals", ")", ";", "return", "this", ";", ...
<p> A list of key-value pairs that must be present in the encryption context of certain subsequent operations that the grant allows. When certain subsequent operations allowed by the grant include encryption context that matches this list, the grant allows the operation. Otherwise, the grant does not allow the operatio...
[ "<p", ">", "A", "list", "of", "key", "-", "value", "pairs", "that", "must", "be", "present", "in", "the", "encryption", "context", "of", "certain", "subsequent", "operations", "that", "the", "grant", "allows", ".", "When", "certain", "subsequent", "operation...
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-kms/src/main/java/com/amazonaws/services/kms/model/GrantConstraints.java#L195-L198
apache/groovy
src/main/java/org/codehaus/groovy/runtime/DefaultGroovyMethods.java
DefaultGroovyMethods.findAll
public static Collection findAll(Object self, Closure closure) { """ Finds all items matching the closure condition. @param self an Object with an Iterator returning its values @param closure a closure condition @return a List of the values found @since 1.6.0 """ List answer = new ArrayList();...
java
public static Collection findAll(Object self, Closure closure) { List answer = new ArrayList(); Iterator iter = InvokerHelper.asIterator(self); return findAll(closure, answer, iter); }
[ "public", "static", "Collection", "findAll", "(", "Object", "self", ",", "Closure", "closure", ")", "{", "List", "answer", "=", "new", "ArrayList", "(", ")", ";", "Iterator", "iter", "=", "InvokerHelper", ".", "asIterator", "(", "self", ")", ";", "return",...
Finds all items matching the closure condition. @param self an Object with an Iterator returning its values @param closure a closure condition @return a List of the values found @since 1.6.0
[ "Finds", "all", "items", "matching", "the", "closure", "condition", "." ]
train
https://github.com/apache/groovy/blob/71cf20addb611bb8d097a59e395fd20bc7f31772/src/main/java/org/codehaus/groovy/runtime/DefaultGroovyMethods.java#L4877-L4881
apache/incubator-shardingsphere
sharding-core/sharding-core-parse/sharding-core-parse-common/src/main/java/org/apache/shardingsphere/core/parse/antlr/extractor/util/ExtractorUtils.java
ExtractorUtils.getFirstChildNode
public static ParserRuleContext getFirstChildNode(final ParserRuleContext node, final RuleName ruleName) { """ Get first child node. @param node start node @param ruleName rule name @return matched node """ Optional<ParserRuleContext> result = findFirstChildNode(node, ruleName); Preconditi...
java
public static ParserRuleContext getFirstChildNode(final ParserRuleContext node, final RuleName ruleName) { Optional<ParserRuleContext> result = findFirstChildNode(node, ruleName); Preconditions.checkState(result.isPresent()); return result.get(); }
[ "public", "static", "ParserRuleContext", "getFirstChildNode", "(", "final", "ParserRuleContext", "node", ",", "final", "RuleName", "ruleName", ")", "{", "Optional", "<", "ParserRuleContext", ">", "result", "=", "findFirstChildNode", "(", "node", ",", "ruleName", ")"...
Get first child node. @param node start node @param ruleName rule name @return matched node
[ "Get", "first", "child", "node", "." ]
train
https://github.com/apache/incubator-shardingsphere/blob/f88fd29fc345dfb31fdce12e9e96cbfa0fd2402d/sharding-core/sharding-core-parse/sharding-core-parse-common/src/main/java/org/apache/shardingsphere/core/parse/antlr/extractor/util/ExtractorUtils.java#L46-L50
alkacon/opencms-core
src/org/opencms/xml/containerpage/CmsXmlGroupContainerFactory.java
CmsXmlGroupContainerFactory.getCache
private static CmsXmlGroupContainer getCache(CmsObject cms, CmsResource resource, boolean keepEncoding) { """ Returns the cached group container.<p> @param cms the cms context @param resource the group container resource @param keepEncoding if to keep the encoding while unmarshalling @return the cached gro...
java
private static CmsXmlGroupContainer getCache(CmsObject cms, CmsResource resource, boolean keepEncoding) { if (resource instanceof I_CmsHistoryResource) { return null; } return getCache().getCacheGroupContainer( getCache().getCacheKey(resource.getStructureId(), keepEncodi...
[ "private", "static", "CmsXmlGroupContainer", "getCache", "(", "CmsObject", "cms", ",", "CmsResource", "resource", ",", "boolean", "keepEncoding", ")", "{", "if", "(", "resource", "instanceof", "I_CmsHistoryResource", ")", "{", "return", "null", ";", "}", "return",...
Returns the cached group container.<p> @param cms the cms context @param resource the group container resource @param keepEncoding if to keep the encoding while unmarshalling @return the cached group container, or <code>null</code> if not found
[ "Returns", "the", "cached", "group", "container", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/xml/containerpage/CmsXmlGroupContainerFactory.java#L401-L409
deeplearning4j/deeplearning4j
nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/org/nd4j/linalg/indexing/BooleanIndexing.java
BooleanIndexing.assignIf
public static void assignIf(@NonNull INDArray to, @NonNull INDArray from, @NonNull Condition condition) { """ This method does element-wise comparison for 2 equal-sized matrices, for each element that matches Condition. To is the array to apply the indexing to from is a condition mask array (0 or 1). This woul...
java
public static void assignIf(@NonNull INDArray to, @NonNull INDArray from, @NonNull Condition condition) { if (!(condition instanceof BaseCondition)) throw new UnsupportedOperationException("Only static Conditions are supported"); if (to.length() != from.length()) throw new Illeg...
[ "public", "static", "void", "assignIf", "(", "@", "NonNull", "INDArray", "to", ",", "@", "NonNull", "INDArray", "from", ",", "@", "NonNull", "Condition", "condition", ")", "{", "if", "(", "!", "(", "condition", "instanceof", "BaseCondition", ")", ")", "thr...
This method does element-wise comparison for 2 equal-sized matrices, for each element that matches Condition. To is the array to apply the indexing to from is a condition mask array (0 or 1). This would come from the output of a bit masking method like: {@link INDArray#gt(Number)},{@link INDArray#gte(Number)}, {@link I...
[ "This", "method", "does", "element", "-", "wise", "comparison", "for", "2", "equal", "-", "sized", "matrices", "for", "each", "element", "that", "matches", "Condition", ".", "To", "is", "the", "array", "to", "apply", "the", "indexing", "to", "from", "is", ...
train
https://github.com/deeplearning4j/deeplearning4j/blob/effce52f2afd7eeb53c5bcca699fcd90bd06822f/nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/org/nd4j/linalg/indexing/BooleanIndexing.java#L156-L164
alkacon/opencms-core
src/org/opencms/file/wrapper/A_CmsResourceExtensionWrapper.java
A_CmsResourceExtensionWrapper.getResource
private CmsResource getResource(CmsObject cms, String resourcename) { """ Trys to read the resourcename after removing the file extension and return the resource if the type id is correct.<p> @param cms the initialized CmsObject @param resourcename the name of the resource to read @return the resource or n...
java
private CmsResource getResource(CmsObject cms, String resourcename) { return getResource(cms, resourcename, CmsResourceFilter.DEFAULT); }
[ "private", "CmsResource", "getResource", "(", "CmsObject", "cms", ",", "String", "resourcename", ")", "{", "return", "getResource", "(", "cms", ",", "resourcename", ",", "CmsResourceFilter", ".", "DEFAULT", ")", ";", "}" ]
Trys to read the resourcename after removing the file extension and return the resource if the type id is correct.<p> @param cms the initialized CmsObject @param resourcename the name of the resource to read @return the resource or null if not found
[ "Trys", "to", "read", "the", "resourcename", "after", "removing", "the", "file", "extension", "and", "return", "the", "resource", "if", "the", "type", "id", "is", "correct", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/file/wrapper/A_CmsResourceExtensionWrapper.java#L320-L323
jenkinsci/jenkins
core/src/main/java/hudson/tools/DownloadFromUrlInstaller.java
DownloadFromUrlInstaller.isUpToDate
protected boolean isUpToDate(FilePath expectedLocation, Installable i) throws IOException, InterruptedException { """ Checks if the specified expected location already contains the installed version of the tool. This check needs to run fairly efficiently. The current implementation uses the source URL of {@link...
java
protected boolean isUpToDate(FilePath expectedLocation, Installable i) throws IOException, InterruptedException { FilePath marker = expectedLocation.child(".installedFrom"); return marker.exists() && marker.readToString().equals(i.url); }
[ "protected", "boolean", "isUpToDate", "(", "FilePath", "expectedLocation", ",", "Installable", "i", ")", "throws", "IOException", ",", "InterruptedException", "{", "FilePath", "marker", "=", "expectedLocation", ".", "child", "(", "\".installedFrom\"", ")", ";", "ret...
Checks if the specified expected location already contains the installed version of the tool. This check needs to run fairly efficiently. The current implementation uses the source URL of {@link Installable}, based on the assumption that released bits do not change its content.
[ "Checks", "if", "the", "specified", "expected", "location", "already", "contains", "the", "installed", "version", "of", "the", "tool", "." ]
train
https://github.com/jenkinsci/jenkins/blob/44c4d3989232082c254d27ae360aa810669f44b7/core/src/main/java/hudson/tools/DownloadFromUrlInstaller.java#L44-L47
bluelinelabs/Conductor
conductor/src/main/java/com/bluelinelabs/conductor/changehandler/SharedElementTransitionChangeHandler.java
SharedElementTransitionChangeHandler.addSharedElement
protected final void addSharedElement(@NonNull String fromName, @NonNull String toName) { """ Used to register an element that will take part in the shared element transition. Maps the name used in the "from" view to the name used in the "to" view if they are not the same. @param fromName The transition name u...
java
protected final void addSharedElement(@NonNull String fromName, @NonNull String toName) { sharedElementNames.put(fromName, toName); }
[ "protected", "final", "void", "addSharedElement", "(", "@", "NonNull", "String", "fromName", ",", "@", "NonNull", "String", "toName", ")", "{", "sharedElementNames", ".", "put", "(", "fromName", ",", "toName", ")", ";", "}" ]
Used to register an element that will take part in the shared element transition. Maps the name used in the "from" view to the name used in the "to" view if they are not the same. @param fromName The transition name used in the "from" view @param toName The transition name used in the "to" view
[ "Used", "to", "register", "an", "element", "that", "will", "take", "part", "in", "the", "shared", "element", "transition", ".", "Maps", "the", "name", "used", "in", "the", "from", "view", "to", "the", "name", "used", "in", "the", "to", "view", "if", "t...
train
https://github.com/bluelinelabs/Conductor/blob/94c9121bb16f93b481954513a8e3905846829fb2/conductor/src/main/java/com/bluelinelabs/conductor/changehandler/SharedElementTransitionChangeHandler.java#L563-L565
imsweb/seerapi-client-java
src/main/java/com/imsweb/seerapi/client/staging/SchemaLookup.java
SchemaLookup.setInput
public void setInput(String key, String value) { """ Set the value of a single input. @param key key of input @param value value of input """ if (getAllowedKeys() != null && !getAllowedKeys().contains(key)) throw new IllegalStateException("The input key " + key + " is not allowed for look...
java
public void setInput(String key, String value) { if (getAllowedKeys() != null && !getAllowedKeys().contains(key)) throw new IllegalStateException("The input key " + key + " is not allowed for lookups"); _inputs.put(key, value); }
[ "public", "void", "setInput", "(", "String", "key", ",", "String", "value", ")", "{", "if", "(", "getAllowedKeys", "(", ")", "!=", "null", "&&", "!", "getAllowedKeys", "(", ")", ".", "contains", "(", "key", ")", ")", "throw", "new", "IllegalStateExceptio...
Set the value of a single input. @param key key of input @param value value of input
[ "Set", "the", "value", "of", "a", "single", "input", "." ]
train
https://github.com/imsweb/seerapi-client-java/blob/04f509961c3a5ece7b232ecb8d8cb8f89d810a85/src/main/java/com/imsweb/seerapi/client/staging/SchemaLookup.java#L69-L74
segmentio/analytics-android
analytics/src/main/java/com/segment/analytics/Options.java
Options.setIntegration
public Options setIntegration(Analytics.BundledIntegration bundledIntegration, boolean enabled) { """ Sets whether an action will be sent to the target integration. Same as {@link #setIntegration(String, boolean)} but type safe for bundled integrations. @param bundledIntegration The target integration @param ...
java
public Options setIntegration(Analytics.BundledIntegration bundledIntegration, boolean enabled) { setIntegration(bundledIntegration.key, enabled); return this; }
[ "public", "Options", "setIntegration", "(", "Analytics", ".", "BundledIntegration", "bundledIntegration", ",", "boolean", "enabled", ")", "{", "setIntegration", "(", "bundledIntegration", ".", "key", ",", "enabled", ")", ";", "return", "this", ";", "}" ]
Sets whether an action will be sent to the target integration. Same as {@link #setIntegration(String, boolean)} but type safe for bundled integrations. @param bundledIntegration The target integration @param enabled <code>true</code> for enabled, <code>false</code> for disabled @return This options object for chaining...
[ "Sets", "whether", "an", "action", "will", "be", "sent", "to", "the", "target", "integration", ".", "Same", "as", "{", "@link", "#setIntegration", "(", "String", "boolean", ")", "}", "but", "type", "safe", "for", "bundled", "integrations", "." ]
train
https://github.com/segmentio/analytics-android/blob/93c7d5bb09b593440a2347a6089db3e9f74012da/analytics/src/main/java/com/segment/analytics/Options.java#L88-L91
ngageoint/geopackage-core-java
src/main/java/mil/nga/geopackage/db/GeoPackageCoreConnection.java
GeoPackageCoreConnection.addColumn
public void addColumn(String tableName, String columnName, String columnDef) { """ Add a new column to the table @param tableName table name @param columnName column name @param columnDef column definition @since 1.1.8 """ execSQL("ALTER TABLE " + CoreSQLUtils.quoteWrap(tableName) + " ADD COLUMN...
java
public void addColumn(String tableName, String columnName, String columnDef) { execSQL("ALTER TABLE " + CoreSQLUtils.quoteWrap(tableName) + " ADD COLUMN " + CoreSQLUtils.quoteWrap(columnName) + " " + columnDef + ";"); }
[ "public", "void", "addColumn", "(", "String", "tableName", ",", "String", "columnName", ",", "String", "columnDef", ")", "{", "execSQL", "(", "\"ALTER TABLE \"", "+", "CoreSQLUtils", ".", "quoteWrap", "(", "tableName", ")", "+", "\" ADD COLUMN \"", "+", "CoreSQL...
Add a new column to the table @param tableName table name @param columnName column name @param columnDef column definition @since 1.1.8
[ "Add", "a", "new", "column", "to", "the", "table" ]
train
https://github.com/ngageoint/geopackage-core-java/blob/6431c3b041a45b7f3802904ea4156b4082a72daa/src/main/java/mil/nga/geopackage/db/GeoPackageCoreConnection.java#L158-L162
RoaringBitmap/RoaringBitmap
roaringbitmap/src/main/java/org/roaringbitmap/Util.java
Util.cardinalityInBitmapRange
public static int cardinalityInBitmapRange(long[] bitmap, int start, int end) { """ Hamming weight of the bitset in the range start, start+1,..., end-1 @param bitmap array of words representing a bitset @param start first index (inclusive) @param end last index (exclusive) @return the hamming weight of th...
java
public static int cardinalityInBitmapRange(long[] bitmap, int start, int end) { if (start >= end) { return 0; } int firstword = start / 64; int endword = (end - 1) / 64; if (firstword == endword) { return Long.bitCount(bitmap[firstword] & ( (~0L << start) & (~0L >>> -end) )); } i...
[ "public", "static", "int", "cardinalityInBitmapRange", "(", "long", "[", "]", "bitmap", ",", "int", "start", ",", "int", "end", ")", "{", "if", "(", "start", ">=", "end", ")", "{", "return", "0", ";", "}", "int", "firstword", "=", "start", "/", "64",...
Hamming weight of the bitset in the range start, start+1,..., end-1 @param bitmap array of words representing a bitset @param start first index (inclusive) @param end last index (exclusive) @return the hamming weight of the corresponding range
[ "Hamming", "weight", "of", "the", "bitset", "in", "the", "range", "start", "start", "+", "1", "...", "end", "-", "1" ]
train
https://github.com/RoaringBitmap/RoaringBitmap/blob/b26fd0a1330fd4d2877f4d74feb69ceb812e9efa/roaringbitmap/src/main/java/org/roaringbitmap/Util.java#L337-L352
xhsun/gw2wrapper
src/main/java/me/xhsun/guildwars2wrapper/AsynchronousRequest.java
AsynchronousRequest.getAllContinentSectorID
public void getAllContinentSectorID(int continentID, int floorID, int regionID, int mapID, Callback<List<Integer>> callback) throws NullPointerException { """ For more info on continents API go <a href="https://wiki.guildwars2.com/wiki/API:2/continents">here</a><br/> Give user the access to {@link Callback#onResp...
java
public void getAllContinentSectorID(int continentID, int floorID, int regionID, int mapID, Callback<List<Integer>> callback) throws NullPointerException { gw2API.getAllContinentSectorIDs(Integer.toString(continentID), Integer.toString(floorID), Integer.toString(regionID), Integer.toString(mapID)).enqueue(callback); ...
[ "public", "void", "getAllContinentSectorID", "(", "int", "continentID", ",", "int", "floorID", ",", "int", "regionID", ",", "int", "mapID", ",", "Callback", "<", "List", "<", "Integer", ">", ">", "callback", ")", "throws", "NullPointerException", "{", "gw2API"...
For more info on continents API go <a href="https://wiki.guildwars2.com/wiki/API:2/continents">here</a><br/> Give user the access to {@link Callback#onResponse(Call, Response)} and {@link Callback#onFailure(Call, Throwable)} methods for custom interactions @param continentID {@link Continent#id} @param floorID {@l...
[ "For", "more", "info", "on", "continents", "API", "go", "<a", "href", "=", "https", ":", "//", "wiki", ".", "guildwars2", ".", "com", "/", "wiki", "/", "API", ":", "2", "/", "continents", ">", "here<", "/", "a", ">", "<br", "/", ">", "Give", "use...
train
https://github.com/xhsun/gw2wrapper/blob/c8a43b51f363b032074fb152ee6efe657e33e525/src/main/java/me/xhsun/guildwars2wrapper/AsynchronousRequest.java#L1142-L1144
ModeShape/modeshape
connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java
CmisConnector.cmisDocument
public Document cmisDocument( CmisObject cmisObject ) { """ Translates cmis document object to JCR node. @param cmisObject cmis document node @return JCR node document. """ org.apache.chemistry.opencmis.client.api.Document doc = (org.apache.chemistry.opencmis.client.api.Document)cmisObject; ...
java
public Document cmisDocument( CmisObject cmisObject ) { org.apache.chemistry.opencmis.client.api.Document doc = (org.apache.chemistry.opencmis.client.api.Document)cmisObject; DocumentWriter writer = newDocument(ObjectId.toString(ObjectId.Type.OBJECT, doc.getId())); ObjectType objectType = cmisO...
[ "public", "Document", "cmisDocument", "(", "CmisObject", "cmisObject", ")", "{", "org", ".", "apache", ".", "chemistry", ".", "opencmis", ".", "client", ".", "api", ".", "Document", "doc", "=", "(", "org", ".", "apache", ".", "chemistry", ".", "opencmis", ...
Translates cmis document object to JCR node. @param cmisObject cmis document node @return JCR node document.
[ "Translates", "cmis", "document", "object", "to", "JCR", "node", "." ]
train
https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/connectors/modeshape-connector-cmis/src/main/java/org/modeshape/connector/cmis/CmisConnector.java#L780-L809
fozziethebeat/S-Space
src/main/java/edu/ucla/sspace/matrix/AtomicGrowingSparseHashMatrix.java
AtomicGrowingSparseHashMatrix.lockRow
private void lockRow(int row, int colsToLock) { """ Locks all the column entries for this row, thereby preventing write or read access to the values. Note that the number of columns to lock <b>must</b> be the same value used with {@link #unlockRow(int,int)}, otherwise the unlock may potentially unlock matrix e...
java
private void lockRow(int row, int colsToLock) { // Put in an entry for all the row's columns for (int col = 0; col < colsToLock; ++col) { Entry e = new Entry(row, col); // Spin waiting for the entry to be unlocked while (lockedEntries.putIfAbsent(e, new Object()) != n...
[ "private", "void", "lockRow", "(", "int", "row", ",", "int", "colsToLock", ")", "{", "// Put in an entry for all the row's columns", "for", "(", "int", "col", "=", "0", ";", "col", "<", "colsToLock", ";", "++", "col", ")", "{", "Entry", "e", "=", "new", ...
Locks all the column entries for this row, thereby preventing write or read access to the values. Note that the number of columns to lock <b>must</b> be the same value used with {@link #unlockRow(int,int)}, otherwise the unlock may potentially unlock matrix entries associated with this lock call. @param row the row t...
[ "Locks", "all", "the", "column", "entries", "for", "this", "row", "thereby", "preventing", "write", "or", "read", "access", "to", "the", "values", ".", "Note", "that", "the", "number", "of", "columns", "to", "lock", "<b", ">", "must<", "/", "b", ">", "...
train
https://github.com/fozziethebeat/S-Space/blob/a608102737dfd3d59038a9ead33fe60356bc6029/src/main/java/edu/ucla/sspace/matrix/AtomicGrowingSparseHashMatrix.java#L359-L367
sstrickx/yahoofinance-api
src/main/java/yahoofinance/YahooFinance.java
YahooFinance.get
public static Stock get(String symbol, Calendar from, Interval interval) throws IOException { """ Sends a request with the historical quotes included starting from the specified {@link Calendar} date at the specified interval. Returns null if the data can't be retrieved from Yahoo Finance. @param symbol ...
java
public static Stock get(String symbol, Calendar from, Interval interval) throws IOException { return YahooFinance.get(symbol, from, HistQuotesRequest.DEFAULT_TO, interval); }
[ "public", "static", "Stock", "get", "(", "String", "symbol", ",", "Calendar", "from", ",", "Interval", "interval", ")", "throws", "IOException", "{", "return", "YahooFinance", ".", "get", "(", "symbol", ",", "from", ",", "HistQuotesRequest", ".", "DEFAULT_TO",...
Sends a request with the historical quotes included starting from the specified {@link Calendar} date at the specified interval. Returns null if the data can't be retrieved from Yahoo Finance. @param symbol the symbol of the stock for which you want to retrieve information @param from start date of the...
[ "Sends", "a", "request", "with", "the", "historical", "quotes", "included", "starting", "from", "the", "specified", "{", "@link", "Calendar", "}", "date", "at", "the", "specified", "interval", ".", "Returns", "null", "if", "the", "data", "can", "t", "be", ...
train
https://github.com/sstrickx/yahoofinance-api/blob/2766ba52fc5cccf9b4da5c06423d68059cf0a6e6/src/main/java/yahoofinance/YahooFinance.java#L143-L145
doanduyhai/Achilles
achilles-core/src/main/java/info/archinnov/achilles/internals/metamodel/MapProperty.java
MapProperty.encodeSingleKeyElement
public KEYTO encodeSingleKeyElement(KEYFROM javaValue, Optional<CassandraOptions> cassandraOptions) { """ Encode the single key element of the map to a CQL-compatible value using Achilles codec system and a CassandraOptions containing a runtime SchemaNameProvider. Use the <br/> <br/> <pre class="code"><code cl...
java
public KEYTO encodeSingleKeyElement(KEYFROM javaValue, Optional<CassandraOptions> cassandraOptions) { return keyProperty.encodeFromRaw(javaValue, cassandraOptions); }
[ "public", "KEYTO", "encodeSingleKeyElement", "(", "KEYFROM", "javaValue", ",", "Optional", "<", "CassandraOptions", ">", "cassandraOptions", ")", "{", "return", "keyProperty", ".", "encodeFromRaw", "(", "javaValue", ",", "cassandraOptions", ")", ";", "}" ]
Encode the single key element of the map to a CQL-compatible value using Achilles codec system and a CassandraOptions containing a runtime SchemaNameProvider. Use the <br/> <br/> <pre class="code"><code class="java"> CassandraOptions.withSchemaNameProvider(SchemaNameProvider provider) </code></pre> <br/> static method ...
[ "Encode", "the", "single", "key", "element", "of", "the", "map", "to", "a", "CQL", "-", "compatible", "value", "using", "Achilles", "codec", "system", "and", "a", "CassandraOptions", "containing", "a", "runtime", "SchemaNameProvider", ".", "Use", "the", "<br",...
train
https://github.com/doanduyhai/Achilles/blob/8281c33100e72c993e570592ae1a5306afac6813/achilles-core/src/main/java/info/archinnov/achilles/internals/metamodel/MapProperty.java#L106-L108