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
huangp/entityunit
src/main/java/com/github/huangp/entityunit/maker/PreferredValueMakersRegistry.java
PreferredValueMakersRegistry.addFieldOrPropertyMaker
public PreferredValueMakersRegistry addFieldOrPropertyMaker(Class ownerType, String propertyName, Maker<?> maker) { """ Add a field/property maker to a class type. i.e. with: <pre> {@code Class Person { String name } } </pre> You could define a custom maker for name field as (Person.class, "name", myNam...
java
public PreferredValueMakersRegistry addFieldOrPropertyMaker(Class ownerType, String propertyName, Maker<?> maker) { Preconditions.checkNotNull(ownerType); Preconditions.checkNotNull(propertyName); makers.put(Matchers.equalTo(String.format(Settable.FULL_NAME_FORMAT, ownerType.getName(), propertyN...
[ "public", "PreferredValueMakersRegistry", "addFieldOrPropertyMaker", "(", "Class", "ownerType", ",", "String", "propertyName", ",", "Maker", "<", "?", ">", "maker", ")", "{", "Preconditions", ".", "checkNotNull", "(", "ownerType", ")", ";", "Preconditions", ".", "...
Add a field/property maker to a class type. i.e. with: <pre> {@code Class Person { String name } } </pre> You could define a custom maker for name field as (Person.class, "name", myNameMaker) @param ownerType the class that owns the field. @param propertyName field or property name @param maker custom maker @return t...
[ "Add", "a", "field", "/", "property", "maker", "to", "a", "class", "type", ".", "i", ".", "e", ".", "with", ":", "<pre", ">", "{", "@code" ]
train
https://github.com/huangp/entityunit/blob/1a09b530149d707dbff7ff46f5428d9db709a4b4/src/main/java/com/github/huangp/entityunit/maker/PreferredValueMakersRegistry.java#L74-L79
Azure/azure-sdk-for-java
cognitiveservices/data-plane/vision/faceapi/src/main/java/com/microsoft/azure/cognitiveservices/vision/faceapi/implementation/PersonGroupPersonsImpl.java
PersonGroupPersonsImpl.updateFaceAsync
public Observable<Void> updateFaceAsync(String personGroupId, UUID personId, UUID persistedFaceId, UpdateFaceOptionalParameter updateFaceOptionalParameter) { """ Update a person persisted face's userData field. @param personGroupId Id referencing a particular person group. @param personId Id referencing a part...
java
public Observable<Void> updateFaceAsync(String personGroupId, UUID personId, UUID persistedFaceId, UpdateFaceOptionalParameter updateFaceOptionalParameter) { return updateFaceWithServiceResponseAsync(personGroupId, personId, persistedFaceId, updateFaceOptionalParameter).map(new Func1<ServiceResponse<Void>, Void...
[ "public", "Observable", "<", "Void", ">", "updateFaceAsync", "(", "String", "personGroupId", ",", "UUID", "personId", ",", "UUID", "persistedFaceId", ",", "UpdateFaceOptionalParameter", "updateFaceOptionalParameter", ")", "{", "return", "updateFaceWithServiceResponseAsync",...
Update a person persisted face's userData field. @param personGroupId Id referencing a particular person group. @param personId Id referencing a particular person. @param persistedFaceId Id referencing a particular persistedFaceId of an existing face. @param updateFaceOptionalParameter the object representing the opti...
[ "Update", "a", "person", "persisted", "face", "s", "userData", "field", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/cognitiveservices/data-plane/vision/faceapi/src/main/java/com/microsoft/azure/cognitiveservices/vision/faceapi/implementation/PersonGroupPersonsImpl.java#L1011-L1018
ModeShape/modeshape
index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java
EsClient.createIndex
public boolean createIndex(String name, String type, EsRequest mappings) throws IOException { """ Creates new index. @param name the name of the index to test. @param type index type @param mappings field mapping definition. @return true if index was created. @throws IOException communication exception. ...
java
public boolean createIndex(String name, String type, EsRequest mappings) throws IOException { if (indexExists(name)) { return true; } CloseableHttpClient client = HttpClients.createDefault(); HttpPost method = new HttpPost(String.format("http://%s:%d/%s", host, port, name));...
[ "public", "boolean", "createIndex", "(", "String", "name", ",", "String", "type", ",", "EsRequest", "mappings", ")", "throws", "IOException", "{", "if", "(", "indexExists", "(", "name", ")", ")", "{", "return", "true", ";", "}", "CloseableHttpClient", "clien...
Creates new index. @param name the name of the index to test. @param type index type @param mappings field mapping definition. @return true if index was created. @throws IOException communication exception.
[ "Creates", "new", "index", "." ]
train
https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/index-providers/modeshape-elasticsearch-index-provider/src/main/java/org/modeshape/jcr/index/elasticsearch/client/EsClient.java#L80-L95
webmetrics/browsermob-proxy
src/main/java/org/xbill/DNS/security/DSASignature.java
DSASignature.toDNS
public static byte [] toDNS(DSAParams params, byte [] sig) throws SignatureException { """ Converts the signature generated by DSA signature routines to the one expected inside an RRSIG/SIG record. """ int rLength, sLength; int rOffset, sOffset; if ((sig[0] != ASN1_SEQ) || (sig[2] != ASN1_INT)) throw new...
java
public static byte [] toDNS(DSAParams params, byte [] sig) throws SignatureException { int rLength, sLength; int rOffset, sOffset; if ((sig[0] != ASN1_SEQ) || (sig[2] != ASN1_INT)) throw new SignatureException("Expected SEQ, INT"); rLength = sig[3]; rOffset = 4; if (sig[rOffset] == 0) { rLength--; rOffset++...
[ "public", "static", "byte", "[", "]", "toDNS", "(", "DSAParams", "params", ",", "byte", "[", "]", "sig", ")", "throws", "SignatureException", "{", "int", "rLength", ",", "sLength", ";", "int", "rOffset", ",", "sOffset", ";", "if", "(", "(", "sig", "[",...
Converts the signature generated by DSA signature routines to the one expected inside an RRSIG/SIG record.
[ "Converts", "the", "signature", "generated", "by", "DSA", "signature", "routines", "to", "the", "one", "expected", "inside", "an", "RRSIG", "/", "SIG", "record", "." ]
train
https://github.com/webmetrics/browsermob-proxy/blob/a9252e62246ac33d55d51b993ba1159404e7d389/src/main/java/org/xbill/DNS/security/DSASignature.java#L68-L100
inkstand-io/scribble
scribble-jcr/src/main/java/io/inkstand/scribble/jcr/JCRAssert.java
JCRAssert.assertNodeExist
public static void assertNodeExist(final Node rootNode, final String relPath) throws RepositoryException { """ Asserts that a specific node exists under the root node, where the specific node is specified using its relative path @param rootNode the root Node to start the search @param relPath the relative p...
java
public static void assertNodeExist(final Node rootNode, final String relPath) throws RepositoryException { try { rootNode.getNode(relPath); } catch (final PathNotFoundException e) { LOG.debug("Node {} does not exist in path {}", relPath, rootNode.getPath(), e); fail(e...
[ "public", "static", "void", "assertNodeExist", "(", "final", "Node", "rootNode", ",", "final", "String", "relPath", ")", "throws", "RepositoryException", "{", "try", "{", "rootNode", ".", "getNode", "(", "relPath", ")", ";", "}", "catch", "(", "final", "Path...
Asserts that a specific node exists under the root node, where the specific node is specified using its relative path @param rootNode the root Node to start the search @param relPath the relative path of the node that is asserted to exist @throws RepositoryException if the repository access failed
[ "Asserts", "that", "a", "specific", "node", "exists", "under", "the", "root", "node", "where", "the", "specific", "node", "is", "specified", "using", "its", "relative", "path" ]
train
https://github.com/inkstand-io/scribble/blob/66e67553bad4b1ff817e1715fd1d3dd833406744/scribble-jcr/src/main/java/io/inkstand/scribble/jcr/JCRAssert.java#L155-L162
elki-project/elki
elki-core-math/src/main/java/de/lmu/ifi/dbs/elki/math/geodesy/SphereUtil.java
SphereUtil.ellipsoidVincentyFormulaRad
@Reference(authors = "T. Vincenty", // title = "Direct and inverse solutions of geodesics on the ellipsoid with application of nested equations", // booktitle = "Survey Review 23:176", // url = "https://doi.org/10.1179/sre.1975.23.176.88", // bibkey = "doi:10.1179/sre.1975.23.176.88") public s...
java
@Reference(authors = "T. Vincenty", // title = "Direct and inverse solutions of geodesics on the ellipsoid with application of nested equations", // booktitle = "Survey Review 23:176", // url = "https://doi.org/10.1179/sre.1975.23.176.88", // bibkey = "doi:10.1179/sre.1975.23.176.88") public s...
[ "@", "Reference", "(", "authors", "=", "\"T. Vincenty\"", ",", "//", "title", "=", "\"Direct and inverse solutions of geodesics on the ellipsoid with application of nested equations\"", ",", "//", "booktitle", "=", "\"Survey Review 23:176\"", ",", "//", "url", "=", "\"https:/...
Compute the approximate great-circle distance of two points. <p> Reference: <p> T. Vincenty<br> Direct and inverse solutions of geodesics on the ellipsoid with application of nested equations<br> Survey review 23 176, 1975 @param f Ellipsoid flattening @param lat1 Latitude of first point in degree @param lon1 Longitud...
[ "Compute", "the", "approximate", "great", "-", "circle", "distance", "of", "two", "points", ".", "<p", ">", "Reference", ":", "<p", ">", "T", ".", "Vincenty<br", ">", "Direct", "and", "inverse", "solutions", "of", "geodesics", "on", "the", "ellipsoid", "wi...
train
https://github.com/elki-project/elki/blob/b54673327e76198ecd4c8a2a901021f1a9174498/elki-core-math/src/main/java/de/lmu/ifi/dbs/elki/math/geodesy/SphereUtil.java#L336-L404
carewebframework/carewebframework-core
org.carewebframework.shell/src/main/java/org/carewebframework/shell/layout/LayoutUtil.java
LayoutUtil.copyAttributes
public static void copyAttributes(Element source, Map<String, String> dest) { """ Copy attributes from a DOM node to a map. @param source DOM node. @param dest Destination map. """ NamedNodeMap attributes = source.getAttributes(); if (attributes != null) { for (int i = 0; i < a...
java
public static void copyAttributes(Element source, Map<String, String> dest) { NamedNodeMap attributes = source.getAttributes(); if (attributes != null) { for (int i = 0; i < attributes.getLength(); i++) { Node attribute = attributes.item(i); dest.put(attribut...
[ "public", "static", "void", "copyAttributes", "(", "Element", "source", ",", "Map", "<", "String", ",", "String", ">", "dest", ")", "{", "NamedNodeMap", "attributes", "=", "source", ".", "getAttributes", "(", ")", ";", "if", "(", "attributes", "!=", "null"...
Copy attributes from a DOM node to a map. @param source DOM node. @param dest Destination map.
[ "Copy", "attributes", "from", "a", "DOM", "node", "to", "a", "map", "." ]
train
https://github.com/carewebframework/carewebframework-core/blob/fa3252d4f7541dbe151b92c3d4f6f91433cd1673/org.carewebframework.shell/src/main/java/org/carewebframework/shell/layout/LayoutUtil.java#L147-L156
Azure/azure-sdk-for-java
containerregistry/resource-manager/v2017_06_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2017_06_01_preview/implementation/ReplicationsInner.java
ReplicationsInner.beginDelete
public void beginDelete(String resourceGroupName, String registryName, String replicationName) { """ Deletes a replication from a container registry. @param resourceGroupName The name of the resource group to which the container registry belongs. @param registryName The name of the container registry. @param ...
java
public void beginDelete(String resourceGroupName, String registryName, String replicationName) { beginDeleteWithServiceResponseAsync(resourceGroupName, registryName, replicationName).toBlocking().single().body(); }
[ "public", "void", "beginDelete", "(", "String", "resourceGroupName", ",", "String", "registryName", ",", "String", "replicationName", ")", "{", "beginDeleteWithServiceResponseAsync", "(", "resourceGroupName", ",", "registryName", ",", "replicationName", ")", ".", "toBlo...
Deletes a replication from a container registry. @param resourceGroupName The name of the resource group to which the container registry belongs. @param registryName The name of the container registry. @param replicationName The name of the replication. @throws IllegalArgumentException thrown if parameters fail the va...
[ "Deletes", "a", "replication", "from", "a", "container", "registry", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/containerregistry/resource-manager/v2017_06_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2017_06_01_preview/implementation/ReplicationsInner.java#L469-L471
spring-projects/spring-android
spring-android-rest-template/src/main/java/org/springframework/web/util/UriComponentsBuilder.java
UriComponentsBuilder.queryParams
public UriComponentsBuilder queryParams(MultiValueMap<String, String> params) { """ Add the given query parameters. @param params the params @return this UriComponentsBuilder """ Assert.notNull(params, "'params' must not be null"); this.queryParams.putAll(params); return this; }
java
public UriComponentsBuilder queryParams(MultiValueMap<String, String> params) { Assert.notNull(params, "'params' must not be null"); this.queryParams.putAll(params); return this; }
[ "public", "UriComponentsBuilder", "queryParams", "(", "MultiValueMap", "<", "String", ",", "String", ">", "params", ")", "{", "Assert", ".", "notNull", "(", "params", ",", "\"'params' must not be null\"", ")", ";", "this", ".", "queryParams", ".", "putAll", "(",...
Add the given query parameters. @param params the params @return this UriComponentsBuilder
[ "Add", "the", "given", "query", "parameters", "." ]
train
https://github.com/spring-projects/spring-android/blob/941296e152d49a40e0745a3e81628a974f72b7e4/spring-android-rest-template/src/main/java/org/springframework/web/util/UriComponentsBuilder.java#L590-L594
liferay/com-liferay-commerce
commerce-product-service/src/main/java/com/liferay/commerce/product/service/persistence/impl/CPDefinitionPersistenceImpl.java
CPDefinitionPersistenceImpl.removeByG_S
@Override public void removeByG_S(long groupId, int status) { """ Removes all the cp definitions where groupId = &#63; and status = &#63; from the database. @param groupId the group ID @param status the status """ for (CPDefinition cpDefinition : findByG_S(groupId, status, QueryUtil.ALL_POS, QueryUt...
java
@Override public void removeByG_S(long groupId, int status) { for (CPDefinition cpDefinition : findByG_S(groupId, status, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null)) { remove(cpDefinition); } }
[ "@", "Override", "public", "void", "removeByG_S", "(", "long", "groupId", ",", "int", "status", ")", "{", "for", "(", "CPDefinition", "cpDefinition", ":", "findByG_S", "(", "groupId", ",", "status", ",", "QueryUtil", ".", "ALL_POS", ",", "QueryUtil", ".", ...
Removes all the cp definitions where groupId = &#63; and status = &#63; from the database. @param groupId the group ID @param status the status
[ "Removes", "all", "the", "cp", "definitions", "where", "groupId", "=", "&#63", ";", "and", "status", "=", "&#63", ";", "from", "the", "database", "." ]
train
https://github.com/liferay/com-liferay-commerce/blob/9e54362d7f59531fc684016ba49ee7cdc3a2f22b/commerce-product-service/src/main/java/com/liferay/commerce/product/service/persistence/impl/CPDefinitionPersistenceImpl.java#L3482-L3488
FDMediagroep/hamcrest-jsoup
src/main/java/nl/fd/hamcrest/jsoup/ElementWithAttribute.java
ElementWithAttribute.hasAttribute
@Factory public static Matcher<Element> hasAttribute(final String attributeName, final Matcher<? super String> attributeValueMatcher) { """ Creates a {@link org.hamcrest.Matcher} for a JSoup {@link org.jsoup.nodes.Element} with the given {@code expectedValue} for the given {@code attributeName}. @param att...
java
@Factory public static Matcher<Element> hasAttribute(final String attributeName, final Matcher<? super String> attributeValueMatcher) { return new ElementWithAttribute(attributeName, attributeValueMatcher); }
[ "@", "Factory", "public", "static", "Matcher", "<", "Element", ">", "hasAttribute", "(", "final", "String", "attributeName", ",", "final", "Matcher", "<", "?", "super", "String", ">", "attributeValueMatcher", ")", "{", "return", "new", "ElementWithAttribute", "(...
Creates a {@link org.hamcrest.Matcher} for a JSoup {@link org.jsoup.nodes.Element} with the given {@code expectedValue} for the given {@code attributeName}. @param attributeName The attribute name whose value to check @param attributeValueMatcher A matcher for the attribute value @return a {@link org.hamcrest....
[ "Creates", "a", "{", "@link", "org", ".", "hamcrest", ".", "Matcher", "}", "for", "a", "JSoup", "{", "@link", "org", ".", "jsoup", ".", "nodes", ".", "Element", "}", "with", "the", "given", "{", "@code", "expectedValue", "}", "for", "the", "given", "...
train
https://github.com/FDMediagroep/hamcrest-jsoup/blob/b7152dac6f834e40117fb7cfdd3149a268d95f7b/src/main/java/nl/fd/hamcrest/jsoup/ElementWithAttribute.java#L70-L73
dmak/jaxb-xew-plugin
src/main/java/com/sun/tools/xjc/addon/xew/XmlElementWrapperPlugin.java
XmlElementWrapperPlugin.moveInnerClassToParent
private boolean moveInnerClassToParent(Outline outline, Candidate candidate) { """ If candidate class contains the inner class which is collection parametrisation (type), then this inner class has to be moved to top class. For example from<br> {@code TypeClass (is a collection type) -> ContainerClass (marked for...
java
private boolean moveInnerClassToParent(Outline outline, Candidate candidate) { // Skip basic parametrisations like "List<String>": if (candidate.getFieldParametrisationClass() == null) { return false; } JDefinedClass fieldParametrisationImpl = candidate.getFieldParametrisationImpl(); if (candidate.getCla...
[ "private", "boolean", "moveInnerClassToParent", "(", "Outline", "outline", ",", "Candidate", "candidate", ")", "{", "// Skip basic parametrisations like \"List<String>\":", "if", "(", "candidate", ".", "getFieldParametrisationClass", "(", ")", "==", "null", ")", "{", "r...
If candidate class contains the inner class which is collection parametrisation (type), then this inner class has to be moved to top class. For example from<br> {@code TypeClass (is a collection type) -> ContainerClass (marked for removal) -> ElementClass}<br> we need to get<br> {@code TypeClass -> ElementClass}.<br> A...
[ "If", "candidate", "class", "contains", "the", "inner", "class", "which", "is", "collection", "parametrisation", "(", "type", ")", "then", "this", "inner", "class", "has", "to", "be", "moved", "to", "top", "class", ".", "For", "example", "from<br", ">", "{...
train
https://github.com/dmak/jaxb-xew-plugin/blob/d564d6bf8e50c46b056cdb4b46d1d4bee4adfbe3/src/main/java/com/sun/tools/xjc/addon/xew/XmlElementWrapperPlugin.java#L540-L570
line/armeria
core/src/main/java/com/linecorp/armeria/client/HttpChannelPool.java
HttpChannelPool.acquireNow
@Nullable PooledChannel acquireNow(SessionProtocol desiredProtocol, PoolKey key) { """ Attempts to acquire a {@link Channel} which is matched by the specified condition immediately. @return {@code null} is there's no match left in the pool and thus a new connection has to be requested via {@link #acquireLa...
java
@Nullable PooledChannel acquireNow(SessionProtocol desiredProtocol, PoolKey key) { PooledChannel ch; switch (desiredProtocol) { case HTTP: ch = acquireNowExact(key, SessionProtocol.H2C); if (ch == null) { ch = acquireNowExact(key, Sessi...
[ "@", "Nullable", "PooledChannel", "acquireNow", "(", "SessionProtocol", "desiredProtocol", ",", "PoolKey", "key", ")", "{", "PooledChannel", "ch", ";", "switch", "(", "desiredProtocol", ")", "{", "case", "HTTP", ":", "ch", "=", "acquireNowExact", "(", "key", "...
Attempts to acquire a {@link Channel} which is matched by the specified condition immediately. @return {@code null} is there's no match left in the pool and thus a new connection has to be requested via {@link #acquireLater(SessionProtocol, PoolKey, ClientConnectionTimingsBuilder)}.
[ "Attempts", "to", "acquire", "a", "{", "@link", "Channel", "}", "which", "is", "matched", "by", "the", "specified", "condition", "immediately", "." ]
train
https://github.com/line/armeria/blob/67d29e019fd35a35f89c45cc8f9119ff9b12b44d/core/src/main/java/com/linecorp/armeria/client/HttpChannelPool.java#L162-L182
landawn/AbacusUtil
src/com/landawn/abacus/util/stream/Collectors.java
Collectors.first
public static <T> Collector<T, ?, List<T>> first(final int n) { """ Only works for sequential Stream. @param n @return @throws UnsupportedOperationException operated by multiple threads """ N.checkArgNotNegative(n, "n"); final Supplier<List<T>> supplier = new Supplier<List<T>>() { ...
java
public static <T> Collector<T, ?, List<T>> first(final int n) { N.checkArgNotNegative(n, "n"); final Supplier<List<T>> supplier = new Supplier<List<T>>() { @Override public List<T> get() { return new ArrayList<T>(N.min(256, n)); } }; ...
[ "public", "static", "<", "T", ">", "Collector", "<", "T", ",", "?", ",", "List", "<", "T", ">", ">", "first", "(", "final", "int", "n", ")", "{", "N", ".", "checkArgNotNegative", "(", "n", ",", "\"n\"", ")", ";", "final", "Supplier", "<", "List",...
Only works for sequential Stream. @param n @return @throws UnsupportedOperationException operated by multiple threads
[ "Only", "works", "for", "sequential", "Stream", "." ]
train
https://github.com/landawn/AbacusUtil/blob/544b7720175d15e9329f83dd22a8cc5fa4515e12/src/com/landawn/abacus/util/stream/Collectors.java#L1461-L1492
jqno/equalsverifier
src/main/java/nl/jqno/equalsverifier/ConfiguredEqualsVerifier.java
ConfiguredEqualsVerifier.withGenericPrefabValues
public <S> ConfiguredEqualsVerifier withGenericPrefabValues(Class<S> otherType, Func1<?, S> factory) { """ Adds a factory to generate prefabricated values for instance fields of classes with 1 generic type parameter that EqualsVerifier cannot instantiate by itself. @param <S> The class of the prefabricated va...
java
public <S> ConfiguredEqualsVerifier withGenericPrefabValues(Class<S> otherType, Func1<?, S> factory) { PrefabValuesApi.addGenericPrefabValues(factoryCache, otherType, factory); return this; }
[ "public", "<", "S", ">", "ConfiguredEqualsVerifier", "withGenericPrefabValues", "(", "Class", "<", "S", ">", "otherType", ",", "Func1", "<", "?", ",", "S", ">", "factory", ")", "{", "PrefabValuesApi", ".", "addGenericPrefabValues", "(", "factoryCache", ",", "o...
Adds a factory to generate prefabricated values for instance fields of classes with 1 generic type parameter that EqualsVerifier cannot instantiate by itself. @param <S> The class of the prefabricated values. @param otherType The class of the prefabricated values. @param factory A factory to generate an instance of {@...
[ "Adds", "a", "factory", "to", "generate", "prefabricated", "values", "for", "instance", "fields", "of", "classes", "with", "1", "generic", "type", "parameter", "that", "EqualsVerifier", "cannot", "instantiate", "by", "itself", "." ]
train
https://github.com/jqno/equalsverifier/blob/25d73c9cb801c8b20b257d1d1283ac6e0585ef1d/src/main/java/nl/jqno/equalsverifier/ConfiguredEqualsVerifier.java#L60-L63
lessthanoptimal/ejml
main/ejml-ddense/src/org/ejml/dense/row/decomposition/TriangularSolver_DDRM.java
TriangularSolver_DDRM.solveTranL
public static void solveTranL( double L[] , double []b , int n ) { """ <p> This is a forward substitution solver for non-singular lower triangular matrices. <br> b = (L<sup>T</sup>)<sup>-1</sup>b<br> <br> where b is a vector, L is an n by n matrix.<br> </p> <p> L is a lower triangular matrix, but it comes ...
java
public static void solveTranL( double L[] , double []b , int n ) { for( int i =n-1; i>=0; i-- ) { double sum = b[i]; for( int k = i+1; k <n; k++ ) { sum -= L[k*n+i]* b[k]; } b[i] = sum/L[i*n+i]; } }
[ "public", "static", "void", "solveTranL", "(", "double", "L", "[", "]", ",", "double", "[", "]", "b", ",", "int", "n", ")", "{", "for", "(", "int", "i", "=", "n", "-", "1", ";", "i", ">=", "0", ";", "i", "--", ")", "{", "double", "sum", "="...
<p> This is a forward substitution solver for non-singular lower triangular matrices. <br> b = (L<sup>T</sup>)<sup>-1</sup>b<br> <br> where b is a vector, L is an n by n matrix.<br> </p> <p> L is a lower triangular matrix, but it comes up with a solution as if it was an upper triangular matrix that was computed by tran...
[ "<p", ">", "This", "is", "a", "forward", "substitution", "solver", "for", "non", "-", "singular", "lower", "triangular", "matrices", ".", "<br", ">", "b", "=", "(", "L<sup", ">", "T<", "/", "sup", ">", ")", "<sup", ">", "-", "1<", "/", "sup", ">", ...
train
https://github.com/lessthanoptimal/ejml/blob/1444680cc487af5e866730e62f48f5f9636850d9/main/ejml-ddense/src/org/ejml/dense/row/decomposition/TriangularSolver_DDRM.java#L148-L157
google/closure-compiler
src/com/google/javascript/jscomp/NodeUtil.java
NodeUtil.newName
static Node newName(AbstractCompiler compiler, String name, Node srcref) { """ Creates a new node representing an *existing* name, copying over the source location information from the basis node. @param name The name for the new NAME node. @param srcref The node that represents the name as currently found in...
java
static Node newName(AbstractCompiler compiler, String name, Node srcref) { return newName(compiler, name).srcref(srcref); }
[ "static", "Node", "newName", "(", "AbstractCompiler", "compiler", ",", "String", "name", ",", "Node", "srcref", ")", "{", "return", "newName", "(", "compiler", ",", "name", ")", ".", "srcref", "(", "srcref", ")", ";", "}" ]
Creates a new node representing an *existing* name, copying over the source location information from the basis node. @param name The name for the new NAME node. @param srcref The node that represents the name as currently found in the AST. @return The node created.
[ "Creates", "a", "new", "node", "representing", "an", "*", "existing", "*", "name", "copying", "over", "the", "source", "location", "information", "from", "the", "basis", "node", "." ]
train
https://github.com/google/closure-compiler/blob/d81e36740f6a9e8ac31a825ee8758182e1dc5aae/src/com/google/javascript/jscomp/NodeUtil.java#L4144-L4146
app55/app55-java
src/main/java/com/app55/util/Base64.java
Base64.encodeFileToFile
private static boolean encodeFileToFile(String infile, String outfile) { """ Reads <tt>infile</tt> and encodes it to <tt>outfile</tt>. @param infile Input file @param outfile Output file @return true if the operation is successful @since 2.2 """ boolean success = false; java.io.InputStream in = nul...
java
private static boolean encodeFileToFile(String infile, String outfile) { boolean success = false; java.io.InputStream in = null; java.io.OutputStream out = null; try { in = new Base64.InputStream(new java.io.BufferedInputStream(new java.io.FileInputStream(infile)), Base64.ENCODE); out = new java.io.Buf...
[ "private", "static", "boolean", "encodeFileToFile", "(", "String", "infile", ",", "String", "outfile", ")", "{", "boolean", "success", "=", "false", ";", "java", ".", "io", ".", "InputStream", "in", "=", "null", ";", "java", ".", "io", ".", "OutputStream",...
Reads <tt>infile</tt> and encodes it to <tt>outfile</tt>. @param infile Input file @param outfile Output file @return true if the operation is successful @since 2.2
[ "Reads", "<tt", ">", "infile<", "/", "tt", ">", "and", "encodes", "it", "to", "<tt", ">", "outfile<", "/", "tt", ">", "." ]
train
https://github.com/app55/app55-java/blob/73e51d0f3141a859dfbd37ca9becef98477e553e/src/main/java/com/app55/util/Base64.java#L1293-L1332
jbossws/jbossws-cxf
modules/server/src/main/java/org/jboss/wsf/stack/cxf/addressRewrite/SEDProcessor.java
SEDProcessor.indexOfNextDelimiter
private static int indexOfNextDelimiter(String script, int indexOfPreviousDelimiter) { """ Returns the index of the next delimiter in the given sed script. The character at {@code indexOfPreviousDelimiter} is taken as delimiter. The method handles escaped delimiters and returns -1 if no further delimiter is fou...
java
private static int indexOfNextDelimiter(String script, int indexOfPreviousDelimiter) { if (indexOfPreviousDelimiter < 0 || script.length() <= indexOfPreviousDelimiter) { return -1; } final char delim = script.charAt(indexOfPreviousDelimiter); if (delim == '\\') { ...
[ "private", "static", "int", "indexOfNextDelimiter", "(", "String", "script", ",", "int", "indexOfPreviousDelimiter", ")", "{", "if", "(", "indexOfPreviousDelimiter", "<", "0", "||", "script", ".", "length", "(", ")", "<=", "indexOfPreviousDelimiter", ")", "{", "...
Returns the index of the next delimiter in the given sed script. The character at {@code indexOfPreviousDelimiter} is taken as delimiter. The method handles escaped delimiters and returns -1 if no further delimiter is found. @param script the script to analyze @param indexOfPreviousDelimiter the index of the previous ...
[ "Returns", "the", "index", "of", "the", "next", "delimiter", "in", "the", "given", "sed", "script", ".", "The", "character", "at", "{", "@code", "indexOfPreviousDelimiter", "}", "is", "taken", "as", "delimiter", ".", "The", "method", "handles", "escaped", "d...
train
https://github.com/jbossws/jbossws-cxf/blob/e1d5df3664cbc2482ebc83cafd355a4d60d12150/modules/server/src/main/java/org/jboss/wsf/stack/cxf/addressRewrite/SEDProcessor.java#L313-L331
netty/netty
codec/src/main/java/io/netty/handler/codec/MessageToByteEncoder.java
MessageToByteEncoder.allocateBuffer
protected ByteBuf allocateBuffer(ChannelHandlerContext ctx, @SuppressWarnings("unused") I msg, boolean preferDirect) throws Exception { """ Allocate a {@link ByteBuf} which will be used as argument of {@link #encode(ChannelHandlerContext, I, ByteBuf)}. Sub-classes may override this ...
java
protected ByteBuf allocateBuffer(ChannelHandlerContext ctx, @SuppressWarnings("unused") I msg, boolean preferDirect) throws Exception { if (preferDirect) { return ctx.alloc().ioBuffer(); } else { return ctx.alloc().heapBuffer(); } }
[ "protected", "ByteBuf", "allocateBuffer", "(", "ChannelHandlerContext", "ctx", ",", "@", "SuppressWarnings", "(", "\"unused\"", ")", "I", "msg", ",", "boolean", "preferDirect", ")", "throws", "Exception", "{", "if", "(", "preferDirect", ")", "{", "return", "ctx"...
Allocate a {@link ByteBuf} which will be used as argument of {@link #encode(ChannelHandlerContext, I, ByteBuf)}. Sub-classes may override this method to return {@link ByteBuf} with a perfect matching {@code initialCapacity}.
[ "Allocate", "a", "{" ]
train
https://github.com/netty/netty/blob/ba06eafa1c1824bd154f1a380019e7ea2edf3c4c/codec/src/main/java/io/netty/handler/codec/MessageToByteEncoder.java#L137-L144
RestComm/sipunit
src/main/java/org/cafesip/sipunit/SipAssert.java
SipAssert.responseReceived
public static boolean responseReceived(int statusCode, MessageListener messageListener) { """ Check the given message listener object received a response with the indicated status code. @param statusCode the code we want to find @param messageListener the {@link MessageListener} we want to check @return true...
java
public static boolean responseReceived(int statusCode, MessageListener messageListener) { ArrayList<SipResponse> responses = messageListener.getAllReceivedResponses(); for (SipResponse r : responses) { if (statusCode == r.getStatusCode()) { return true; } } return false; ...
[ "public", "static", "boolean", "responseReceived", "(", "int", "statusCode", ",", "MessageListener", "messageListener", ")", "{", "ArrayList", "<", "SipResponse", ">", "responses", "=", "messageListener", ".", "getAllReceivedResponses", "(", ")", ";", "for", "(", ...
Check the given message listener object received a response with the indicated status code. @param statusCode the code we want to find @param messageListener the {@link MessageListener} we want to check @return true if a received response matches the given statusCode
[ "Check", "the", "given", "message", "listener", "object", "received", "a", "response", "with", "the", "indicated", "status", "code", "." ]
train
https://github.com/RestComm/sipunit/blob/18a6be2e29be3fbdc14226e8c41b25e2d57378b1/src/main/java/org/cafesip/sipunit/SipAssert.java#L303-L313
apiman/apiman
gateway/engine/core/src/main/java/io/apiman/gateway/engine/impl/DefaultPluginRegistry.java
DefaultPluginRegistry.downloadPlugin
protected void downloadPlugin(final PluginCoordinates coordinates, final IAsyncResultHandler<File> handler) { """ Downloads the plugin via its maven GAV information. This will first look in the local .m2 directory. If the plugin is not found there, then it will try to download the plugin from one of the config...
java
protected void downloadPlugin(final PluginCoordinates coordinates, final IAsyncResultHandler<File> handler) { if (pluginRepositories.isEmpty()) { // Didn't find it - no repositories configured! handler.handle(AsyncResultImpl.create((File) null)); return; } fi...
[ "protected", "void", "downloadPlugin", "(", "final", "PluginCoordinates", "coordinates", ",", "final", "IAsyncResultHandler", "<", "File", ">", "handler", ")", "{", "if", "(", "pluginRepositories", ".", "isEmpty", "(", ")", ")", "{", "// Didn't find it - no reposito...
Downloads the plugin via its maven GAV information. This will first look in the local .m2 directory. If the plugin is not found there, then it will try to download the plugin from one of the configured remote maven repositories.
[ "Downloads", "the", "plugin", "via", "its", "maven", "GAV", "information", ".", "This", "will", "first", "look", "in", "the", "local", ".", "m2", "directory", ".", "If", "the", "plugin", "is", "not", "found", "there", "then", "it", "will", "try", "to", ...
train
https://github.com/apiman/apiman/blob/8c049c2a2f2e4a69bbb6125686a15edd26f29c21/gateway/engine/core/src/main/java/io/apiman/gateway/engine/impl/DefaultPluginRegistry.java#L335-L355
VoltDB/voltdb
src/frontend/org/voltdb/sysprocs/AdHocNTBase.java
AdHocNTBase.processAdHocSQLStmtTypes
public static AdHocSQLMix processAdHocSQLStmtTypes(String sql, List<String> validatedHomogeonousSQL) { """ Split a set of one or more semi-colon delimited sql statements into a list. Store the list in validatedHomogeonousSQL. Return whether the SQL is empty, all dml or dql, all ddl, or an invalid mix (AdHocSQLMi...
java
public static AdHocSQLMix processAdHocSQLStmtTypes(String sql, List<String> validatedHomogeonousSQL) { assert(validatedHomogeonousSQL != null); assert(validatedHomogeonousSQL.size() == 0); List<String> sqlStatements = SQLLexer.splitStatements(sql).getCompletelyParsedStmts(); // do init...
[ "public", "static", "AdHocSQLMix", "processAdHocSQLStmtTypes", "(", "String", "sql", ",", "List", "<", "String", ">", "validatedHomogeonousSQL", ")", "{", "assert", "(", "validatedHomogeonousSQL", "!=", "null", ")", ";", "assert", "(", "validatedHomogeonousSQL", "."...
Split a set of one or more semi-colon delimited sql statements into a list. Store the list in validatedHomogeonousSQL. Return whether the SQL is empty, all dml or dql, all ddl, or an invalid mix (AdHocSQLMix) Used by the NT adhoc procs, but also by the experimental in-proc adhoc.
[ "Split", "a", "set", "of", "one", "or", "more", "semi", "-", "colon", "delimited", "sql", "statements", "into", "a", "list", ".", "Store", "the", "list", "in", "validatedHomogeonousSQL", ".", "Return", "whether", "the", "SQL", "is", "empty", "all", "dml", ...
train
https://github.com/VoltDB/voltdb/blob/8afc1031e475835344b5497ea9e7203bc95475ac/src/frontend/org/voltdb/sysprocs/AdHocNTBase.java#L128-L160
optimatika/ojAlgo-finance
src/main/java/org/ojalgo/finance/FinanceUtils.java
FinanceUtils.toCovariances
public static PrimitiveMatrix toCovariances(Access1D<?> volatilities, Access2D<?> correlations) { """ Vill constract a covariance matrix from the standard deviations (volatilities) and correlation coefficient, """ int tmpSize = (int) volatilities.count(); PrimitiveMatrix.DenseReceiver retVal...
java
public static PrimitiveMatrix toCovariances(Access1D<?> volatilities, Access2D<?> correlations) { int tmpSize = (int) volatilities.count(); PrimitiveMatrix.DenseReceiver retVal = PrimitiveMatrix.FACTORY.makeDense(tmpSize, tmpSize); for (int j = 0; j < tmpSize; j++) { double tmpCol...
[ "public", "static", "PrimitiveMatrix", "toCovariances", "(", "Access1D", "<", "?", ">", "volatilities", ",", "Access2D", "<", "?", ">", "correlations", ")", "{", "int", "tmpSize", "=", "(", "int", ")", "volatilities", ".", "count", "(", ")", ";", "Primitiv...
Vill constract a covariance matrix from the standard deviations (volatilities) and correlation coefficient,
[ "Vill", "constract", "a", "covariance", "matrix", "from", "the", "standard", "deviations", "(", "volatilities", ")", "and", "correlation", "coefficient" ]
train
https://github.com/optimatika/ojAlgo-finance/blob/c8d3f7e1894d4263b7334bca3f4c060e466f8b15/src/main/java/org/ojalgo/finance/FinanceUtils.java#L418-L435
avianey/facebook-api-android-maven
facebook/src/main/java/com/facebook/Request.java
Request.executeConnectionAsync
public static RequestAsyncTask executeConnectionAsync(HttpURLConnection connection, RequestBatch requests) { """ Asynchronously executes requests that have already been serialized into an HttpURLConnection. No validation is done that the contents of the connection actually reflect the serialized requests, so it i...
java
public static RequestAsyncTask executeConnectionAsync(HttpURLConnection connection, RequestBatch requests) { return executeConnectionAsync(null, connection, requests); }
[ "public", "static", "RequestAsyncTask", "executeConnectionAsync", "(", "HttpURLConnection", "connection", ",", "RequestBatch", "requests", ")", "{", "return", "executeConnectionAsync", "(", "null", ",", "connection", ",", "requests", ")", ";", "}" ]
Asynchronously executes requests that have already been serialized into an HttpURLConnection. No validation is done that the contents of the connection actually reflect the serialized requests, so it is the caller's responsibility to ensure that it will correctly generate the desired responses. This function will retur...
[ "Asynchronously", "executes", "requests", "that", "have", "already", "been", "serialized", "into", "an", "HttpURLConnection", ".", "No", "validation", "is", "done", "that", "the", "contents", "of", "the", "connection", "actually", "reflect", "the", "serialized", "...
train
https://github.com/avianey/facebook-api-android-maven/blob/ae6c7aa7ae45739ee19f18c1983e05f7e35b9ede/facebook/src/main/java/com/facebook/Request.java#L1596-L1598
jdereg/java-util
src/main/java/com/cedarsoftware/util/ProxyFactory.java
ProxyFactory.create
public static <T> T create(Class<T> intf, InvocationHandler h) { """ Returns an instance of a proxy class for the specified interfaces that dispatches method invocations to the specified invocation handler. @param intf the interface for the proxy to implement @param h the invocation handler to dispatch met...
java
public static <T> T create(Class<T> intf, InvocationHandler h) { return create(h.getClass().getClassLoader(), intf, h); }
[ "public", "static", "<", "T", ">", "T", "create", "(", "Class", "<", "T", ">", "intf", ",", "InvocationHandler", "h", ")", "{", "return", "create", "(", "h", ".", "getClass", "(", ")", ".", "getClassLoader", "(", ")", ",", "intf", ",", "h", ")", ...
Returns an instance of a proxy class for the specified interfaces that dispatches method invocations to the specified invocation handler. @param intf the interface for the proxy to implement @param h the invocation handler to dispatch method invocations to @return a proxy instance with the specified invocation handl...
[ "Returns", "an", "instance", "of", "a", "proxy", "class", "for", "the", "specified", "interfaces", "that", "dispatches", "method", "invocations", "to", "the", "specified", "invocation", "handler", "." ]
train
https://github.com/jdereg/java-util/blob/a2dce61aed16d6454ee575174dda1ba6bff0015c/src/main/java/com/cedarsoftware/util/ProxyFactory.java#L50-L52
google/j2objc
jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/TransliteratorParser.java
TransliteratorParser.syntaxError
static final void syntaxError(String msg, String rule, int start) { """ Throw an exception indicating a syntax error. Search the rule string for the probable end of the rule. Of course, if the error is that the end of rule marker is missing, then the rule end will not be found. In any case the rule start will...
java
static final void syntaxError(String msg, String rule, int start) { int end = ruleEnd(rule, start, rule.length()); throw new IllegalIcuArgumentException(msg + " in \"" + Utility.escape(rule.substring(start, end)) + '"'); }
[ "static", "final", "void", "syntaxError", "(", "String", "msg", ",", "String", "rule", ",", "int", "start", ")", "{", "int", "end", "=", "ruleEnd", "(", "rule", ",", "start", ",", "rule", ".", "length", "(", ")", ")", ";", "throw", "new", "IllegalIcu...
Throw an exception indicating a syntax error. Search the rule string for the probable end of the rule. Of course, if the error is that the end of rule marker is missing, then the rule end will not be found. In any case the rule start will be correctly reported. @param msg error description @param rule pattern string ...
[ "Throw", "an", "exception", "indicating", "a", "syntax", "error", ".", "Search", "the", "rule", "string", "for", "the", "probable", "end", "of", "the", "rule", ".", "Of", "course", "if", "the", "error", "is", "that", "the", "end", "of", "rule", "marker",...
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/TransliteratorParser.java#L1435-L1439
OpenLiberty/open-liberty
dev/com.ibm.ws.messaging.runtime/src/com/ibm/ws/sib/processor/gd/InternalOutputStreamManager.java
InternalOutputStreamManager.removeMessage
public void removeMessage(StreamSet streamSet, SIMPMessage msgItem) throws SIResourceException { """ Remove a message from the appropriate source stream. This is done by replacing the message with Silence in the stream Since it can only be called when a message is already in the stream the stream must exist. If...
java
public void removeMessage(StreamSet streamSet, SIMPMessage msgItem) throws SIResourceException { if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(tc, "removeMessage", new Object[] { streamSet, msgItem }); int priority = msgItem.getPriority(); Reliabil...
[ "public", "void", "removeMessage", "(", "StreamSet", "streamSet", ",", "SIMPMessage", "msgItem", ")", "throws", "SIResourceException", "{", "if", "(", "TraceComponent", ".", "isAnyTracingEnabled", "(", ")", "&&", "tc", ".", "isEntryEnabled", "(", ")", ")", "SibT...
Remove a message from the appropriate source stream. This is done by replacing the message with Silence in the stream Since it can only be called when a message is already in the stream the stream must exist. If it doesn't we have an internal error @param the stream set from which the messae should be removed @param m...
[ "Remove", "a", "message", "from", "the", "appropriate", "source", "stream", ".", "This", "is", "done", "by", "replacing", "the", "message", "with", "Silence", "in", "the", "stream", "Since", "it", "can", "only", "be", "called", "when", "a", "message", "is"...
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.messaging.runtime/src/com/ibm/ws/sib/processor/gd/InternalOutputStreamManager.java#L935-L966
Carbonado/Carbonado
src/main/java/com/amazon/carbonado/gen/CodeBuilderUtil.java
CodeBuilderUtil.throwException
public static void throwException(CodeBuilder b, Class type, String message) { """ Generate code to throw an exception with an optional message. @param b {@link CodeBuilder} to which to add code @param type type of the object to throw @param message optional message to provide to the constructor """ ...
java
public static void throwException(CodeBuilder b, Class type, String message) { TypeDesc desc = TypeDesc.forClass(type); b.newObject(desc); b.dup(); if (message == null) { b.invokeConstructor(desc, null); } else { b.loadConstant(message); ...
[ "public", "static", "void", "throwException", "(", "CodeBuilder", "b", ",", "Class", "type", ",", "String", "message", ")", "{", "TypeDesc", "desc", "=", "TypeDesc", ".", "forClass", "(", "type", ")", ";", "b", ".", "newObject", "(", "desc", ")", ";", ...
Generate code to throw an exception with an optional message. @param b {@link CodeBuilder} to which to add code @param type type of the object to throw @param message optional message to provide to the constructor
[ "Generate", "code", "to", "throw", "an", "exception", "with", "an", "optional", "message", "." ]
train
https://github.com/Carbonado/Carbonado/blob/eee29b365a61c8f03e1a1dc6bed0692e6b04b1db/src/main/java/com/amazon/carbonado/gen/CodeBuilderUtil.java#L89-L100
Azure/azure-sdk-for-java
network/resource-manager/v2018_04_01/src/main/java/com/microsoft/azure/management/network/v2018_04_01/implementation/ApplicationGatewaysInner.java
ApplicationGatewaysInner.beginDelete
public void beginDelete(String resourceGroupName, String applicationGatewayName) { """ Deletes the specified application gateway. @param resourceGroupName The name of the resource group. @param applicationGatewayName The name of the application gateway. @throws IllegalArgumentException thrown if parameters fa...
java
public void beginDelete(String resourceGroupName, String applicationGatewayName) { beginDeleteWithServiceResponseAsync(resourceGroupName, applicationGatewayName).toBlocking().single().body(); }
[ "public", "void", "beginDelete", "(", "String", "resourceGroupName", ",", "String", "applicationGatewayName", ")", "{", "beginDeleteWithServiceResponseAsync", "(", "resourceGroupName", ",", "applicationGatewayName", ")", ".", "toBlocking", "(", ")", ".", "single", "(", ...
Deletes the specified application gateway. @param resourceGroupName The name of the resource group. @param applicationGatewayName The name of the application gateway. @throws IllegalArgumentException thrown if parameters fail the validation @throws CloudException thrown if the request is rejected by server @throws Run...
[ "Deletes", "the", "specified", "application", "gateway", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/network/resource-manager/v2018_04_01/src/main/java/com/microsoft/azure/management/network/v2018_04_01/implementation/ApplicationGatewaysInner.java#L235-L237
apache/incubator-gobblin
gobblin-utility/src/main/java/org/apache/gobblin/util/ConfigUtils.java
ConfigUtils.configToProperties
public static Properties configToProperties(Config config, Optional<String> prefix) { """ Convert a given {@link Config} instance to a {@link Properties} instance. @param config the given {@link Config} instance @param prefix an optional prefix; if present, only properties whose name starts with the prefix wi...
java
public static Properties configToProperties(Config config, Optional<String> prefix) { Properties properties = new Properties(); if (config != null) { Config resolvedConfig = config.resolve(); for (Map.Entry<String, ConfigValue> entry : resolvedConfig.entrySet()) { if (!prefix.isPresent() || ...
[ "public", "static", "Properties", "configToProperties", "(", "Config", "config", ",", "Optional", "<", "String", ">", "prefix", ")", "{", "Properties", "properties", "=", "new", "Properties", "(", ")", ";", "if", "(", "config", "!=", "null", ")", "{", "Con...
Convert a given {@link Config} instance to a {@link Properties} instance. @param config the given {@link Config} instance @param prefix an optional prefix; if present, only properties whose name starts with the prefix will be returned. @return a {@link Properties} instance
[ "Convert", "a", "given", "{", "@link", "Config", "}", "instance", "to", "a", "{", "@link", "Properties", "}", "instance", "." ]
train
https://github.com/apache/incubator-gobblin/blob/f029b4c0fea0fe4aa62f36dda2512344ff708bae/gobblin-utility/src/main/java/org/apache/gobblin/util/ConfigUtils.java#L99-L112
windup/windup
reporting/api/src/main/java/org/jboss/windup/reporting/service/EffortReportService.java
EffortReportService.getEffortLevelDescription
public static String getEffortLevelDescription(Verbosity verbosity, int points) { """ Returns the right string representation of the effort level based on given number of points. """ EffortLevel level = EffortLevel.forPoints(points); switch (verbosity) { case ID: re...
java
public static String getEffortLevelDescription(Verbosity verbosity, int points) { EffortLevel level = EffortLevel.forPoints(points); switch (verbosity) { case ID: return level.name(); case VERBOSE: return level.getVerboseDescription(); case SH...
[ "public", "static", "String", "getEffortLevelDescription", "(", "Verbosity", "verbosity", ",", "int", "points", ")", "{", "EffortLevel", "level", "=", "EffortLevel", ".", "forPoints", "(", "points", ")", ";", "switch", "(", "verbosity", ")", "{", "case", "ID",...
Returns the right string representation of the effort level based on given number of points.
[ "Returns", "the", "right", "string", "representation", "of", "the", "effort", "level", "based", "on", "given", "number", "of", "points", "." ]
train
https://github.com/windup/windup/blob/6668f09e7f012d24a0b4212ada8809417225b2ad/reporting/api/src/main/java/org/jboss/windup/reporting/service/EffortReportService.java#L75-L89
jmapper-framework/jmapper-core
JMapper Framework/src/main/java/com/googlecode/jmapper/util/ClassesManager.java
ClassesManager.isPutAllPermitted
public static boolean isPutAllPermitted(Field destination,Field source) { """ this method verify that the istruction: <p><code> destination.putAll(source) </code><p>is permitted @param destination destination field @param source source field @return true if the istruction destination.putAll(source) is permit...
java
public static boolean isPutAllPermitted(Field destination,Field source){ boolean isFirst = true; boolean isAddAllFunction = false; boolean isPutAllFunction = true; return isAssignableFrom(getGenericString(destination), getGenericString(source), destination.getType(), source.getType(), isFirst, isAddAllF...
[ "public", "static", "boolean", "isPutAllPermitted", "(", "Field", "destination", ",", "Field", "source", ")", "{", "boolean", "isFirst", "=", "true", ";", "boolean", "isAddAllFunction", "=", "false", ";", "boolean", "isPutAllFunction", "=", "true", ";", "return"...
this method verify that the istruction: <p><code> destination.putAll(source) </code><p>is permitted @param destination destination field @param source source field @return true if the istruction destination.putAll(source) is permitted
[ "this", "method", "verify", "that", "the", "istruction", ":", "<p", ">", "<code", ">", "destination", ".", "putAll", "(", "source", ")", "<", "/", "code", ">", "<p", ">", "is", "permitted" ]
train
https://github.com/jmapper-framework/jmapper-core/blob/b48fd3527f35055b8b4a30f53a51136f183acc90/JMapper Framework/src/main/java/com/googlecode/jmapper/util/ClassesManager.java#L64-L71
molgenis/molgenis
molgenis-data-validation/src/main/java/org/molgenis/data/validation/meta/NameValidator.java
NameValidator.validateAttributeName
public static void validateAttributeName(String name) { """ Validates names of entities, packages and attributes. Rules: only [a-zA-Z0-9_#] are allowed, name must start with a letter """ checkForKeyword(name); validateName(name); if (!name.matches("[a-zA-Z0-9_#]+(-[a-z]{2,3})??$")) { throw...
java
public static void validateAttributeName(String name) { checkForKeyword(name); validateName(name); if (!name.matches("[a-zA-Z0-9_#]+(-[a-z]{2,3})??$")) { throw new MolgenisDataException( "Invalid characters in: [" + name + "] Only letters (a-z, A-Z), digits (0-9...
[ "public", "static", "void", "validateAttributeName", "(", "String", "name", ")", "{", "checkForKeyword", "(", "name", ")", ";", "validateName", "(", "name", ")", ";", "if", "(", "!", "name", ".", "matches", "(", "\"[a-zA-Z0-9_#]+(-[a-z]{2,3})??$\"", ")", ")", ...
Validates names of entities, packages and attributes. Rules: only [a-zA-Z0-9_#] are allowed, name must start with a letter
[ "Validates", "names", "of", "entities", "packages", "and", "attributes", ".", "Rules", ":", "only", "[", "a", "-", "zA", "-", "Z0", "-", "9_#", "]", "are", "allowed", "name", "must", "start", "with", "a", "letter" ]
train
https://github.com/molgenis/molgenis/blob/b4d0d6b27e6f6c8d7505a3863dc03b589601f987/molgenis-data-validation/src/main/java/org/molgenis/data/validation/meta/NameValidator.java#L28-L39
belaban/JGroups
src/org/jgroups/protocols/AUTH.java
AUTH.handleAuthHeader
protected boolean handleAuthHeader(GMS.GmsHeader gms_hdr, AuthHeader auth_hdr, Message msg) { """ Handles a GMS header @param gms_hdr @param msg @return true if the message should be passed up, or else false """ if(needsAuthentication(gms_hdr)) { if(this.auth_token.authenticate(auth_hdr....
java
protected boolean handleAuthHeader(GMS.GmsHeader gms_hdr, AuthHeader auth_hdr, Message msg) { if(needsAuthentication(gms_hdr)) { if(this.auth_token.authenticate(auth_hdr.getToken(), msg)) return true; // authentication passed, send message up the stack else { ...
[ "protected", "boolean", "handleAuthHeader", "(", "GMS", ".", "GmsHeader", "gms_hdr", ",", "AuthHeader", "auth_hdr", ",", "Message", "msg", ")", "{", "if", "(", "needsAuthentication", "(", "gms_hdr", ")", ")", "{", "if", "(", "this", ".", "auth_token", ".", ...
Handles a GMS header @param gms_hdr @param msg @return true if the message should be passed up, or else false
[ "Handles", "a", "GMS", "header" ]
train
https://github.com/belaban/JGroups/blob/bd3ca786aa57fed41dfbc10a94b1281e388be03b/src/org/jgroups/protocols/AUTH.java#L214-L227
calrissian/mango
mango-core/src/main/java/org/calrissian/mango/net/MoreInetAddresses.java
MoreInetAddresses.forIPv6String
public static Inet6Address forIPv6String(String ipString) { """ Generates a new {@link Inet6Address} instance from the provided address. This will NOT do a dns lookup on the address if it does not represent a valid ip address like {@code InetAddress.getByName()}. If the provided string is an ipv4 "mapped" addr...
java
public static Inet6Address forIPv6String(String ipString) { requireNonNull(ipString); try{ InetAddress parsed = forString(ipString); if (parsed instanceof Inet6Address) return (Inet6Address) parsed; } catch(Exception ignored){} throw new Illega...
[ "public", "static", "Inet6Address", "forIPv6String", "(", "String", "ipString", ")", "{", "requireNonNull", "(", "ipString", ")", ";", "try", "{", "InetAddress", "parsed", "=", "forString", "(", "ipString", ")", ";", "if", "(", "parsed", "instanceof", "Inet6Ad...
Generates a new {@link Inet6Address} instance from the provided address. This will NOT do a dns lookup on the address if it does not represent a valid ip address like {@code InetAddress.getByName()}. If the provided string is an ipv4 "mapped" address ('ffff:x.x.x.x' this method will still generate a valid {@link Inet6...
[ "Generates", "a", "new", "{", "@link", "Inet6Address", "}", "instance", "from", "the", "provided", "address", ".", "This", "will", "NOT", "do", "a", "dns", "lookup", "on", "the", "address", "if", "it", "does", "not", "represent", "a", "valid", "ip", "add...
train
https://github.com/calrissian/mango/blob/a95aa5e77af9aa0e629787228d80806560023452/mango-core/src/main/java/org/calrissian/mango/net/MoreInetAddresses.java#L140-L152
thinkaurelius/faunus
src/main/java/com/thinkaurelius/faunus/FaunusPipeline.java
FaunusPipeline.linkIn
public FaunusPipeline linkIn(final String label, final String step, final String mergeWeightKey) { """ Have the elements for the named step previous project an edge to the current vertex with provided label. If a merge weight key is provided, then count the number of duplicate edges between the same two vertices ...
java
public FaunusPipeline linkIn(final String label, final String step, final String mergeWeightKey) { return this.link(IN, label, step, mergeWeightKey); }
[ "public", "FaunusPipeline", "linkIn", "(", "final", "String", "label", ",", "final", "String", "step", ",", "final", "String", "mergeWeightKey", ")", "{", "return", "this", ".", "link", "(", "IN", ",", "label", ",", "step", ",", "mergeWeightKey", ")", ";",...
Have the elements for the named step previous project an edge to the current vertex with provided label. If a merge weight key is provided, then count the number of duplicate edges between the same two vertices and add a weight. No weight key is specified by "_" and then all duplicates are merged, but no weight is adde...
[ "Have", "the", "elements", "for", "the", "named", "step", "previous", "project", "an", "edge", "to", "the", "current", "vertex", "with", "provided", "label", ".", "If", "a", "merge", "weight", "key", "is", "provided", "then", "count", "the", "number", "of"...
train
https://github.com/thinkaurelius/faunus/blob/1eb8494eeb3fe3b84a98d810d304ba01d55b0d6e/src/main/java/com/thinkaurelius/faunus/FaunusPipeline.java#L831-L833
Azure/azure-sdk-for-java
sql/resource-manager/v2015_05_01_preview/src/main/java/com/microsoft/azure/management/sql/v2015_05_01_preview/implementation/SyncGroupsInner.java
SyncGroupsInner.triggerSyncAsync
public Observable<Void> triggerSyncAsync(String resourceGroupName, String serverName, String databaseName, String syncGroupName) { """ Triggers a sync group synchronization. @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Mana...
java
public Observable<Void> triggerSyncAsync(String resourceGroupName, String serverName, String databaseName, String syncGroupName) { return triggerSyncWithServiceResponseAsync(resourceGroupName, serverName, databaseName, syncGroupName).map(new Func1<ServiceResponse<Void>, Void>() { @Override ...
[ "public", "Observable", "<", "Void", ">", "triggerSyncAsync", "(", "String", "resourceGroupName", ",", "String", "serverName", ",", "String", "databaseName", ",", "String", "syncGroupName", ")", "{", "return", "triggerSyncWithServiceResponseAsync", "(", "resourceGroupNa...
Triggers a sync group synchronization. @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. @param serverName The name of the server. @param databaseName The name of the database on which the sync group is hoste...
[ "Triggers", "a", "sync", "group", "synchronization", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/sql/resource-manager/v2015_05_01_preview/src/main/java/com/microsoft/azure/management/sql/v2015_05_01_preview/implementation/SyncGroupsInner.java#L1044-L1051
aws/aws-sdk-java
aws-java-sdk-dynamodb/src/main/java/com/amazonaws/services/dynamodbv2/document/spec/ScanSpec.java
ScanSpec.withNameMap
public ScanSpec withNameMap(Map<String, String> nameMap) { """ Applicable only when an expression has been specified. Used to specify the actual values for the attribute-name placeholders, where the value in the map can either be string for simple attribute name, or a JSON path expression. @see ScanRequest#w...
java
public ScanSpec withNameMap(Map<String, String> nameMap) { if (nameMap == null) this.nameMap = null; else this.nameMap = Collections.unmodifiableMap(new LinkedHashMap<String, String>(nameMap)); return this; }
[ "public", "ScanSpec", "withNameMap", "(", "Map", "<", "String", ",", "String", ">", "nameMap", ")", "{", "if", "(", "nameMap", "==", "null", ")", "this", ".", "nameMap", "=", "null", ";", "else", "this", ".", "nameMap", "=", "Collections", ".", "unmodi...
Applicable only when an expression has been specified. Used to specify the actual values for the attribute-name placeholders, where the value in the map can either be string for simple attribute name, or a JSON path expression. @see ScanRequest#withExpressionAttributeNames(Map)
[ "Applicable", "only", "when", "an", "expression", "has", "been", "specified", ".", "Used", "to", "specify", "the", "actual", "values", "for", "the", "attribute", "-", "name", "placeholders", "where", "the", "value", "in", "the", "map", "can", "either", "be",...
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-dynamodb/src/main/java/com/amazonaws/services/dynamodbv2/document/spec/ScanSpec.java#L163-L169
mapfish/mapfish-print
core/src/main/java/org/mapfish/print/parser/OneOfTracker.java
OneOfTracker.markAsVisited
public void markAsVisited(final Field field) { """ Check if a field is part of a {@link org.mapfish.print.parser.OneOf} relationship and mark the group as satisfied. @param field the field that is done. """ final OneOf oneOfAnnotation = field.getAnnotation(OneOf.class); if (oneOfAnnotation ...
java
public void markAsVisited(final Field field) { final OneOf oneOfAnnotation = field.getAnnotation(OneOf.class); if (oneOfAnnotation != null) { final OneOfGroup oneOfGroup = this.mapping.get(oneOfAnnotation.value()); oneOfGroup.satisfiedBy.add(new OneOfSatisfier(field, false)); ...
[ "public", "void", "markAsVisited", "(", "final", "Field", "field", ")", "{", "final", "OneOf", "oneOfAnnotation", "=", "field", ".", "getAnnotation", "(", "OneOf", ".", "class", ")", ";", "if", "(", "oneOfAnnotation", "!=", "null", ")", "{", "final", "OneO...
Check if a field is part of a {@link org.mapfish.print.parser.OneOf} relationship and mark the group as satisfied. @param field the field that is done.
[ "Check", "if", "a", "field", "is", "part", "of", "a", "{", "@link", "org", ".", "mapfish", ".", "print", ".", "parser", ".", "OneOf", "}", "relationship", "and", "mark", "the", "group", "as", "satisfied", "." ]
train
https://github.com/mapfish/mapfish-print/blob/25a452cb39f592bd8a53b20db1037703898e1e22/core/src/main/java/org/mapfish/print/parser/OneOfTracker.java#L56-L67
Azure/azure-sdk-for-java
logic/resource-manager/v2016_06_01/src/main/java/com/microsoft/azure/management/logic/v2016_06_01/implementation/WorkflowRunActionsInner.java
WorkflowRunActionsInner.getAsync
public Observable<WorkflowRunActionInner> getAsync(String resourceGroupName, String workflowName, String runName, String actionName) { """ Gets a workflow run action. @param resourceGroupName The resource group name. @param workflowName The workflow name. @param runName The workflow run name. @param actionNa...
java
public Observable<WorkflowRunActionInner> getAsync(String resourceGroupName, String workflowName, String runName, String actionName) { return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).map(new Func1<ServiceResponse<WorkflowRunActionInner>, WorkflowRunActionInner>() { ...
[ "public", "Observable", "<", "WorkflowRunActionInner", ">", "getAsync", "(", "String", "resourceGroupName", ",", "String", "workflowName", ",", "String", "runName", ",", "String", "actionName", ")", "{", "return", "getWithServiceResponseAsync", "(", "resourceGroupName",...
Gets a workflow run action. @param resourceGroupName The resource group name. @param workflowName The workflow name. @param runName The workflow run name. @param actionName The workflow action name. @throws IllegalArgumentException thrown if parameters fail the validation @return the observable to the WorkflowRunActio...
[ "Gets", "a", "workflow", "run", "action", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/logic/resource-manager/v2016_06_01/src/main/java/com/microsoft/azure/management/logic/v2016_06_01/implementation/WorkflowRunActionsInner.java#L387-L394
JOML-CI/JOML
src/org/joml/Vector2i.java
Vector2i.set
public Vector2i set(int index, IntBuffer buffer) { """ Read this vector from the supplied {@link IntBuffer} starting at the specified absolute buffer position/index. <p> This method will not increment the position of the given IntBuffer. @param index the absolute position into the IntBuffer @param buffer ...
java
public Vector2i set(int index, IntBuffer buffer) { MemUtil.INSTANCE.get(this, index, buffer); return this; }
[ "public", "Vector2i", "set", "(", "int", "index", ",", "IntBuffer", "buffer", ")", "{", "MemUtil", ".", "INSTANCE", ".", "get", "(", "this", ",", "index", ",", "buffer", ")", ";", "return", "this", ";", "}" ]
Read this vector from the supplied {@link IntBuffer} starting at the specified absolute buffer position/index. <p> This method will not increment the position of the given IntBuffer. @param index the absolute position into the IntBuffer @param buffer values will be read in <code>x, y</code> order @return this
[ "Read", "this", "vector", "from", "the", "supplied", "{", "@link", "IntBuffer", "}", "starting", "at", "the", "specified", "absolute", "buffer", "position", "/", "index", ".", "<p", ">", "This", "method", "will", "not", "increment", "the", "position", "of", ...
train
https://github.com/JOML-CI/JOML/blob/ce2652fc236b42bda3875c591f8e6645048a678f/src/org/joml/Vector2i.java#L318-L321
fcrepo3/fcrepo
fcrepo-client/fcrepo-client-admin/src/main/java/org/fcrepo/client/FedoraClient.java
FedoraClient.uploadFile
public String uploadFile(File file) throws IOException { """ Upload the given file to Fedora's upload interface via HTTP POST. @return the temporary id which can then be passed to API-M requests as a URL. It will look like uploaded://123 """ HttpPost post = null; try { // prepar...
java
public String uploadFile(File file) throws IOException { HttpPost post = null; try { // prepare the post method post = new HttpPost(getUploadURL()); post.getParams().setParameter("Connection", "Keep-Alive"); // add the file part MultipartEntit...
[ "public", "String", "uploadFile", "(", "File", "file", ")", "throws", "IOException", "{", "HttpPost", "post", "=", "null", ";", "try", "{", "// prepare the post method", "post", "=", "new", "HttpPost", "(", "getUploadURL", "(", ")", ")", ";", "post", ".", ...
Upload the given file to Fedora's upload interface via HTTP POST. @return the temporary id which can then be passed to API-M requests as a URL. It will look like uploaded://123
[ "Upload", "the", "given", "file", "to", "Fedora", "s", "upload", "interface", "via", "HTTP", "POST", "." ]
train
https://github.com/fcrepo3/fcrepo/blob/37df51b9b857fd12c6ab8269820d406c3c4ad774/fcrepo-client/fcrepo-client-admin/src/main/java/org/fcrepo/client/FedoraClient.java#L232-L271
lessthanoptimal/ejml
main/ejml-zdense/src/org/ejml/dense/row/CommonOps_ZDRM.java
CommonOps_ZDRM.multTransB
public static void multTransB(double realAlpha , double imagAlpha, ZMatrixRMaj a , ZMatrixRMaj b , ZMatrixRMaj c ) { """ <p> Performs the following operation:<br> <br> c = &alpha; * a * b<sup>H</sup> <br> c<sub>ij</sub> = &alpha; &sum;<sub>k=1:n</sub> { a<sub>ik</sub> * b<sub>jk</sub>} </p> @param realAl...
java
public static void multTransB(double realAlpha , double imagAlpha, ZMatrixRMaj a , ZMatrixRMaj b , ZMatrixRMaj c ) { // TODO add a matrix vectory multiply here MatrixMatrixMult_ZDRM.multTransB(realAlpha,imagAlpha,a,b,c); }
[ "public", "static", "void", "multTransB", "(", "double", "realAlpha", ",", "double", "imagAlpha", ",", "ZMatrixRMaj", "a", ",", "ZMatrixRMaj", "b", ",", "ZMatrixRMaj", "c", ")", "{", "// TODO add a matrix vectory multiply here", "MatrixMatrixMult_ZDRM", ".", "multTran...
<p> Performs the following operation:<br> <br> c = &alpha; * a * b<sup>H</sup> <br> c<sub>ij</sub> = &alpha; &sum;<sub>k=1:n</sub> { a<sub>ik</sub> * b<sub>jk</sub>} </p> @param realAlpha Real component of scaling factor. @param imagAlpha Imaginary component of scaling factor. @param a The left matrix in the multipl...
[ "<p", ">", "Performs", "the", "following", "operation", ":", "<br", ">", "<br", ">", "c", "=", "&alpha", ";", "*", "a", "*", "b<sup", ">", "H<", "/", "sup", ">", "<br", ">", "c<sub", ">", "ij<", "/", "sub", ">", "=", "&alpha", ";", "&sum", ";",...
train
https://github.com/lessthanoptimal/ejml/blob/1444680cc487af5e866730e62f48f5f9636850d9/main/ejml-zdense/src/org/ejml/dense/row/CommonOps_ZDRM.java#L520-L524
facebookarchive/hadoop-20
src/hdfs/org/apache/hadoop/hdfs/server/namenode/FSNamesystem.java
FSNamesystem.replicateLastBlock
private void replicateLastBlock(String src, INodeFileUnderConstruction file) { """ Check last block of the file under construction Replicate it if it is under replicated @param src the file name @param file the file's inode """ BlockInfo[] blks = file.getBlocks(); if (blks == null || blks.length == ...
java
private void replicateLastBlock(String src, INodeFileUnderConstruction file) { BlockInfo[] blks = file.getBlocks(); if (blks == null || blks.length == 0) return; BlockInfo block = blks[blks.length-1]; DatanodeDescriptor[] targets = file.getValidTargets(); final int numOfTargets = targets == nu...
[ "private", "void", "replicateLastBlock", "(", "String", "src", ",", "INodeFileUnderConstruction", "file", ")", "{", "BlockInfo", "[", "]", "blks", "=", "file", ".", "getBlocks", "(", ")", ";", "if", "(", "blks", "==", "null", "||", "blks", ".", "length", ...
Check last block of the file under construction Replicate it if it is under replicated @param src the file name @param file the file's inode
[ "Check", "last", "block", "of", "the", "file", "under", "construction", "Replicate", "it", "if", "it", "is", "under", "replicated" ]
train
https://github.com/facebookarchive/hadoop-20/blob/2a29bc6ecf30edb1ad8dbde32aa49a317b4d44f4/src/hdfs/org/apache/hadoop/hdfs/server/namenode/FSNamesystem.java#L2890-L2923
cvut/JCOP
src/main/java/cz/cvut/felk/cig/jcop/problem/tsp/City.java
City.addDistance
public City addDistance(City city, Integer distance) { """ Adds new distance to city. @param city target city @param distance distance to city @return self, fluent interface """ this.distances.put(city, distance); return this; }
java
public City addDistance(City city, Integer distance) { this.distances.put(city, distance); return this; }
[ "public", "City", "addDistance", "(", "City", "city", ",", "Integer", "distance", ")", "{", "this", ".", "distances", ".", "put", "(", "city", ",", "distance", ")", ";", "return", "this", ";", "}" ]
Adds new distance to city. @param city target city @param distance distance to city @return self, fluent interface
[ "Adds", "new", "distance", "to", "city", "." ]
train
https://github.com/cvut/JCOP/blob/2ec18315a9a452e5f4e3d07cccfde0310adc465a/src/main/java/cz/cvut/felk/cig/jcop/problem/tsp/City.java#L67-L70
prestodb/presto
presto-main/src/main/java/com/facebook/presto/operator/TableFinishOperator.java
TableFinishOperator.isStatisticsPosition
private static boolean isStatisticsPosition(Page page, int position) { """ Both the statistics and the row_count + fragments are transferred over the same communication link between the TableWriterOperator and the TableFinishOperator. Thus the multiplexing is needed. <p> The transferred page layout looks like: ...
java
private static boolean isStatisticsPosition(Page page, int position) { return page.getBlock(ROW_COUNT_CHANNEL).isNull(position) && page.getBlock(FRAGMENT_CHANNEL).isNull(position); }
[ "private", "static", "boolean", "isStatisticsPosition", "(", "Page", "page", ",", "int", "position", ")", "{", "return", "page", ".", "getBlock", "(", "ROW_COUNT_CHANNEL", ")", ".", "isNull", "(", "position", ")", "&&", "page", ".", "getBlock", "(", "FRAGMEN...
Both the statistics and the row_count + fragments are transferred over the same communication link between the TableWriterOperator and the TableFinishOperator. Thus the multiplexing is needed. <p> The transferred page layout looks like: <p> [[row_count_channel], [fragment_channel], [statistic_channel_1] ... [statistic_...
[ "Both", "the", "statistics", "and", "the", "row_count", "+", "fragments", "are", "transferred", "over", "the", "same", "communication", "link", "between", "the", "TableWriterOperator", "and", "the", "TableFinishOperator", ".", "Thus", "the", "multiplexing", "is", ...
train
https://github.com/prestodb/presto/blob/89de5e379d8f85e139d292b0add8c537a2a01a88/presto-main/src/main/java/com/facebook/presto/operator/TableFinishOperator.java#L263-L266
Mozu/mozu-java
mozu-java-core/src/main/java/com/mozu/api/urls/commerce/orders/RefundUrl.java
RefundUrl.resendRefundEmailUrl
public static MozuUrl resendRefundEmailUrl(String orderId, String refundId) { """ Get Resource Url for ResendRefundEmail @param orderId Unique identifier of the order. @param refundId Unique ID of the refund. @return String Resource Url """ UrlFormatter formatter = new UrlFormatter("/api/commerce/ord...
java
public static MozuUrl resendRefundEmailUrl(String orderId, String refundId) { UrlFormatter formatter = new UrlFormatter("/api/commerce/orders/{orderId}/refunds/{refundId}"); formatter.formatUrl("orderId", orderId); formatter.formatUrl("refundId", refundId); return new MozuUrl(formatter.getResourceUrl(), M...
[ "public", "static", "MozuUrl", "resendRefundEmailUrl", "(", "String", "orderId", ",", "String", "refundId", ")", "{", "UrlFormatter", "formatter", "=", "new", "UrlFormatter", "(", "\"/api/commerce/orders/{orderId}/refunds/{refundId}\"", ")", ";", "formatter", ".", "form...
Get Resource Url for ResendRefundEmail @param orderId Unique identifier of the order. @param refundId Unique ID of the refund. @return String Resource Url
[ "Get", "Resource", "Url", "for", "ResendRefundEmail", "@param", "orderId", "Unique", "identifier", "of", "the", "order", ".", "@param", "refundId", "Unique", "ID", "of", "the", "refund", "." ]
train
https://github.com/Mozu/mozu-java/blob/5beadde73601a859f845e3e2fc1077b39c8bea83/mozu-java-core/src/main/java/com/mozu/api/urls/commerce/orders/RefundUrl.java#L37-L43
google/j2objc
jre_emul/android/platform/libcore/ojluni/src/main/java/java/awt/font/NumericShaper.java
NumericShaper.shape
public void shape(char[] text, int start, int count) { """ Converts the digits in the text that occur between start and start + count. @param text an array of characters to convert @param start the index into <code>text</code> to start converting @param count the number of characters in <code>text</code> to ...
java
public void shape(char[] text, int start, int count) { checkParams(text, start, count); if (isContextual()) { if (rangeSet == null) { shapeContextually(text, start, count, key); } else { shapeContextually(text, start, count, shapingRange); ...
[ "public", "void", "shape", "(", "char", "[", "]", "text", ",", "int", "start", ",", "int", "count", ")", "{", "checkParams", "(", "text", ",", "start", ",", "count", ")", ";", "if", "(", "isContextual", "(", ")", ")", "{", "if", "(", "rangeSet", ...
Converts the digits in the text that occur between start and start + count. @param text an array of characters to convert @param start the index into <code>text</code> to start converting @param count the number of characters in <code>text</code> to convert @throws IndexOutOfBoundsException if start or start + count is...
[ "Converts", "the", "digits", "in", "the", "text", "that", "occur", "between", "start", "and", "start", "+", "count", "." ]
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/awt/font/NumericShaper.java#L1100-L1111
biojava/biojava
biojava-survival/src/main/java/org/biojava/nbio/survival/data/WorkSheet.java
WorkSheet.getLogScale
public WorkSheet getLogScale(double base, double zeroValue) throws Exception { """ Get the log scale of this worksheet @param base @return @throws Exception """ WorkSheet workSheet = new WorkSheet(getRows(), getColumns()); workSheet.setIndexColumnName(this.getIndexColumnName()); ArrayList<String> r...
java
public WorkSheet getLogScale(double base, double zeroValue) throws Exception { WorkSheet workSheet = new WorkSheet(getRows(), getColumns()); workSheet.setIndexColumnName(this.getIndexColumnName()); ArrayList<String> rows = getRows(); ArrayList<String> columns = getColumns(); for (String row : rows) { for ...
[ "public", "WorkSheet", "getLogScale", "(", "double", "base", ",", "double", "zeroValue", ")", "throws", "Exception", "{", "WorkSheet", "workSheet", "=", "new", "WorkSheet", "(", "getRows", "(", ")", ",", "getColumns", "(", ")", ")", ";", "workSheet", ".", ...
Get the log scale of this worksheet @param base @return @throws Exception
[ "Get", "the", "log", "scale", "of", "this", "worksheet" ]
train
https://github.com/biojava/biojava/blob/a1c71a8e3d40cc32104b1d387a3d3b560b43356e/biojava-survival/src/main/java/org/biojava/nbio/survival/data/WorkSheet.java#L1187-L1221
BorderTech/wcomponents
wcomponents-examples/src/main/java/com/github/bordertech/wcomponents/examples/theme/WConfirmationButtonExample.java
WConfirmationButtonExample.addAjaxExample
private void addAjaxExample() { """ This is used to reproduce a WComponents bug condition to make sure we do not re-create it once it is fixed. See https://github.com/BorderTech/wcomponents/issues/1266. """ add(new WHeading(HeadingLevel.H2, "Confirm as ajax trigger")); final String before = "Before"; fi...
java
private void addAjaxExample() { add(new WHeading(HeadingLevel.H2, "Confirm as ajax trigger")); final String before = "Before"; final String after = "After"; final WText ajaxContent = new WText("Before"); final WPanel target = new WPanel(WPanel.Type.BOX); add(target); target.add(ajaxContent); WButton c...
[ "private", "void", "addAjaxExample", "(", ")", "{", "add", "(", "new", "WHeading", "(", "HeadingLevel", ".", "H2", ",", "\"Confirm as ajax trigger\"", ")", ")", ";", "final", "String", "before", "=", "\"Before\"", ";", "final", "String", "after", "=", "\"Aft...
This is used to reproduce a WComponents bug condition to make sure we do not re-create it once it is fixed. See https://github.com/BorderTech/wcomponents/issues/1266.
[ "This", "is", "used", "to", "reproduce", "a", "WComponents", "bug", "condition", "to", "make", "sure", "we", "do", "not", "re", "-", "create", "it", "once", "it", "is", "fixed", ".", "See", "https", ":", "//", "github", ".", "com", "/", "BorderTech", ...
train
https://github.com/BorderTech/wcomponents/blob/d1a2b2243270067db030feb36ca74255aaa94436/wcomponents-examples/src/main/java/com/github/bordertech/wcomponents/examples/theme/WConfirmationButtonExample.java#L87-L107
elki-project/elki
addons/batikvis/src/main/java/de/lmu/ifi/dbs/elki/visualization/svg/SVGPath.java
SVGPath.cubicTo
public SVGPath cubicTo(double[] c1xy, double[] c2xy, double[] xy) { """ Cubic Bezier line to the given coordinates. @param c1xy first control point @param c2xy second control point @param xy new coordinates @return path object, for compact syntax. """ return append(PATH_CUBIC_TO).append(c1xy[0]).appe...
java
public SVGPath cubicTo(double[] c1xy, double[] c2xy, double[] xy) { return append(PATH_CUBIC_TO).append(c1xy[0]).append(c1xy[1]).append(c2xy[0]).append(c2xy[1]).append(xy[0]).append(xy[1]); }
[ "public", "SVGPath", "cubicTo", "(", "double", "[", "]", "c1xy", ",", "double", "[", "]", "c2xy", ",", "double", "[", "]", "xy", ")", "{", "return", "append", "(", "PATH_CUBIC_TO", ")", ".", "append", "(", "c1xy", "[", "0", "]", ")", ".", "append",...
Cubic Bezier line to the given coordinates. @param c1xy first control point @param c2xy second control point @param xy new coordinates @return path object, for compact syntax.
[ "Cubic", "Bezier", "line", "to", "the", "given", "coordinates", "." ]
train
https://github.com/elki-project/elki/blob/b54673327e76198ecd4c8a2a901021f1a9174498/addons/batikvis/src/main/java/de/lmu/ifi/dbs/elki/visualization/svg/SVGPath.java#L369-L371
Azure/azure-sdk-for-java
network/resource-manager/v2018_07_01/src/main/java/com/microsoft/azure/management/network/v2018_07_01/implementation/NetworkInterfacesInner.java
NetworkInterfacesInner.getEffectiveRouteTable
public EffectiveRouteListResultInner getEffectiveRouteTable(String resourceGroupName, String networkInterfaceName) { """ Gets all route tables applied to a network interface. @param resourceGroupName The name of the resource group. @param networkInterfaceName The name of the network interface. @throws Illegal...
java
public EffectiveRouteListResultInner getEffectiveRouteTable(String resourceGroupName, String networkInterfaceName) { return getEffectiveRouteTableWithServiceResponseAsync(resourceGroupName, networkInterfaceName).toBlocking().last().body(); }
[ "public", "EffectiveRouteListResultInner", "getEffectiveRouteTable", "(", "String", "resourceGroupName", ",", "String", "networkInterfaceName", ")", "{", "return", "getEffectiveRouteTableWithServiceResponseAsync", "(", "resourceGroupName", ",", "networkInterfaceName", ")", ".", ...
Gets all route tables applied to a network interface. @param resourceGroupName The name of the resource group. @param networkInterfaceName The name of the network interface. @throws IllegalArgumentException thrown if parameters fail the validation @throws CloudException thrown if the request is rejected by server @thr...
[ "Gets", "all", "route", "tables", "applied", "to", "a", "network", "interface", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/network/resource-manager/v2018_07_01/src/main/java/com/microsoft/azure/management/network/v2018_07_01/implementation/NetworkInterfacesInner.java#L1192-L1194
google/error-prone-javac
src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/HtmlSerialFieldWriter.java
HtmlSerialFieldWriter.addMemberTags
public void addMemberTags(FieldDoc field, Content contentTree) { """ Add the tag information for this member. @param field the field to document. @param contentTree the tree to which the member tags info will be added """ Content tagContent = new ContentBuilder(); TagletWriter.genTagOuput(c...
java
public void addMemberTags(FieldDoc field, Content contentTree) { Content tagContent = new ContentBuilder(); TagletWriter.genTagOuput(configuration.tagletManager, field, configuration.tagletManager.getCustomTaglets(field), writer.getTagletWriterInstance(false), tagContent)...
[ "public", "void", "addMemberTags", "(", "FieldDoc", "field", ",", "Content", "contentTree", ")", "{", "Content", "tagContent", "=", "new", "ContentBuilder", "(", ")", ";", "TagletWriter", ".", "genTagOuput", "(", "configuration", ".", "tagletManager", ",", "fiel...
Add the tag information for this member. @param field the field to document. @param contentTree the tree to which the member tags info will be added
[ "Add", "the", "tag", "information", "for", "this", "member", "." ]
train
https://github.com/google/error-prone-javac/blob/a53d069bbdb2c60232ed3811c19b65e41c3e60e0/src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/HtmlSerialFieldWriter.java#L183-L191
MKLab-ITI/multimedia-indexing
src/main/java/gr/iti/mklab/download/ImageDownloader.java
ImageDownloader.shutDown
public void shutDown() { """ Shuts the download executor down, waiting for up to 60 seconds for the remaining tasks to complete. See http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/ExecutorService.html """ downloadExecutor.shutdown(); // Disable new tasks from being submitted try { // ...
java
public void shutDown() { downloadExecutor.shutdown(); // Disable new tasks from being submitted try { // Wait a while for existing tasks to terminate if (!downloadExecutor.awaitTermination(60, TimeUnit.SECONDS)) { downloadExecutor.shutdownNow(); // Cancel currently executing tasks // Wait a whil...
[ "public", "void", "shutDown", "(", ")", "{", "downloadExecutor", ".", "shutdown", "(", ")", ";", "// Disable new tasks from being submitted\r", "try", "{", "// Wait a while for existing tasks to terminate\r", "if", "(", "!", "downloadExecutor", ".", "awaitTermination", "(...
Shuts the download executor down, waiting for up to 60 seconds for the remaining tasks to complete. See http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/ExecutorService.html
[ "Shuts", "the", "download", "executor", "down", "waiting", "for", "up", "to", "60", "seconds", "for", "the", "remaining", "tasks", "to", "complete", ".", "See", "http", ":", "//", "docs", ".", "oracle", ".", "com", "/", "javase", "/", "7", "/", "docs",...
train
https://github.com/MKLab-ITI/multimedia-indexing/blob/f82e8e517da706651f4b7a719805401f3102e135/src/main/java/gr/iti/mklab/download/ImageDownloader.java#L179-L195
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/permission/UserPermissionDao.java
UserPermissionDao.deleteProjectPermissionOfAnyUser
public int deleteProjectPermissionOfAnyUser(DbSession dbSession, long projectId, String permission) { """ Deletes the specified permission on the specified project for any user. """ return mapper(dbSession).deleteProjectPermissionOfAnyUser(projectId, permission); }
java
public int deleteProjectPermissionOfAnyUser(DbSession dbSession, long projectId, String permission) { return mapper(dbSession).deleteProjectPermissionOfAnyUser(projectId, permission); }
[ "public", "int", "deleteProjectPermissionOfAnyUser", "(", "DbSession", "dbSession", ",", "long", "projectId", ",", "String", "permission", ")", "{", "return", "mapper", "(", "dbSession", ")", ".", "deleteProjectPermissionOfAnyUser", "(", "projectId", ",", "permission"...
Deletes the specified permission on the specified project for any user.
[ "Deletes", "the", "specified", "permission", "on", "the", "specified", "project", "for", "any", "user", "." ]
train
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/permission/UserPermissionDao.java#L137-L139
Azure/azure-sdk-for-java
cognitiveservices/data-plane/vision/customvision/training/src/main/java/com/microsoft/azure/cognitiveservices/vision/customvision/training/implementation/TrainingsImpl.java
TrainingsImpl.createImageRegionsWithServiceResponseAsync
public Observable<ServiceResponse<ImageRegionCreateSummary>> createImageRegionsWithServiceResponseAsync(UUID projectId, CreateImageRegionsOptionalParameter createImageRegionsOptionalParameter) { """ Create a set of image regions. This API accepts a batch of image regions, and optionally tags, to update existing i...
java
public Observable<ServiceResponse<ImageRegionCreateSummary>> createImageRegionsWithServiceResponseAsync(UUID projectId, CreateImageRegionsOptionalParameter createImageRegionsOptionalParameter) { if (projectId == null) { throw new IllegalArgumentException("Parameter projectId is required and cannot b...
[ "public", "Observable", "<", "ServiceResponse", "<", "ImageRegionCreateSummary", ">", ">", "createImageRegionsWithServiceResponseAsync", "(", "UUID", "projectId", ",", "CreateImageRegionsOptionalParameter", "createImageRegionsOptionalParameter", ")", "{", "if", "(", "projectId"...
Create a set of image regions. This API accepts a batch of image regions, and optionally tags, to update existing images with region information. There is a limit of 64 entries in the batch. @param projectId The project id @param createImageRegionsOptionalParameter the object representing the optional parameters to be...
[ "Create", "a", "set", "of", "image", "regions", ".", "This", "API", "accepts", "a", "batch", "of", "image", "regions", "and", "optionally", "tags", "to", "update", "existing", "images", "with", "region", "information", ".", "There", "is", "a", "limit", "of...
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/cognitiveservices/data-plane/vision/customvision/training/src/main/java/com/microsoft/azure/cognitiveservices/vision/customvision/training/implementation/TrainingsImpl.java#L3393-L3403
EvidentSolutions/dalesbred
dalesbred/src/main/java/org/dalesbred/query/SqlQuery.java
SqlQuery.namedQuery
public static @NotNull SqlQuery namedQuery(@NotNull @SQL String sql, @NotNull Map<String, ?> valueMap) { """ Constructs a query with named arguments, using given map for resolving the values of arguments. @see #namedQuery(String, VariableResolver) @see VariableResolver#forMap(Map) """ return namedQ...
java
public static @NotNull SqlQuery namedQuery(@NotNull @SQL String sql, @NotNull Map<String, ?> valueMap) { return namedQuery(sql, VariableResolver.forMap(valueMap)); }
[ "public", "static", "@", "NotNull", "SqlQuery", "namedQuery", "(", "@", "NotNull", "@", "SQL", "String", "sql", ",", "@", "NotNull", "Map", "<", "String", ",", "?", ">", "valueMap", ")", "{", "return", "namedQuery", "(", "sql", ",", "VariableResolver", "...
Constructs a query with named arguments, using given map for resolving the values of arguments. @see #namedQuery(String, VariableResolver) @see VariableResolver#forMap(Map)
[ "Constructs", "a", "query", "with", "named", "arguments", "using", "given", "map", "for", "resolving", "the", "values", "of", "arguments", "." ]
train
https://github.com/EvidentSolutions/dalesbred/blob/713f5b6e152d97e1672ca68b9ff9c7c6c288ceb1/dalesbred/src/main/java/org/dalesbred/query/SqlQuery.java#L81-L83
ops4j/org.ops4j.base
ops4j-base-lang/src/main/java/org/ops4j/lang/NullArgumentException.java
NullArgumentException.validateNotEmpty
public static void validateNotEmpty( Object[] arrayToCheck, String argumentName ) throws NullArgumentException { """ Validates that the array instance is not null and that it has entries. @param arrayToCheck The object to be tested. @param argumentName The name of the object, which is used to construct...
java
public static void validateNotEmpty( Object[] arrayToCheck, String argumentName ) throws NullArgumentException { validateNotNull( arrayToCheck, argumentName ); if( arrayToCheck.length == 0 ) { throw new NullArgumentException( argumentName + IS_EMPTY ); } }
[ "public", "static", "void", "validateNotEmpty", "(", "Object", "[", "]", "arrayToCheck", ",", "String", "argumentName", ")", "throws", "NullArgumentException", "{", "validateNotNull", "(", "arrayToCheck", ",", "argumentName", ")", ";", "if", "(", "arrayToCheck", "...
Validates that the array instance is not null and that it has entries. @param arrayToCheck The object to be tested. @param argumentName The name of the object, which is used to construct the exception message. @throws NullArgumentException if the array instance is null or does not have any entries. @since 0.5.0, Janu...
[ "Validates", "that", "the", "array", "instance", "is", "not", "null", "and", "that", "it", "has", "entries", "." ]
train
https://github.com/ops4j/org.ops4j.base/blob/b0e742c0d9511f6b19ca64da2ebaf30b7a47256a/ops4j-base-lang/src/main/java/org/ops4j/lang/NullArgumentException.java#L140-L148
aws/aws-sdk-java
aws-java-sdk-ssm/src/main/java/com/amazonaws/services/simplesystemsmanagement/model/AssociationOverview.java
AssociationOverview.withAssociationStatusAggregatedCount
public AssociationOverview withAssociationStatusAggregatedCount(java.util.Map<String, Integer> associationStatusAggregatedCount) { """ <p> Returns the number of targets for the association status. For example, if you created an association with two instances, and one of them was successful, this would return the...
java
public AssociationOverview withAssociationStatusAggregatedCount(java.util.Map<String, Integer> associationStatusAggregatedCount) { setAssociationStatusAggregatedCount(associationStatusAggregatedCount); return this; }
[ "public", "AssociationOverview", "withAssociationStatusAggregatedCount", "(", "java", ".", "util", ".", "Map", "<", "String", ",", "Integer", ">", "associationStatusAggregatedCount", ")", "{", "setAssociationStatusAggregatedCount", "(", "associationStatusAggregatedCount", ")"...
<p> Returns the number of targets for the association status. For example, if you created an association with two instances, and one of them was successful, this would return the count of instances by status. </p> @param associationStatusAggregatedCount Returns the number of targets for the association status. For exa...
[ "<p", ">", "Returns", "the", "number", "of", "targets", "for", "the", "association", "status", ".", "For", "example", "if", "you", "created", "an", "association", "with", "two", "instances", "and", "one", "of", "them", "was", "successful", "this", "would", ...
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-ssm/src/main/java/com/amazonaws/services/simplesystemsmanagement/model/AssociationOverview.java#L172-L175
orbisgis/h2gis
h2gis-functions/src/main/java/org/h2gis/functions/io/osm/OSMTablesFactory.java
OSMTablesFactory.createRelationMemberTable
public static PreparedStatement createRelationMemberTable(Connection connection, String relationMemberTable) throws SQLException { """ Store all relation members @param connection @param relationMemberTable @return @throws SQLException """ try (Statement stmt = connection.createStatement()) { ...
java
public static PreparedStatement createRelationMemberTable(Connection connection, String relationMemberTable) throws SQLException { try (Statement stmt = connection.createStatement()) { StringBuilder sb = new StringBuilder("CREATE TABLE "); sb.append(relationMemberTable); sb.a...
[ "public", "static", "PreparedStatement", "createRelationMemberTable", "(", "Connection", "connection", ",", "String", "relationMemberTable", ")", "throws", "SQLException", "{", "try", "(", "Statement", "stmt", "=", "connection", ".", "createStatement", "(", ")", ")", ...
Store all relation members @param connection @param relationMemberTable @return @throws SQLException
[ "Store", "all", "relation", "members" ]
train
https://github.com/orbisgis/h2gis/blob/9cd70b447e6469cecbc2fc64b16774b59491df3b/h2gis-functions/src/main/java/org/h2gis/functions/io/osm/OSMTablesFactory.java#L308-L316
actorapp/actor-platform
actor-sdk/sdk-core/core/core-shared/src/main/java/im/actor/core/util/JavaUtil.java
JavaUtil.equalsE
public static <T> boolean equalsE(T a, T b) { """ Equals with null checking @param a first argument @param b second argument @return is equals result """ if (a == null && b == null) { return true; } if (a != null && b == null) { return false; } ...
java
public static <T> boolean equalsE(T a, T b) { if (a == null && b == null) { return true; } if (a != null && b == null) { return false; } if (a == null) { return false; } return a.equals(b); }
[ "public", "static", "<", "T", ">", "boolean", "equalsE", "(", "T", "a", ",", "T", "b", ")", "{", "if", "(", "a", "==", "null", "&&", "b", "==", "null", ")", "{", "return", "true", ";", "}", "if", "(", "a", "!=", "null", "&&", "b", "==", "nu...
Equals with null checking @param a first argument @param b second argument @return is equals result
[ "Equals", "with", "null", "checking" ]
train
https://github.com/actorapp/actor-platform/blob/5123c1584757c6eeea0ed2a0e7e043629871a0c6/actor-sdk/sdk-core/core/core-shared/src/main/java/im/actor/core/util/JavaUtil.java#L39-L50
gallandarakhneorg/afc
core/inputoutput/src/main/java/org/arakhne/afc/inputoutput/xml/XMLUtil.java
XMLUtil.getAttributeDoubleWithDefault
@Pure public static Double getAttributeDoubleWithDefault(Node document, Double defaultValue, String... path) { """ Replies the double value that corresponds to the specified attribute's path. <p>The path is an ordered list of tag's names and ended by the name of the attribute. Be careful about the fact that ...
java
@Pure public static Double getAttributeDoubleWithDefault(Node document, Double defaultValue, String... path) { assert document != null : AssertMessages.notNullParameter(0); return getAttributeDoubleWithDefault(document, true, defaultValue, path); }
[ "@", "Pure", "public", "static", "Double", "getAttributeDoubleWithDefault", "(", "Node", "document", ",", "Double", "defaultValue", ",", "String", "...", "path", ")", "{", "assert", "document", "!=", "null", ":", "AssertMessages", ".", "notNullParameter", "(", "...
Replies the double value that corresponds to the specified attribute's path. <p>The path is an ordered list of tag's names and ended by the name of the attribute. Be careful about the fact that the names are case sensitives. @param document is the XML document to explore. @param defaultValue is the default value to r...
[ "Replies", "the", "double", "value", "that", "corresponds", "to", "the", "specified", "attribute", "s", "path", "." ]
train
https://github.com/gallandarakhneorg/afc/blob/0c7d2e1ddefd4167ef788416d970a6c1ef6f8bbb/core/inputoutput/src/main/java/org/arakhne/afc/inputoutput/xml/XMLUtil.java#L636-L640
mnlipp/jgrapes
org.jgrapes.http/src/org/jgrapes/http/HttpConnector.java
HttpConnector.onClosed
@Handler(channels = NetworkChannel.class) public void onClosed(Closed event, TcpChannel netConnChannel) { """ Called when the network connection is closed. @param event the event @param netConnChannel the net conn channel """ netConnChannel.associated(WebAppMsgChannel.class).ifPresent( ...
java
@Handler(channels = NetworkChannel.class) public void onClosed(Closed event, TcpChannel netConnChannel) { netConnChannel.associated(WebAppMsgChannel.class).ifPresent( appChannel -> appChannel.handleClosed(event)); pooled.remove(netConnChannel.remoteAddress(), netConnChannel); }
[ "@", "Handler", "(", "channels", "=", "NetworkChannel", ".", "class", ")", "public", "void", "onClosed", "(", "Closed", "event", ",", "TcpChannel", "netConnChannel", ")", "{", "netConnChannel", ".", "associated", "(", "WebAppMsgChannel", ".", "class", ")", "."...
Called when the network connection is closed. @param event the event @param netConnChannel the net conn channel
[ "Called", "when", "the", "network", "connection", "is", "closed", "." ]
train
https://github.com/mnlipp/jgrapes/blob/8b5d874935d84c34a52d3e3d3745e869b5203fa0/org.jgrapes.http/src/org/jgrapes/http/HttpConnector.java#L255-L260
OpenLiberty/open-liberty
dev/com.ibm.ws.classloading/src/com/ibm/ws/classloading/internal/Util.java
Util.ensureNotNull
static <T> T ensureNotNull(String msg, T t) throws ClassLoadingConfigurationException { """ Check that the parameter is not null. @param msg the exception message to use if the parameter is null @return the parameter if it isn't null @throws ClassLoadingConfigurationException if the parameter is null """ ...
java
static <T> T ensureNotNull(String msg, T t) throws ClassLoadingConfigurationException { ensure(msg, t != null); return t; }
[ "static", "<", "T", ">", "T", "ensureNotNull", "(", "String", "msg", ",", "T", "t", ")", "throws", "ClassLoadingConfigurationException", "{", "ensure", "(", "msg", ",", "t", "!=", "null", ")", ";", "return", "t", ";", "}" ]
Check that the parameter is not null. @param msg the exception message to use if the parameter is null @return the parameter if it isn't null @throws ClassLoadingConfigurationException if the parameter is null
[ "Check", "that", "the", "parameter", "is", "not", "null", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.classloading/src/com/ibm/ws/classloading/internal/Util.java#L45-L48
apache/groovy
subprojects/groovy-json/src/main/java/groovy/json/JsonBuilder.java
JsonBuilder.call
public Object call(Iterable coll, Closure c) { """ A collection and closure passed to a JSON builder will create a root JSON array applying the closure to each object in the collection <p> Example: <pre><code class="groovyTestCase"> class Author { String name } def authors = [new Author (name: "Guillaume")...
java
public Object call(Iterable coll, Closure c) { List<Object> listContent = new ArrayList<Object>(); if (coll != null) { for (Object it : coll) { listContent.add(JsonDelegate.curryDelegateAndGetContent(c, it)); } } content = listContent; ret...
[ "public", "Object", "call", "(", "Iterable", "coll", ",", "Closure", "c", ")", "{", "List", "<", "Object", ">", "listContent", "=", "new", "ArrayList", "<", "Object", ">", "(", ")", ";", "if", "(", "coll", "!=", "null", ")", "{", "for", "(", "Objec...
A collection and closure passed to a JSON builder will create a root JSON array applying the closure to each object in the collection <p> Example: <pre><code class="groovyTestCase"> class Author { String name } def authors = [new Author (name: "Guillaume"), new Author (name: "Jochen"), new Author (name: "Paul")] def j...
[ "A", "collection", "and", "closure", "passed", "to", "a", "JSON", "builder", "will", "create", "a", "root", "JSON", "array", "applying", "the", "closure", "to", "each", "object", "in", "the", "collection", "<p", ">", "Example", ":", "<pre", ">", "<code", ...
train
https://github.com/apache/groovy/blob/71cf20addb611bb8d097a59e395fd20bc7f31772/subprojects/groovy-json/src/main/java/groovy/json/JsonBuilder.java#L206-L216
apache/flink
flink-libraries/flink-gelly/src/main/java/org/apache/flink/graph/pregel/VertexCentricConfiguration.java
VertexCentricConfiguration.addBroadcastSet
public void addBroadcastSet(String name, DataSet<?> data) { """ Adds a data set as a broadcast set to the compute function. @param name The name under which the broadcast data set is available in the compute function. @param data The data set to be broadcast. """ this.bcVars.add(new Tuple2<>(name, data))...
java
public void addBroadcastSet(String name, DataSet<?> data) { this.bcVars.add(new Tuple2<>(name, data)); }
[ "public", "void", "addBroadcastSet", "(", "String", "name", ",", "DataSet", "<", "?", ">", "data", ")", "{", "this", ".", "bcVars", ".", "add", "(", "new", "Tuple2", "<>", "(", "name", ",", "data", ")", ")", ";", "}" ]
Adds a data set as a broadcast set to the compute function. @param name The name under which the broadcast data set is available in the compute function. @param data The data set to be broadcast.
[ "Adds", "a", "data", "set", "as", "a", "broadcast", "set", "to", "the", "compute", "function", "." ]
train
https://github.com/apache/flink/blob/b62db93bf63cb3bb34dd03d611a779d9e3fc61ac/flink-libraries/flink-gelly/src/main/java/org/apache/flink/graph/pregel/VertexCentricConfiguration.java#L50-L52
Carbonado/Carbonado
src/main/java/com/amazon/carbonado/spi/LobEngine.java
LobEngine.setBlobValue
public void setBlobValue(long locator, Blob data) throws PersistException, IOException { """ Stores a value into a Blob, replacing anything that was there before. Passing null deletes the Blob, which is a convenience for auto-generated code that may call this method. @param locator lob locator as created by c...
java
public void setBlobValue(long locator, Blob data) throws PersistException, IOException { if (data == null) { deleteLob(locator); return; } if (locator == 0) { throw new IllegalArgumentException("Cannot use locator zero"); } if (data...
[ "public", "void", "setBlobValue", "(", "long", "locator", ",", "Blob", "data", ")", "throws", "PersistException", ",", "IOException", "{", "if", "(", "data", "==", "null", ")", "{", "deleteLob", "(", "locator", ")", ";", "return", ";", "}", "if", "(", ...
Stores a value into a Blob, replacing anything that was there before. Passing null deletes the Blob, which is a convenience for auto-generated code that may call this method. @param locator lob locator as created by createNewBlob @param data source of data for Blob, which may be null to delete @throws IllegalArgumentE...
[ "Stores", "a", "value", "into", "a", "Blob", "replacing", "anything", "that", "was", "there", "before", ".", "Passing", "null", "deletes", "the", "Blob", "which", "is", "a", "convenience", "for", "auto", "-", "generated", "code", "that", "may", "call", "th...
train
https://github.com/Carbonado/Carbonado/blob/eee29b365a61c8f03e1a1dc6bed0692e6b04b1db/src/main/java/com/amazon/carbonado/spi/LobEngine.java#L230-L253
rythmengine/rythmengine
src/main/java/org/rythmengine/internal/compiler/TemplateClass.java
TemplateClass.toCanonicalName
private static String toCanonicalName(String key, String root) { """ Convert the key to canonical template name @param key the resource key @param root the resource loader root path @return the canonical name """ if (key.startsWith("/") || key.startsWith("\\")) { key = key.substring(1...
java
private static String toCanonicalName(String key, String root) { if (key.startsWith("/") || key.startsWith("\\")) { key = key.substring(1); } if (key.startsWith(root)) { key = key.replace(root, ""); } if (key.startsWith("/") || key.startsWith("\\")) { ...
[ "private", "static", "String", "toCanonicalName", "(", "String", "key", ",", "String", "root", ")", "{", "if", "(", "key", ".", "startsWith", "(", "\"/\"", ")", "||", "key", ".", "startsWith", "(", "\"\\\\\"", ")", ")", "{", "key", "=", "key", ".", "...
Convert the key to canonical template name @param key the resource key @param root the resource loader root path @return the canonical name
[ "Convert", "the", "key", "to", "canonical", "template", "name" ]
train
https://github.com/rythmengine/rythmengine/blob/064b565f08d9da07378bf77a9dd856ea5831cc92/src/main/java/org/rythmengine/internal/compiler/TemplateClass.java#L845-L858
Azure/azure-sdk-for-java
automation/resource-manager/v2015_10_31/src/main/java/com/microsoft/azure/management/automation/v2015_10_31/implementation/WebhooksInner.java
WebhooksInner.createOrUpdateAsync
public Observable<WebhookInner> createOrUpdateAsync(String resourceGroupName, String automationAccountName, String webhookName, WebhookCreateOrUpdateParameters parameters) { """ Create the webhook identified by webhook name. @param resourceGroupName Name of an Azure Resource group. @param automationAccountName...
java
public Observable<WebhookInner> createOrUpdateAsync(String resourceGroupName, String automationAccountName, String webhookName, WebhookCreateOrUpdateParameters parameters) { return createOrUpdateWithServiceResponseAsync(resourceGroupName, automationAccountName, webhookName, parameters).map(new Func1<ServiceResp...
[ "public", "Observable", "<", "WebhookInner", ">", "createOrUpdateAsync", "(", "String", "resourceGroupName", ",", "String", "automationAccountName", ",", "String", "webhookName", ",", "WebhookCreateOrUpdateParameters", "parameters", ")", "{", "return", "createOrUpdateWithSe...
Create the webhook identified by webhook name. @param resourceGroupName Name of an Azure Resource group. @param automationAccountName The name of the automation account. @param webhookName The webhook name. @param parameters The create or update parameters for webhook. @throws IllegalArgumentException thrown if parame...
[ "Create", "the", "webhook", "identified", "by", "webhook", "name", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/automation/resource-manager/v2015_10_31/src/main/java/com/microsoft/azure/management/automation/v2015_10_31/implementation/WebhooksInner.java#L404-L411
looly/hutool
hutool-db/src/main/java/cn/hutool/db/DaoTemplate.java
DaoTemplate.get
public <T> Entity get(String field, T value) throws SQLException { """ 根据某个字段(最好是唯一字段)查询单个记录<br> 当有多条返回时,只显示查询到的第一条 @param <T> 字段值类型 @param field 字段名 @param value 字段值 @return 记录 @throws SQLException SQL执行异常 """ return this.get(Entity.create(tableName).set(field, value)); }
java
public <T> Entity get(String field, T value) throws SQLException { return this.get(Entity.create(tableName).set(field, value)); }
[ "public", "<", "T", ">", "Entity", "get", "(", "String", "field", ",", "T", "value", ")", "throws", "SQLException", "{", "return", "this", ".", "get", "(", "Entity", ".", "create", "(", "tableName", ")", ".", "set", "(", "field", ",", "value", ")", ...
根据某个字段(最好是唯一字段)查询单个记录<br> 当有多条返回时,只显示查询到的第一条 @param <T> 字段值类型 @param field 字段名 @param value 字段值 @return 记录 @throws SQLException SQL执行异常
[ "根据某个字段(最好是唯一字段)查询单个记录<br", ">", "当有多条返回时,只显示查询到的第一条" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-db/src/main/java/cn/hutool/db/DaoTemplate.java#L232-L234
ReactiveX/RxJavaGuava
src/main/java/rx/transformer/GuavaTransformers.java
GuavaTransformers.toImmutableSet
public static <T> Observable.Transformer<T,ImmutableSet<T>> toImmutableSet() { """ Returns a Transformer&lt;T,ImmutableSet&lt;T&gt;&gt that maps an Observable&lt;T&gt; to an Observable&lt;ImmutableSet&lt;T&gt;&gt; """ return new Observable.Transformer<T, ImmutableSet<T>>() { @Override ...
java
public static <T> Observable.Transformer<T,ImmutableSet<T>> toImmutableSet() { return new Observable.Transformer<T, ImmutableSet<T>>() { @Override public Observable<ImmutableSet<T>> call(Observable<T> source) { return source.collect(new Func0<ImmutableSet.Builder<T>>() { ...
[ "public", "static", "<", "T", ">", "Observable", ".", "Transformer", "<", "T", ",", "ImmutableSet", "<", "T", ">", ">", "toImmutableSet", "(", ")", "{", "return", "new", "Observable", ".", "Transformer", "<", "T", ",", "ImmutableSet", "<", "T", ">", ">...
Returns a Transformer&lt;T,ImmutableSet&lt;T&gt;&gt that maps an Observable&lt;T&gt; to an Observable&lt;ImmutableSet&lt;T&gt;&gt;
[ "Returns", "a", "Transformer&lt", ";", "T", "ImmutableSet&lt", ";", "T&gt", ";", "&gt", "that", "maps", "an", "Observable&lt", ";", "T&gt", ";", "to", "an", "Observable&lt", ";", "ImmutableSet&lt", ";", "T&gt", ";", "&gt", ";" ]
train
https://github.com/ReactiveX/RxJavaGuava/blob/bfb5da6e073364a96da23d57f47c6b706fb733aa/src/main/java/rx/transformer/GuavaTransformers.java#L65-L88
webmetrics/browsermob-proxy
src/main/java/org/browsermob/proxy/jetty/http/HttpMessage.java
HttpMessage.setField
public String setField(String name, String value) { """ Set a field value. If the message is editable, then a header field is set. Otherwise if the message is sending and a HTTP/1.1 version, then a trailer field is set. @param name Name of field @param value New value of field @return Old value of field ...
java
public String setField(String name, String value) { if (_state!=__MSG_EDITABLE) return null; if (HttpFields.__ContentType.equalsIgnoreCase(name)) { String old=_header.get(name); setContentType(value); return old; } ret...
[ "public", "String", "setField", "(", "String", "name", ",", "String", "value", ")", "{", "if", "(", "_state", "!=", "__MSG_EDITABLE", ")", "return", "null", ";", "if", "(", "HttpFields", ".", "__ContentType", ".", "equalsIgnoreCase", "(", "name", ")", ")",...
Set a field value. If the message is editable, then a header field is set. Otherwise if the message is sending and a HTTP/1.1 version, then a trailer field is set. @param name Name of field @param value New value of field @return Old value of field
[ "Set", "a", "field", "value", ".", "If", "the", "message", "is", "editable", "then", "a", "header", "field", "is", "set", ".", "Otherwise", "if", "the", "message", "is", "sending", "and", "a", "HTTP", "/", "1", ".", "1", "version", "then", "a", "trai...
train
https://github.com/webmetrics/browsermob-proxy/blob/a9252e62246ac33d55d51b993ba1159404e7d389/src/main/java/org/browsermob/proxy/jetty/http/HttpMessage.java#L267-L280
cdapio/tigon
tigon-api/src/main/java/co/cask/tigon/api/common/Bytes.java
Bytes.putLong
public static int putLong(byte[] bytes, int offset, long val) { """ Put a long value out to the specified byte array position. @param bytes the byte array @param offset position in the array @param val long to write out @return incremented offset @throws IllegalArgumentException if the byte array given doesn'...
java
public static int putLong(byte[] bytes, int offset, long val) { if (bytes.length - offset < SIZEOF_LONG) { throw new IllegalArgumentException("Not enough room to put a long at" + " offset " + offset + " in a " + bytes.length + " byte array"); } for (int i = offset + 7; i > offset; i--) { ...
[ "public", "static", "int", "putLong", "(", "byte", "[", "]", "bytes", ",", "int", "offset", ",", "long", "val", ")", "{", "if", "(", "bytes", ".", "length", "-", "offset", "<", "SIZEOF_LONG", ")", "{", "throw", "new", "IllegalArgumentException", "(", "...
Put a long value out to the specified byte array position. @param bytes the byte array @param offset position in the array @param val long to write out @return incremented offset @throws IllegalArgumentException if the byte array given doesn't have enough room at the offset specified.
[ "Put", "a", "long", "value", "out", "to", "the", "specified", "byte", "array", "position", "." ]
train
https://github.com/cdapio/tigon/blob/5be6dffd7c79519d1211bb08f75be7dcfbbad392/tigon-api/src/main/java/co/cask/tigon/api/common/Bytes.java#L430-L441
attribyte/wpdb
src/main/java/org/attribyte/wp/db/DB.java
DB.forSite
public DB forSite(final long siteId) { """ Creates a database for another site with shared user caches, metrics and taxonomy terms. @param siteId The site id. @return The site-specific database. """ return siteId == this.siteId ? this : new DB(this.connectionSupplier, siteId, this.taxonomyTermCaches.ke...
java
public DB forSite(final long siteId) { return siteId == this.siteId ? this : new DB(this.connectionSupplier, siteId, this.taxonomyTermCaches.keySet(), this.taxonomyCacheTimeout, this.userCache, this.usernameCache, this.metrics); }
[ "public", "DB", "forSite", "(", "final", "long", "siteId", ")", "{", "return", "siteId", "==", "this", ".", "siteId", "?", "this", ":", "new", "DB", "(", "this", ".", "connectionSupplier", ",", "siteId", ",", "this", ".", "taxonomyTermCaches", ".", "keyS...
Creates a database for another site with shared user caches, metrics and taxonomy terms. @param siteId The site id. @return The site-specific database.
[ "Creates", "a", "database", "for", "another", "site", "with", "shared", "user", "caches", "metrics", "and", "taxonomy", "terms", "." ]
train
https://github.com/attribyte/wpdb/blob/b9adf6131dfb67899ebff770c9bfeb001cc42f30/src/main/java/org/attribyte/wp/db/DB.java#L85-L88
apache/incubator-gobblin
gobblin-data-management/src/main/java/org/apache/gobblin/data/management/copy/hive/HiveCopyEntityHelper.java
HiveCopyEntityHelper.getCopyableFilesFromPaths
List<CopyableFile.Builder> getCopyableFilesFromPaths(Collection<FileStatus> paths, CopyConfiguration configuration, Optional<Partition> partition) throws IOException { """ Get builders for a {@link CopyableFile} for each file referred to by a {@link org.apache.hadoop.hive.metastore.api.StorageDescriptor}. ...
java
List<CopyableFile.Builder> getCopyableFilesFromPaths(Collection<FileStatus> paths, CopyConfiguration configuration, Optional<Partition> partition) throws IOException { List<CopyableFile.Builder> builders = Lists.newArrayList(); List<SourceAndDestination> dataFiles = Lists.newArrayList(); Configuratio...
[ "List", "<", "CopyableFile", ".", "Builder", ">", "getCopyableFilesFromPaths", "(", "Collection", "<", "FileStatus", ">", "paths", ",", "CopyConfiguration", "configuration", ",", "Optional", "<", "Partition", ">", "partition", ")", "throws", "IOException", "{", "L...
Get builders for a {@link CopyableFile} for each file referred to by a {@link org.apache.hadoop.hive.metastore.api.StorageDescriptor}.
[ "Get", "builders", "for", "a", "{" ]
train
https://github.com/apache/incubator-gobblin/blob/f029b4c0fea0fe4aa62f36dda2512344ff708bae/gobblin-data-management/src/main/java/org/apache/gobblin/data/management/copy/hive/HiveCopyEntityHelper.java#L729-L770
lightblue-platform/lightblue-client
core/src/main/java/com/redhat/lightblue/client/request/DataBulkRequest.java
DataBulkRequest.insertBefore
public DataBulkRequest insertBefore(CRUDRequest request, CRUDRequest before) { """ Inserts a request before another specified request. This guarantees that the first request parameter will be executed, sequentially, before the second request parameter. It does not guarantee consecutive execution. @param reque...
java
public DataBulkRequest insertBefore(CRUDRequest request, CRUDRequest before) { this.requests.add(requests.indexOf(before), request); return this; }
[ "public", "DataBulkRequest", "insertBefore", "(", "CRUDRequest", "request", ",", "CRUDRequest", "before", ")", "{", "this", ".", "requests", ".", "add", "(", "requests", ".", "indexOf", "(", "before", ")", ",", "request", ")", ";", "return", "this", ";", "...
Inserts a request before another specified request. This guarantees that the first request parameter will be executed, sequentially, before the second request parameter. It does not guarantee consecutive execution. @param request @param before @return
[ "Inserts", "a", "request", "before", "another", "specified", "request", ".", "This", "guarantees", "that", "the", "first", "request", "parameter", "will", "be", "executed", "sequentially", "before", "the", "second", "request", "parameter", ".", "It", "does", "no...
train
https://github.com/lightblue-platform/lightblue-client/blob/03790aff34e90d3889f60fd6c603c21a21dc1a40/core/src/main/java/com/redhat/lightblue/client/request/DataBulkRequest.java#L85-L88
alkacon/opencms-core
src/org/opencms/xml/content/CmsXmlContent.java
CmsXmlContent.getValueSequence
public CmsXmlContentValueSequence getValueSequence(String xpath, Locale locale) { """ Returns the value sequence for the selected element xpath in this XML content.<p> If the given element xpath is not valid according to the schema of this XML content, <code>null</code> is returned.<p> @param xpath the elem...
java
public CmsXmlContentValueSequence getValueSequence(String xpath, Locale locale) { I_CmsXmlSchemaType type = m_contentDefinition.getSchemaType(xpath); if (type == null) { return null; } return new CmsXmlContentValueSequence(xpath, locale, this); }
[ "public", "CmsXmlContentValueSequence", "getValueSequence", "(", "String", "xpath", ",", "Locale", "locale", ")", "{", "I_CmsXmlSchemaType", "type", "=", "m_contentDefinition", ".", "getSchemaType", "(", "xpath", ")", ";", "if", "(", "type", "==", "null", ")", "...
Returns the value sequence for the selected element xpath in this XML content.<p> If the given element xpath is not valid according to the schema of this XML content, <code>null</code> is returned.<p> @param xpath the element xpath to get the value sequence for @param locale the locale to get the value sequence for ...
[ "Returns", "the", "value", "sequence", "for", "the", "selected", "element", "xpath", "in", "this", "XML", "content", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/xml/content/CmsXmlContent.java#L640-L647
khuxtable/seaglass
src/main/java/com/seaglasslookandfeel/painter/ScrollBarButtonPainter.java
ScrollBarButtonPainter.paintBackgroundTogetherDecrease
private void paintBackgroundTogetherDecrease(Graphics2D g, int width, int height) { """ DOCUMENT ME! @param g DOCUMENT ME! @param width DOCUMENT ME! @param height DOCUMENT ME! """ Shape s = shapeGenerator.createScrollButtonTogetherDecrease(0, 0, width, height); dropShadow.fill(g, s)...
java
private void paintBackgroundTogetherDecrease(Graphics2D g, int width, int height) { Shape s = shapeGenerator.createScrollButtonTogetherDecrease(0, 0, width, height); dropShadow.fill(g, s); fillScrollBarButtonInteriorColors(g, s, isIncrease, buttonsTogether); }
[ "private", "void", "paintBackgroundTogetherDecrease", "(", "Graphics2D", "g", ",", "int", "width", ",", "int", "height", ")", "{", "Shape", "s", "=", "shapeGenerator", ".", "createScrollButtonTogetherDecrease", "(", "0", ",", "0", ",", "width", ",", "height", ...
DOCUMENT ME! @param g DOCUMENT ME! @param width DOCUMENT ME! @param height DOCUMENT ME!
[ "DOCUMENT", "ME!" ]
train
https://github.com/khuxtable/seaglass/blob/f25ecba622923d7b29b64cb7d6068dd8005989b3/src/main/java/com/seaglasslookandfeel/painter/ScrollBarButtonPainter.java#L269-L274
kaazing/java.client
amqp-0-9-1/amqp/src/main/java/org/kaazing/net/ws/amqp/impl/AmqpBuffer.java
AmqpBuffer.encodeAuthAmqPlain
public String encodeAuthAmqPlain(String username, String password) { """ Encodes the AMQPLAIN authentication response as an AmqpArguments """ AmqpBuffer bytes = new AmqpBuffer(); bytes.putShortString("LOGIN"); bytes.putTypeIdentifier("Longstr"); bytes.putLongString(usern...
java
public String encodeAuthAmqPlain(String username, String password) { AmqpBuffer bytes = new AmqpBuffer(); bytes.putShortString("LOGIN"); bytes.putTypeIdentifier("Longstr"); bytes.putLongString(username); bytes.putShortString("PASSWORD"); bytes.putTypeIdentifi...
[ "public", "String", "encodeAuthAmqPlain", "(", "String", "username", ",", "String", "password", ")", "{", "AmqpBuffer", "bytes", "=", "new", "AmqpBuffer", "(", ")", ";", "bytes", ".", "putShortString", "(", "\"LOGIN\"", ")", ";", "bytes", ".", "putTypeIdentifi...
Encodes the AMQPLAIN authentication response as an AmqpArguments
[ "Encodes", "the", "AMQPLAIN", "authentication", "response", "as", "an", "AmqpArguments" ]
train
https://github.com/kaazing/java.client/blob/25ad2ae5bb24aa9d6b79400fce649b518dcfbe26/amqp-0-9-1/amqp/src/main/java/org/kaazing/net/ws/amqp/impl/AmqpBuffer.java#L92-L113
tvesalainen/util
util/src/main/java/org/vesalainen/util/concurrent/CachedScheduledThreadPool.java
CachedScheduledThreadPool.iterateAtFixedRate
public ScheduledFuture<?> iterateAtFixedRate(long initialDelay, long period, TimeUnit unit, Collection<Runnable> commands) { """ After initialDelay executes commands using collections iterator until either iterator has no more commands or command throws exception. @param initialDelay @param period @param unit ...
java
public ScheduledFuture<?> iterateAtFixedRate(long initialDelay, long period, TimeUnit unit, Collection<Runnable> commands) { return iterateAtFixedRate(initialDelay, period, unit, commands.iterator()); }
[ "public", "ScheduledFuture", "<", "?", ">", "iterateAtFixedRate", "(", "long", "initialDelay", ",", "long", "period", ",", "TimeUnit", "unit", ",", "Collection", "<", "Runnable", ">", "commands", ")", "{", "return", "iterateAtFixedRate", "(", "initialDelay", ","...
After initialDelay executes commands using collections iterator until either iterator has no more commands or command throws exception. @param initialDelay @param period @param unit @param commands @return @see java.util.concurrent.ScheduledThreadPoolExecutor#scheduleAtFixedDelay(java.lang.Runnable, long, long, java.ut...
[ "After", "initialDelay", "executes", "commands", "using", "collections", "iterator", "until", "either", "iterator", "has", "no", "more", "commands", "or", "command", "throws", "exception", "." ]
train
https://github.com/tvesalainen/util/blob/bba7a44689f638ffabc8be40a75bdc9a33676433/util/src/main/java/org/vesalainen/util/concurrent/CachedScheduledThreadPool.java#L206-L209
kaazing/java.client
net.api/src/main/java/org/kaazing/net/URLFactory.java
URLFactory.createURL
public static URL createURL(URL context, String spec) throws MalformedURLException { """ Creates a URL by parsing the given spec within a specified context. The new URL is created from the given context URL and the spec argument as described in RFC2396 "Uniform Resource Identifiers : Generic Syntax" ...
java
public static URL createURL(URL context, String spec) throws MalformedURLException { if ((spec == null) || (spec.trim().length() == 0)) { return new URL(context, spec); } String protocol = URI.create(spec).getScheme(); URLStreamHandlerFactory factory = _factories...
[ "public", "static", "URL", "createURL", "(", "URL", "context", ",", "String", "spec", ")", "throws", "MalformedURLException", "{", "if", "(", "(", "spec", "==", "null", ")", "||", "(", "spec", ".", "trim", "(", ")", ".", "length", "(", ")", "==", "0"...
Creates a URL by parsing the given spec within a specified context. The new URL is created from the given context URL and the spec argument as described in RFC2396 "Uniform Resource Identifiers : Generic Syntax" : <p/> {@code <scheme>://<authority><path>?<query>#<fragment> } <p/> The reference is parsed into the scheme...
[ "Creates", "a", "URL", "by", "parsing", "the", "given", "spec", "within", "a", "specified", "context", ".", "The", "new", "URL", "is", "created", "from", "the", "given", "context", "URL", "and", "the", "spec", "argument", "as", "described", "in", "RFC2396"...
train
https://github.com/kaazing/java.client/blob/25ad2ae5bb24aa9d6b79400fce649b518dcfbe26/net.api/src/main/java/org/kaazing/net/URLFactory.java#L127-L147
elki-project/elki
elki-itemsets/src/main/java/de/lmu/ifi/dbs/elki/algorithm/itemsetmining/APRIORI.java
APRIORI.buildFrequentOneItemsets
protected List<OneItemset> buildFrequentOneItemsets(final Relation<? extends SparseFeatureVector<?>> relation, final int dim, final int needed) { """ Build the 1-itemsets. @param relation Data relation @param dim Maximum dimensionality @param needed Minimum support needed @return 1-itemsets """ // TO...
java
protected List<OneItemset> buildFrequentOneItemsets(final Relation<? extends SparseFeatureVector<?>> relation, final int dim, final int needed) { // TODO: use TIntList and prefill appropriately to avoid knowing "dim" // beforehand? int[] counts = new int[dim]; for(DBIDIter iditer = relation.iterDBIDs();...
[ "protected", "List", "<", "OneItemset", ">", "buildFrequentOneItemsets", "(", "final", "Relation", "<", "?", "extends", "SparseFeatureVector", "<", "?", ">", ">", "relation", ",", "final", "int", "dim", ",", "final", "int", "needed", ")", "{", "// TODO: use TI...
Build the 1-itemsets. @param relation Data relation @param dim Maximum dimensionality @param needed Minimum support needed @return 1-itemsets
[ "Build", "the", "1", "-", "itemsets", "." ]
train
https://github.com/elki-project/elki/blob/b54673327e76198ecd4c8a2a901021f1a9174498/elki-itemsets/src/main/java/de/lmu/ifi/dbs/elki/algorithm/itemsetmining/APRIORI.java#L198-L219
gmessner/gitlab4j-api
src/main/java/org/gitlab4j/api/GroupApi.java
GroupApi.addLdapGroupLink
public void addLdapGroupLink(Object groupIdOrPath, String cn, AccessLevel groupAccess, String provider) throws GitLabApiException { """ Adds an LDAP group link. <pre><code>GitLab Endpoint: POST /groups/:id/ldap_group_links</code></pre> @param groupIdOrPath the group ID, path of the group, or a Group instance...
java
public void addLdapGroupLink(Object groupIdOrPath, String cn, AccessLevel groupAccess, String provider) throws GitLabApiException { if (groupAccess == null) { throw new RuntimeException("groupAccess cannot be null or empty"); } addLdapGroupLink(groupIdOrPath, cn, groupAccess.toValu...
[ "public", "void", "addLdapGroupLink", "(", "Object", "groupIdOrPath", ",", "String", "cn", ",", "AccessLevel", "groupAccess", ",", "String", "provider", ")", "throws", "GitLabApiException", "{", "if", "(", "groupAccess", "==", "null", ")", "{", "throw", "new", ...
Adds an LDAP group link. <pre><code>GitLab Endpoint: POST /groups/:id/ldap_group_links</code></pre> @param groupIdOrPath the group ID, path of the group, or a Group instance holding the group ID or path @param cn the CN of a LDAP group @param groupAccess the minimum access level for members of the LDAP group @param p...
[ "Adds", "an", "LDAP", "group", "link", "." ]
train
https://github.com/gmessner/gitlab4j-api/blob/ab045070abac0a8f4ccbf17b5ed9bfdef5723eed/src/main/java/org/gitlab4j/api/GroupApi.java#L924-L931
app55/app55-java
src/main/java/com/app55/util/Base64.java
Base64.encodeFromFile
public static String encodeFromFile(String filename) { """ Convenience method for reading a binary file and base64-encoding it. @param filename Filename for reading binary data @return base64-encoded string or null if unsuccessful @since 2.1 """ String encodedData = null; Base64.InputStream bis = n...
java
public static String encodeFromFile(String filename) { String encodedData = null; Base64.InputStream bis = null; try { // Set up some useful variables java.io.File file = new java.io.File(filename); byte[] buffer = new byte[Math.max((int) (file.length() * 1.4), 40)]; // Need max() for math on small fi...
[ "public", "static", "String", "encodeFromFile", "(", "String", "filename", ")", "{", "String", "encodedData", "=", "null", ";", "Base64", ".", "InputStream", "bis", "=", "null", ";", "try", "{", "// Set up some useful variables", "java", ".", "io", ".", "File"...
Convenience method for reading a binary file and base64-encoding it. @param filename Filename for reading binary data @return base64-encoded string or null if unsuccessful @since 2.1
[ "Convenience", "method", "for", "reading", "a", "binary", "file", "and", "base64", "-", "encoding", "it", "." ]
train
https://github.com/app55/app55-java/blob/73e51d0f3141a859dfbd37ca9becef98477e553e/src/main/java/com/app55/util/Base64.java#L1243-L1281
looly/hutool
hutool-socket/src/main/java/cn/hutool/socket/aio/AioClient.java
AioClient.setOption
public <T> AioClient setOption(SocketOption<T> name, T value) throws IOException { """ 设置 Socket 的 Option 选项<br> 选项见:{@link java.net.StandardSocketOptions} @param <T> 选项泛型 @param name {@link SocketOption} 枚举 @param value SocketOption参数 @throws IOException IO异常 """ this.session.getChannel().setOption(...
java
public <T> AioClient setOption(SocketOption<T> name, T value) throws IOException { this.session.getChannel().setOption(name, value); return this; }
[ "public", "<", "T", ">", "AioClient", "setOption", "(", "SocketOption", "<", "T", ">", "name", ",", "T", "value", ")", "throws", "IOException", "{", "this", ".", "session", ".", "getChannel", "(", ")", ".", "setOption", "(", "name", ",", "value", ")", ...
设置 Socket 的 Option 选项<br> 选项见:{@link java.net.StandardSocketOptions} @param <T> 选项泛型 @param name {@link SocketOption} 枚举 @param value SocketOption参数 @throws IOException IO异常
[ "设置", "Socket", "的", "Option", "选项<br", ">", "选项见:", "{", "@link", "java", ".", "net", ".", "StandardSocketOptions", "}" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-socket/src/main/java/cn/hutool/socket/aio/AioClient.java#L68-L71
OpenLiberty/open-liberty
dev/com.ibm.ws.microprofile.openapi/src/com/ibm/ws/microprofile/openapi/impl/core/util/ReflectionUtils.java
ReflectionUtils.findMethod
public static Method findMethod(Method methodToFind, Class<?> cls) { """ Searches the method methodToFind in given class cls. If the method is found returns it, else return null. @param methodToFind is the method to search @param cls is the class or interface where to search @return method if it is found ...
java
public static Method findMethod(Method methodToFind, Class<?> cls) { if (cls == null) { return null; } String methodToSearch = methodToFind.getName(); Class<?>[] soughtForParameterType = methodToFind.getParameterTypes(); Type[] soughtForGenericParameterType = methodTo...
[ "public", "static", "Method", "findMethod", "(", "Method", "methodToFind", ",", "Class", "<", "?", ">", "cls", ")", "{", "if", "(", "cls", "==", "null", ")", "{", "return", "null", ";", "}", "String", "methodToSearch", "=", "methodToFind", ".", "getName"...
Searches the method methodToFind in given class cls. If the method is found returns it, else return null. @param methodToFind is the method to search @param cls is the class or interface where to search @return method if it is found
[ "Searches", "the", "method", "methodToFind", "in", "given", "class", "cls", ".", "If", "the", "method", "is", "found", "returns", "it", "else", "return", "null", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.microprofile.openapi/src/com/ibm/ws/microprofile/openapi/impl/core/util/ReflectionUtils.java#L128-L148
VoltDB/voltdb
third_party/java/src/org/apache/zookeeper_voltpatches/server/persistence/FileTxnLog.java
FileTxnLog.getDbId
public long getDbId() throws IOException { """ the dbid of this transaction database @return the dbid of this database """ FileTxnIterator itr = new FileTxnIterator(logDir, 0); FileHeader fh=readHeader(itr.logFile); itr.close(); if(fh==null) throw new IOException("U...
java
public long getDbId() throws IOException { FileTxnIterator itr = new FileTxnIterator(logDir, 0); FileHeader fh=readHeader(itr.logFile); itr.close(); if(fh==null) throw new IOException("Unsupported Format."); return fh.getDbid(); }
[ "public", "long", "getDbId", "(", ")", "throws", "IOException", "{", "FileTxnIterator", "itr", "=", "new", "FileTxnIterator", "(", "logDir", ",", "0", ")", ";", "FileHeader", "fh", "=", "readHeader", "(", "itr", ".", "logFile", ")", ";", "itr", ".", "clo...
the dbid of this transaction database @return the dbid of this database
[ "the", "dbid", "of", "this", "transaction", "database" ]
train
https://github.com/VoltDB/voltdb/blob/8afc1031e475835344b5497ea9e7203bc95475ac/third_party/java/src/org/apache/zookeeper_voltpatches/server/persistence/FileTxnLog.java#L380-L387
mnlipp/jgrapes
org.jgrapes.http/src/org/jgrapes/http/HttpServer.java
HttpServer.onOptions
@Handler(priority = Integer.MIN_VALUE) public void onOptions(Request.In.Options event, IOSubchannel appChannel) { """ Provides a fallback handler for an OPTIONS request with asterisk. Simply responds with "OK". @param event the event @param appChannel the application channel """ if (event.requ...
java
@Handler(priority = Integer.MIN_VALUE) public void onOptions(Request.In.Options event, IOSubchannel appChannel) { if (event.requestUri() == HttpRequest.ASTERISK_REQUEST) { HttpResponse response = event.httpRequest().response().get(); response.setStatus(HttpStatus.OK); app...
[ "@", "Handler", "(", "priority", "=", "Integer", ".", "MIN_VALUE", ")", "public", "void", "onOptions", "(", "Request", ".", "In", ".", "Options", "event", ",", "IOSubchannel", "appChannel", ")", "{", "if", "(", "event", ".", "requestUri", "(", ")", "==",...
Provides a fallback handler for an OPTIONS request with asterisk. Simply responds with "OK". @param event the event @param appChannel the application channel
[ "Provides", "a", "fallback", "handler", "for", "an", "OPTIONS", "request", "with", "asterisk", ".", "Simply", "responds", "with", "OK", "." ]
train
https://github.com/mnlipp/jgrapes/blob/8b5d874935d84c34a52d3e3d3745e869b5203fa0/org.jgrapes.http/src/org/jgrapes/http/HttpServer.java#L386-L395
fcrepo4/fcrepo4
fcrepo-kernel-modeshape/src/main/java/org/fcrepo/kernel/modeshape/services/AbstractService.java
AbstractService.tagHierarchyWithPairtreeMixin
private static void tagHierarchyWithPairtreeMixin(final Node baseNode, final Node createdNode) throws RepositoryException { """ Tag a hierarchy with {@link org.fcrepo.kernel.api.FedoraTypes#FEDORA_PAIRTREE} @param baseNode Top most ancestor that should not be tagged @param createdNode Node whose pare...
java
private static void tagHierarchyWithPairtreeMixin(final Node baseNode, final Node createdNode) throws RepositoryException { Node parent = createdNode.getParent(); while (parent.isNew() && !parent.equals(baseNode)) { parent.addMixin(FEDORA_PAIRTREE); parent = parent.g...
[ "private", "static", "void", "tagHierarchyWithPairtreeMixin", "(", "final", "Node", "baseNode", ",", "final", "Node", "createdNode", ")", "throws", "RepositoryException", "{", "Node", "parent", "=", "createdNode", ".", "getParent", "(", ")", ";", "while", "(", "...
Tag a hierarchy with {@link org.fcrepo.kernel.api.FedoraTypes#FEDORA_PAIRTREE} @param baseNode Top most ancestor that should not be tagged @param createdNode Node whose parents should be tagged up to but not including {@code baseNode} @throws RepositoryException if repository exception occurred
[ "Tag", "a", "hierarchy", "with", "{" ]
train
https://github.com/fcrepo4/fcrepo4/blob/7489ad5bc8fb44e2442c93eceb7d97ac54553ab6/fcrepo-kernel-modeshape/src/main/java/org/fcrepo/kernel/modeshape/services/AbstractService.java#L79-L87
infinispan/infinispan
server/integration/commons/src/main/java/org/infinispan/server/commons/controller/Operations.java
Operations.createWriteAttributeOperation
public static ModelNode createWriteAttributeOperation(PathAddress address, String name, ModelNode value) { """ Creates a write-attribute operation using the specified address, namem and value. @param address a resource path @param name an attribute name @param value an attribute value @return a write-attribute...
java
public static ModelNode createWriteAttributeOperation(PathAddress address, String name, ModelNode value) { ModelNode operation = createAttributeOperation(ModelDescriptionConstants.WRITE_ATTRIBUTE_OPERATION, address, name); operation.get(ModelDescriptionConstants.VALUE).set(value); return operati...
[ "public", "static", "ModelNode", "createWriteAttributeOperation", "(", "PathAddress", "address", ",", "String", "name", ",", "ModelNode", "value", ")", "{", "ModelNode", "operation", "=", "createAttributeOperation", "(", "ModelDescriptionConstants", ".", "WRITE_ATTRIBUTE_...
Creates a write-attribute operation using the specified address, namem and value. @param address a resource path @param name an attribute name @param value an attribute value @return a write-attribute operation
[ "Creates", "a", "write", "-", "attribute", "operation", "using", "the", "specified", "address", "namem", "and", "value", "." ]
train
https://github.com/infinispan/infinispan/blob/7c62b94886c3febb4774ae8376acf2baa0265ab5/server/integration/commons/src/main/java/org/infinispan/server/commons/controller/Operations.java#L117-L121
jfinal/jfinal
src/main/java/com/jfinal/plugin/redis/Cache.java
Cache.expire
public Long expire(Object key, int seconds) { """ 为给定 key 设置生存时间,当 key 过期时(生存时间为 0 ),它会被自动删除。 在 Redis 中,带有生存时间的 key 被称为『易失的』(volatile)。 """ Jedis jedis = getJedis(); try { return jedis.expire(keyToBytes(key), seconds); } finally {close(jedis);} }
java
public Long expire(Object key, int seconds) { Jedis jedis = getJedis(); try { return jedis.expire(keyToBytes(key), seconds); } finally {close(jedis);} }
[ "public", "Long", "expire", "(", "Object", "key", ",", "int", "seconds", ")", "{", "Jedis", "jedis", "=", "getJedis", "(", ")", ";", "try", "{", "return", "jedis", ".", "expire", "(", "keyToBytes", "(", "key", ")", ",", "seconds", ")", ";", "}", "f...
为给定 key 设置生存时间,当 key 过期时(生存时间为 0 ),它会被自动删除。 在 Redis 中,带有生存时间的 key 被称为『易失的』(volatile)。
[ "为给定", "key", "设置生存时间,当", "key", "过期时", "(", "生存时间为", "0", ")", ",它会被自动删除。", "在", "Redis", "中,带有生存时间的", "key", "被称为『易失的』", "(", "volatile", ")", "。" ]
train
https://github.com/jfinal/jfinal/blob/fc07f0f5d56e85ccd3cfcdd587b56b8dd9c663e9/src/main/java/com/jfinal/plugin/redis/Cache.java#L318-L324
OpenLiberty/open-liberty
dev/com.ibm.ws.security.javaeesec.cdi/src/com/ibm/ws/security/javaeesec/cdi/extensions/IdentityStoreHandlerServiceImpl.java
IdentityStoreHandlerServiceImpl.createHashtableInSubject
@Override public Subject createHashtableInSubject(String username, @Sensitive String password) throws AuthenticationException { """ Returns the partial subject for hashtable login @param username @param password @return the partial subject which can be used for hashtable login if username and password a...
java
@Override public Subject createHashtableInSubject(String username, @Sensitive String password) throws AuthenticationException { UsernamePasswordCredential credential = new UsernamePasswordCredential(username, password); return createHashtableInSubject(credential); }
[ "@", "Override", "public", "Subject", "createHashtableInSubject", "(", "String", "username", ",", "@", "Sensitive", "String", "password", ")", "throws", "AuthenticationException", "{", "UsernamePasswordCredential", "credential", "=", "new", "UsernamePasswordCredential", "...
Returns the partial subject for hashtable login @param username @param password @return the partial subject which can be used for hashtable login if username and password are valid. @throws com.ibm.ws.security.authentication.AuthenticationException
[ "Returns", "the", "partial", "subject", "for", "hashtable", "login" ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.security.javaeesec.cdi/src/com/ibm/ws/security/javaeesec/cdi/extensions/IdentityStoreHandlerServiceImpl.java#L63-L67
Axway/Grapes
server/src/main/java/org/axway/grapes/server/webapp/resources/PromotionReportTranslator.java
PromotionReportTranslator.buildErrorMsg
private static String buildErrorMsg(List<String> dependencies, String message) { """ Get the error message with the dependencies appended @param dependencies - the list with dependencies to be attached to the message @param message - the custom error message to be displayed to the user @return String ...
java
private static String buildErrorMsg(List<String> dependencies, String message) { final StringBuilder buffer = new StringBuilder(); boolean isFirstElement = true; for (String dependency : dependencies) { if (!isFirstElement) { buffer.append(", "); } ...
[ "private", "static", "String", "buildErrorMsg", "(", "List", "<", "String", ">", "dependencies", ",", "String", "message", ")", "{", "final", "StringBuilder", "buffer", "=", "new", "StringBuilder", "(", ")", ";", "boolean", "isFirstElement", "=", "true", ";", ...
Get the error message with the dependencies appended @param dependencies - the list with dependencies to be attached to the message @param message - the custom error message to be displayed to the user @return String
[ "Get", "the", "error", "message", "with", "the", "dependencies", "appended" ]
train
https://github.com/Axway/Grapes/blob/ce9cc73d85f83eaa5fbc991abb593915a8c8374e/server/src/main/java/org/axway/grapes/server/webapp/resources/PromotionReportTranslator.java#L161-L174
nohana/Amalgam
amalgam/src/main/java/com/amalgam/view/MotionEventUtils.java
MotionEventUtils.getVerticalMotionDirection
public static MotionDirection getVerticalMotionDirection(MotionEvent e1, MotionEvent e2) { """ Calculate the vertical move motion direction. @param e1 start point of the motion. @param e2 end point of the motion. @return the motion direction for the vertical axis. """ return getVerticalMotionDirecti...
java
public static MotionDirection getVerticalMotionDirection(MotionEvent e1, MotionEvent e2) { return getVerticalMotionDirection(e1, e2, DEFAULT_THRESHOLD); }
[ "public", "static", "MotionDirection", "getVerticalMotionDirection", "(", "MotionEvent", "e1", ",", "MotionEvent", "e2", ")", "{", "return", "getVerticalMotionDirection", "(", "e1", ",", "e2", ",", "DEFAULT_THRESHOLD", ")", ";", "}" ]
Calculate the vertical move motion direction. @param e1 start point of the motion. @param e2 end point of the motion. @return the motion direction for the vertical axis.
[ "Calculate", "the", "vertical", "move", "motion", "direction", "." ]
train
https://github.com/nohana/Amalgam/blob/57809ddbfe7897e979cf507982ce0b3aa5e0ed8a/amalgam/src/main/java/com/amalgam/view/MotionEventUtils.java#L85-L87
Azure/azure-sdk-for-java
logic/resource-manager/v2016_06_01/src/main/java/com/microsoft/azure/management/logic/v2016_06_01/implementation/WorkflowRunActionRepetitionsInner.java
WorkflowRunActionRepetitionsInner.listExpressionTracesAsync
public Observable<List<ExpressionRootInner>> listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { """ Lists a workflow run expression trace. @param resourceGroupName The resource group name. @param workflowName The workflow name. ...
java
public Observable<List<ExpressionRootInner>> listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { return listExpressionTracesWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).map(new Func...
[ "public", "Observable", "<", "List", "<", "ExpressionRootInner", ">", ">", "listExpressionTracesAsync", "(", "String", "resourceGroupName", ",", "String", "workflowName", ",", "String", "runName", ",", "String", "actionName", ",", "String", "repetitionName", ")", "{...
Lists a workflow run expression trace. @param resourceGroupName The resource group name. @param workflowName The workflow name. @param runName The workflow run name. @param actionName The workflow action name. @param repetitionName The workflow repetition. @throws IllegalArgumentException thrown if parameters fail the...
[ "Lists", "a", "workflow", "run", "expression", "trace", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/logic/resource-manager/v2016_06_01/src/main/java/com/microsoft/azure/management/logic/v2016_06_01/implementation/WorkflowRunActionRepetitionsInner.java#L326-L333
fhoeben/hsac-fitnesse-fixtures
src/main/java/nl/hsac/fitnesse/fixture/util/selenium/SeleniumHelper.java
SeleniumHelper.findElement
public T findElement(SearchContext context, By by) { """ Finds element matching the By supplied. @param context context to find element in. @param by criteria. @return element if found, null if none could be found. """ return FirstElementBy.getWebElement(by, context); }
java
public T findElement(SearchContext context, By by) { return FirstElementBy.getWebElement(by, context); }
[ "public", "T", "findElement", "(", "SearchContext", "context", ",", "By", "by", ")", "{", "return", "FirstElementBy", ".", "getWebElement", "(", "by", ",", "context", ")", ";", "}" ]
Finds element matching the By supplied. @param context context to find element in. @param by criteria. @return element if found, null if none could be found.
[ "Finds", "element", "matching", "the", "By", "supplied", "." ]
train
https://github.com/fhoeben/hsac-fitnesse-fixtures/blob/4e9018d7386a9aa65bfcbf07eb28ae064edd1732/src/main/java/nl/hsac/fitnesse/fixture/util/selenium/SeleniumHelper.java#L957-L959
fabric8io/docker-maven-plugin
src/main/java/io/fabric8/maven/docker/service/QueryService.java
QueryService.getMandatoryContainer
public Container getMandatoryContainer(String containerIdOrName) throws DockerAccessException { """ Get container by id @param containerIdOrName container id or name @return container found @throws DockerAccessException if an error occurs or no container with this id or name exists """ Container c...
java
public Container getMandatoryContainer(String containerIdOrName) throws DockerAccessException { Container container = getContainer(containerIdOrName); if (container == null) { throw new DockerAccessException("Cannot find container %s", containerIdOrName); } return container; ...
[ "public", "Container", "getMandatoryContainer", "(", "String", "containerIdOrName", ")", "throws", "DockerAccessException", "{", "Container", "container", "=", "getContainer", "(", "containerIdOrName", ")", ";", "if", "(", "container", "==", "null", ")", "{", "throw...
Get container by id @param containerIdOrName container id or name @return container found @throws DockerAccessException if an error occurs or no container with this id or name exists
[ "Get", "container", "by", "id" ]
train
https://github.com/fabric8io/docker-maven-plugin/blob/70ce4f56125d8efb8ddcf2ad4dbb5d6e2c7642b3/src/main/java/io/fabric8/maven/docker/service/QueryService.java#L36-L42
alkacon/opencms-core
src/org/opencms/db/CmsDriverManager.java
CmsDriverManager.newDriverInstance
public Object newDriverInstance( CmsDbContext dbc, CmsConfigurationManager configurationManager, String driverName, List<String> successiveDrivers) throws CmsInitException { """ Gets a new driver instance.<p> @param dbc the database context @param configurationManager the co...
java
public Object newDriverInstance( CmsDbContext dbc, CmsConfigurationManager configurationManager, String driverName, List<String> successiveDrivers) throws CmsInitException { Class<?> driverClass = null; I_CmsDriver driver = null; try { // try to ...
[ "public", "Object", "newDriverInstance", "(", "CmsDbContext", "dbc", ",", "CmsConfigurationManager", "configurationManager", ",", "String", "driverName", ",", "List", "<", "String", ">", "successiveDrivers", ")", "throws", "CmsInitException", "{", "Class", "<", "?", ...
Gets a new driver instance.<p> @param dbc the database context @param configurationManager the configuration manager @param driverName the driver name @param successiveDrivers the list of successive drivers @return the driver object @throws CmsInitException if the selected driver could not be initialized
[ "Gets", "a", "new", "driver", "instance", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/db/CmsDriverManager.java#L5919-L5959
maven-nar/nar-maven-plugin
src/main/java/com/github/maven_nar/cpptasks/msvc/MsvcProjectWriter.java
MsvcProjectWriter.writeSource
private void writeSource(final Writer writer, final String basePath, final File groupMember) throws IOException { """ Writes the entry for one source file in the project. @param writer Writer writer @param basePath String base path for project @param groupMember File project source file @throws IOExceptio...
java
private void writeSource(final Writer writer, final String basePath, final File groupMember) throws IOException { writer.write("# Begin Source File\r\n\r\nSOURCE="); String relativePath = CUtil.getRelativePath(basePath, groupMember); // // if relative path is just a name (hello.c) then // make it .\...
[ "private", "void", "writeSource", "(", "final", "Writer", "writer", ",", "final", "String", "basePath", ",", "final", "File", "groupMember", ")", "throws", "IOException", "{", "writer", ".", "write", "(", "\"# Begin Source File\\r\\n\\r\\nSOURCE=\"", ")", ";", "St...
Writes the entry for one source file in the project. @param writer Writer writer @param basePath String base path for project @param groupMember File project source file @throws IOException if error writing project file
[ "Writes", "the", "entry", "for", "one", "source", "file", "in", "the", "project", "." ]
train
https://github.com/maven-nar/nar-maven-plugin/blob/3c622e2024296b4203431bbae3bde290a01dac00/src/main/java/com/github/maven_nar/cpptasks/msvc/MsvcProjectWriter.java#L652-L663