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
apache/flink
flink-runtime/src/main/java/org/apache/flink/runtime/zookeeper/ZooKeeperStateHandleStore.java
ZooKeeperStateHandleStore.releaseAll
public void releaseAll() throws Exception { """ Releases all lock nodes of this ZooKeeperStateHandleStore. @throws Exception if the delete operation of a lock file fails """ Collection<String> children = getAllPaths(); Exception exception = null; for (String child: children) { try { release(c...
java
public void releaseAll() throws Exception { Collection<String> children = getAllPaths(); Exception exception = null; for (String child: children) { try { release(child); } catch (Exception e) { exception = ExceptionUtils.firstOrSuppressed(e, exception); } } if (exception != null) { thro...
[ "public", "void", "releaseAll", "(", ")", "throws", "Exception", "{", "Collection", "<", "String", ">", "children", "=", "getAllPaths", "(", ")", ";", "Exception", "exception", "=", "null", ";", "for", "(", "String", "child", ":", "children", ")", "{", "...
Releases all lock nodes of this ZooKeeperStateHandleStore. @throws Exception if the delete operation of a lock file fails
[ "Releases", "all", "lock", "nodes", "of", "this", "ZooKeeperStateHandleStore", "." ]
train
https://github.com/apache/flink/blob/b62db93bf63cb3bb34dd03d611a779d9e3fc61ac/flink-runtime/src/main/java/org/apache/flink/runtime/zookeeper/ZooKeeperStateHandleStore.java#L410-L426
stripe/stripe-android
stripe/src/main/java/com/stripe/android/CardUtils.java
CardUtils.getPossibleCardType
@NonNull @Card.CardBrand public static String getPossibleCardType(@Nullable String cardNumber) { """ Returns a {@link Card.CardBrand} corresponding to a partial card number, or {@link Card#UNKNOWN} if the card brand can't be determined from the input value. @param cardNumber a credit card number or par...
java
@NonNull @Card.CardBrand public static String getPossibleCardType(@Nullable String cardNumber) { return getPossibleCardType(cardNumber, true); }
[ "@", "NonNull", "@", "Card", ".", "CardBrand", "public", "static", "String", "getPossibleCardType", "(", "@", "Nullable", "String", "cardNumber", ")", "{", "return", "getPossibleCardType", "(", "cardNumber", ",", "true", ")", ";", "}" ]
Returns a {@link Card.CardBrand} corresponding to a partial card number, or {@link Card#UNKNOWN} if the card brand can't be determined from the input value. @param cardNumber a credit card number or partial card number @return the {@link Card.CardBrand} corresponding to that number, or {@link Card#UNKNOWN} if it can't...
[ "Returns", "a", "{", "@link", "Card", ".", "CardBrand", "}", "corresponding", "to", "a", "partial", "card", "number", "or", "{", "@link", "Card#UNKNOWN", "}", "if", "the", "card", "brand", "can", "t", "be", "determined", "from", "the", "input", "value", ...
train
https://github.com/stripe/stripe-android/blob/0f199255f3769a3b84583fe3ace47bfae8c3b1c8/stripe/src/main/java/com/stripe/android/CardUtils.java#L27-L31
google/j2objc
jre_emul/android/platform/external/okhttp/okio/okio/src/main/java/okio/Buffer.java
Buffer.copyTo
public Buffer copyTo(Buffer out, long offset, long byteCount) { """ Copy {@code byteCount} bytes from this, starting at {@code offset}, to {@code out}. """ if (out == null) throw new IllegalArgumentException("out == null"); checkOffsetAndCount(size, offset, byteCount); if (byteCount == 0) return th...
java
public Buffer copyTo(Buffer out, long offset, long byteCount) { if (out == null) throw new IllegalArgumentException("out == null"); checkOffsetAndCount(size, offset, byteCount); if (byteCount == 0) return this; out.size += byteCount; // Skip segments that we aren't copying from. Segment s = he...
[ "public", "Buffer", "copyTo", "(", "Buffer", "out", ",", "long", "offset", ",", "long", "byteCount", ")", "{", "if", "(", "out", "==", "null", ")", "throw", "new", "IllegalArgumentException", "(", "\"out == null\"", ")", ";", "checkOffsetAndCount", "(", "siz...
Copy {@code byteCount} bytes from this, starting at {@code offset}, to {@code out}.
[ "Copy", "{" ]
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/okhttp/okio/okio/src/main/java/okio/Buffer.java#L164-L192
jbundle/jbundle
base/screen/model/src/main/java/org/jbundle/base/screen/model/report/ReportBreakScreen.java
ReportBreakScreen.isPrintableControl
public boolean isPrintableControl(ScreenField sField, int iPrintOptions) { """ Display this sub-control in html input format? @param iPrintOptions The view specific print options. @return True if this sub-control is printable. """ // Override this to break if ((sField == null) || (sField == t...
java
public boolean isPrintableControl(ScreenField sField, int iPrintOptions) { // Override this to break if ((sField == null) || (sField == this)) { // Asking about this control int iDisplayOptions = m_iDisplayFieldDesc & (HtmlConstants.HEADING_SCREEN | HtmlConstants.FOOTING_SC...
[ "public", "boolean", "isPrintableControl", "(", "ScreenField", "sField", ",", "int", "iPrintOptions", ")", "{", "// Override this to break", "if", "(", "(", "sField", "==", "null", ")", "||", "(", "sField", "==", "this", ")", ")", "{", "// Asking about this cont...
Display this sub-control in html input format? @param iPrintOptions The view specific print options. @return True if this sub-control is printable.
[ "Display", "this", "sub", "-", "control", "in", "html", "input", "format?" ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/screen/model/src/main/java/org/jbundle/base/screen/model/report/ReportBreakScreen.java#L75-L86
google/closure-compiler
src/com/google/javascript/jscomp/ExploitAssigns.java
ExploitAssigns.isSafeReplacement
private boolean isSafeReplacement(Node node, Node replacement) { """ Checks name referenced in node to determine if it might have changed. @return Whether the replacement can be made. """ // No checks are needed for simple names. if (node.isName()) { return true; } checkArgument(node.is...
java
private boolean isSafeReplacement(Node node, Node replacement) { // No checks are needed for simple names. if (node.isName()) { return true; } checkArgument(node.isGetProp()); while (node.isGetProp()) { node = node.getFirstChild(); } return !(node.isName() && isNameAssignedTo(no...
[ "private", "boolean", "isSafeReplacement", "(", "Node", "node", ",", "Node", "replacement", ")", "{", "// No checks are needed for simple names.", "if", "(", "node", ".", "isName", "(", ")", ")", "{", "return", "true", ";", "}", "checkArgument", "(", "node", "...
Checks name referenced in node to determine if it might have changed. @return Whether the replacement can be made.
[ "Checks", "name", "referenced", "in", "node", "to", "determine", "if", "it", "might", "have", "changed", "." ]
train
https://github.com/google/closure-compiler/blob/d81e36740f6a9e8ac31a825ee8758182e1dc5aae/src/com/google/javascript/jscomp/ExploitAssigns.java#L207-L219
gitblit/fathom
fathom-x509/src/main/java/fathom/x509/X509Utils.java
X509Utils.prepareX509Infrastructure
public static void prepareX509Infrastructure(X509Metadata metadata, File serverKeyStore, File serverTrustStore, X509Log x509log) { """ Prepare all the certificates and stores necessary for a Fathom server. @param metadata @param serverKeyStore @param serverTrustStore @param x509log """ // make th...
java
public static void prepareX509Infrastructure(X509Metadata metadata, File serverKeyStore, File serverTrustStore, X509Log x509log) { // make the specified folder, if necessary File folder = serverKeyStore.getParentFile(); folder.mkdirs(); // Fathom CA certificate File caKeyStore =...
[ "public", "static", "void", "prepareX509Infrastructure", "(", "X509Metadata", "metadata", ",", "File", "serverKeyStore", ",", "File", "serverTrustStore", ",", "X509Log", "x509log", ")", "{", "// make the specified folder, if necessary", "File", "folder", "=", "serverKeySt...
Prepare all the certificates and stores necessary for a Fathom server. @param metadata @param serverKeyStore @param serverTrustStore @param x509log
[ "Prepare", "all", "the", "certificates", "and", "stores", "necessary", "for", "a", "Fathom", "server", "." ]
train
https://github.com/gitblit/fathom/blob/f2f820eb16e9fea1e36ad4eda4ed51b35f056538/fathom-x509/src/main/java/fathom/x509/X509Utils.java#L260-L295
SvenEwald/xmlbeam
src/main/java/org/xmlbeam/util/intern/DOMHelper.java
DOMHelper.nodesAreEqual
public static boolean nodesAreEqual(final Node a, final Node b) { """ Implementation independent version of the Node.isEqualNode() method. Matches the same algorithm as the nodeHashCode method. <br> Two nodes are equal if and only if the following conditions are satisfied: <ul> <li>The two nodes are of the sam...
java
public static boolean nodesAreEqual(final Node a, final Node b) { if (a == b) { return true; } if ((a == null) || (b == null)) { return false; } if (!Arrays.equals(getNodeAttributes(a), getNodeAttributes(b))) { return false; } i...
[ "public", "static", "boolean", "nodesAreEqual", "(", "final", "Node", "a", ",", "final", "Node", "b", ")", "{", "if", "(", "a", "==", "b", ")", "{", "return", "true", ";", "}", "if", "(", "(", "a", "==", "null", ")", "||", "(", "b", "==", "null...
Implementation independent version of the Node.isEqualNode() method. Matches the same algorithm as the nodeHashCode method. <br> Two nodes are equal if and only if the following conditions are satisfied: <ul> <li>The two nodes are of the same type.</li> <li>The following string attributes are equal: <code>nodeName</cod...
[ "Implementation", "independent", "version", "of", "the", "Node", ".", "isEqualNode", "()", "method", ".", "Matches", "the", "same", "algorithm", "as", "the", "nodeHashCode", "method", ".", "<br", ">", "Two", "nodes", "are", "equal", "if", "and", "only", "if"...
train
https://github.com/SvenEwald/xmlbeam/blob/acaac1b8fa28d246f17187f5e3c6696458a0b447/src/main/java/org/xmlbeam/util/intern/DOMHelper.java#L202-L219
powermock/powermock
powermock-api/powermock-api-easymock/src/main/java/org/powermock/api/easymock/PowerMock.java
PowerMock.createMock
public static <T> T createMock(Class<T> type, ConstructorArgs constructorArgs, Method... methods) { """ Creates a mock object that supports mocking of final and native methods and invokes a specific constructor. @param <T> the type of the mock object @param type the type of the mock obj...
java
public static <T> T createMock(Class<T> type, ConstructorArgs constructorArgs, Method... methods) { return doMock(type, false, new DefaultMockStrategy(), constructorArgs, methods); }
[ "public", "static", "<", "T", ">", "T", "createMock", "(", "Class", "<", "T", ">", "type", ",", "ConstructorArgs", "constructorArgs", ",", "Method", "...", "methods", ")", "{", "return", "doMock", "(", "type", ",", "false", ",", "new", "DefaultMockStrategy...
Creates a mock object that supports mocking of final and native methods and invokes a specific constructor. @param <T> the type of the mock object @param type the type of the mock object @param constructorArgs The constructor arguments that will be used to invoke a special constructor. @param me...
[ "Creates", "a", "mock", "object", "that", "supports", "mocking", "of", "final", "and", "native", "methods", "and", "invokes", "a", "specific", "constructor", "." ]
train
https://github.com/powermock/powermock/blob/e8cd68026c284c6a7efe66959809eeebd8d1f9ad/powermock-api/powermock-api-easymock/src/main/java/org/powermock/api/easymock/PowerMock.java#L109-L111
alkacon/opencms-core
src/org/opencms/ui/components/CmsUserInfo.java
CmsUserInfo.generateInfo
private String generateInfo(CmsObject cms, Locale locale) { """ Generates the info data HTML.<p> @param cms the cms context @param locale the locale @return the info data HTML """ StringBuffer infoHtml = new StringBuffer(128); infoHtml.append("<p>").append(CmsStringUtil.escapeHtml(m_use...
java
private String generateInfo(CmsObject cms, Locale locale) { StringBuffer infoHtml = new StringBuffer(128); infoHtml.append("<p>").append(CmsStringUtil.escapeHtml(m_user.getSimpleName())).append("</p>"); if (CmsStringUtil.isNotEmptyOrWhitespaceOnly(m_user.getFirstname())) { infoHtml....
[ "private", "String", "generateInfo", "(", "CmsObject", "cms", ",", "Locale", "locale", ")", "{", "StringBuffer", "infoHtml", "=", "new", "StringBuffer", "(", "128", ")", ";", "infoHtml", ".", "append", "(", "\"<p>\"", ")", ".", "append", "(", "CmsStringUtil"...
Generates the info data HTML.<p> @param cms the cms context @param locale the locale @return the info data HTML
[ "Generates", "the", "info", "data", "HTML", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/ui/components/CmsUserInfo.java#L297-L309
moparisthebest/beehive
beehive-netui-core/src/main/java/org/apache/beehive/netui/pageflow/FlowController.java
FlowController.getActionMethodForward
ActionForward getActionMethodForward( String actionName, Object inputForm, HttpServletRequest request, HttpServletResponse response, ActionMapping mapping ) throws Exception { """ Get the ActionForward returned by the acti...
java
ActionForward getActionMethodForward( String actionName, Object inputForm, HttpServletRequest request, HttpServletResponse response, ActionMapping mapping ) throws Exception { // // Find the method. ...
[ "ActionForward", "getActionMethodForward", "(", "String", "actionName", ",", "Object", "inputForm", ",", "HttpServletRequest", "request", ",", "HttpServletResponse", "response", ",", "ActionMapping", "mapping", ")", "throws", "Exception", "{", "//", "// Find the method.",...
Get the ActionForward returned by the action handler method that corresponds to the given action name and form-bean, or send an error to the browser if there is no matching method. @param actionName the name of the Struts action to handle. @param inputForm the form-bean associated with the action. May be <code>null</...
[ "Get", "the", "ActionForward", "returned", "by", "the", "action", "handler", "method", "that", "corresponds", "to", "the", "given", "action", "name", "and", "form", "-", "bean", "or", "send", "an", "error", "to", "the", "browser", "if", "there", "is", "no"...
train
https://github.com/moparisthebest/beehive/blob/4246a0cc40ce3c05f1a02c2da2653ac622703d77/beehive-netui-core/src/main/java/org/apache/beehive/netui/pageflow/FlowController.java#L794-L824
looly/hutool
hutool-core/src/main/java/cn/hutool/core/io/FileUtil.java
FileUtil.getReader
public static BufferedReader getReader(String path, String charsetName) throws IORuntimeException { """ 获得一个文件读取器 @param path 绝对路径 @param charsetName 字符集 @return BufferedReader对象 @throws IORuntimeException IO异常 """ return getReader(file(path), charsetName); }
java
public static BufferedReader getReader(String path, String charsetName) throws IORuntimeException { return getReader(file(path), charsetName); }
[ "public", "static", "BufferedReader", "getReader", "(", "String", "path", ",", "String", "charsetName", ")", "throws", "IORuntimeException", "{", "return", "getReader", "(", "file", "(", "path", ")", ",", "charsetName", ")", ";", "}" ]
获得一个文件读取器 @param path 绝对路径 @param charsetName 字符集 @return BufferedReader对象 @throws IORuntimeException IO异常
[ "获得一个文件读取器" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/io/FileUtil.java#L2017-L2019
mapfish/mapfish-print
core/src/main/java/org/mapfish/print/map/image/wms/WmsUtilities.java
WmsUtilities.setDpiValue
private static void setDpiValue(final Multimap<String, String> extraParams, final int dpi) { """ Set the DPI value for GeoServer if there are already FORMAT_OPTIONS. """ String searchKey = "FORMAT_OPTIONS"; for (String key: extraParams.keys()) { if (key.equalsIgnoreCase(searchKey)) ...
java
private static void setDpiValue(final Multimap<String, String> extraParams, final int dpi) { String searchKey = "FORMAT_OPTIONS"; for (String key: extraParams.keys()) { if (key.equalsIgnoreCase(searchKey)) { Collection<String> values = extraParams.removeAll(key); ...
[ "private", "static", "void", "setDpiValue", "(", "final", "Multimap", "<", "String", ",", "String", ">", "extraParams", ",", "final", "int", "dpi", ")", "{", "String", "searchKey", "=", "\"FORMAT_OPTIONS\"", ";", "for", "(", "String", "key", ":", "extraParam...
Set the DPI value for GeoServer if there are already FORMAT_OPTIONS.
[ "Set", "the", "DPI", "value", "for", "GeoServer", "if", "there", "are", "already", "FORMAT_OPTIONS", "." ]
train
https://github.com/mapfish/mapfish-print/blob/25a452cb39f592bd8a53b20db1037703898e1e22/core/src/main/java/org/mapfish/print/map/image/wms/WmsUtilities.java#L188-L204
biojava/biojava
biojava-core/src/main/java/org/biojava/nbio/core/sequence/ProteinSequence.java
ProteinSequence.setParentDNASequence
public void setParentDNASequence(AbstractSequence<NucleotideCompound> parentDNASequence, Integer begin, Integer end) { """ However, due to the derivation of this class, this is the only possible type argument for this parameter... """ this.setParentSequence(parentDNASequence); setBioBegin(begin); setBioE...
java
public void setParentDNASequence(AbstractSequence<NucleotideCompound> parentDNASequence, Integer begin, Integer end) { this.setParentSequence(parentDNASequence); setBioBegin(begin); setBioEnd(end); }
[ "public", "void", "setParentDNASequence", "(", "AbstractSequence", "<", "NucleotideCompound", ">", "parentDNASequence", ",", "Integer", "begin", ",", "Integer", "end", ")", "{", "this", ".", "setParentSequence", "(", "parentDNASequence", ")", ";", "setBioBegin", "("...
However, due to the derivation of this class, this is the only possible type argument for this parameter...
[ "However", "due", "to", "the", "derivation", "of", "this", "class", "this", "is", "the", "only", "possible", "type", "argument", "for", "this", "parameter", "..." ]
train
https://github.com/biojava/biojava/blob/a1c71a8e3d40cc32104b1d387a3d3b560b43356e/biojava-core/src/main/java/org/biojava/nbio/core/sequence/ProteinSequence.java#L149-L153
Azure/azure-sdk-for-java
resources/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/resources/v2018_02_01/implementation/ResourcesInner.java
ResourcesInner.beginMoveResources
public void beginMoveResources(String sourceResourceGroupName, ResourcesMoveInfo parameters) { """ Moves resources from one resource group to another resource group. The resources to move must be in the same source resource group. The target resource group may be in a different subscription. When moving resources...
java
public void beginMoveResources(String sourceResourceGroupName, ResourcesMoveInfo parameters) { beginMoveResourcesWithServiceResponseAsync(sourceResourceGroupName, parameters).toBlocking().single().body(); }
[ "public", "void", "beginMoveResources", "(", "String", "sourceResourceGroupName", ",", "ResourcesMoveInfo", "parameters", ")", "{", "beginMoveResourcesWithServiceResponseAsync", "(", "sourceResourceGroupName", ",", "parameters", ")", ".", "toBlocking", "(", ")", ".", "sin...
Moves resources from one resource group to another resource group. The resources to move must be in the same source resource group. The target resource group may be in a different subscription. When moving resources, both the source group and the target group are locked for the duration of the operation. Write and dele...
[ "Moves", "resources", "from", "one", "resource", "group", "to", "another", "resource", "group", ".", "The", "resources", "to", "move", "must", "be", "in", "the", "same", "source", "resource", "group", ".", "The", "target", "resource", "group", "may", "be", ...
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/resources/resource-manager/v2018_02_01/src/main/java/com/microsoft/azure/management/resources/v2018_02_01/implementation/ResourcesInner.java#L491-L493
threerings/nenya
core/src/main/java/com/threerings/media/tile/TileUtil.java
TileUtil.getTileHash
public static int getTileHash (int x, int y) { """ Compute some hash value for "randomizing" tileset picks based on x and y coordinates. @return a positive, seemingly random number based on x and y. """ long seed = (((x << 2) ^ y) ^ MULTIPLIER) & MASK; long hash = (seed * MULTIPLIER + ADDEN...
java
public static int getTileHash (int x, int y) { long seed = (((x << 2) ^ y) ^ MULTIPLIER) & MASK; long hash = (seed * MULTIPLIER + ADDEND) & MASK; return (int) (hash >>> 30); }
[ "public", "static", "int", "getTileHash", "(", "int", "x", ",", "int", "y", ")", "{", "long", "seed", "=", "(", "(", "(", "x", "<<", "2", ")", "^", "y", ")", "^", "MULTIPLIER", ")", "&", "MASK", ";", "long", "hash", "=", "(", "seed", "*", "MU...
Compute some hash value for "randomizing" tileset picks based on x and y coordinates. @return a positive, seemingly random number based on x and y.
[ "Compute", "some", "hash", "value", "for", "randomizing", "tileset", "picks", "based", "on", "x", "and", "y", "coordinates", "." ]
train
https://github.com/threerings/nenya/blob/3165a012fd859009db3367f87bd2a5b820cc760a/core/src/main/java/com/threerings/media/tile/TileUtil.java#L58-L63
google/error-prone-javac
src/java.compiler/share/classes/javax/lang/model/util/ElementFilter.java
ElementFilter.constructorsIn
public static List<ExecutableElement> constructorsIn(Iterable<? extends Element> elements) { """ Returns a list of constructors in {@code elements}. @return a list of constructors in {@code elements} @param elements the elements to filter """ return listFilter(elements, CONSTRUCTOR_KIND, ...
java
public static List<ExecutableElement> constructorsIn(Iterable<? extends Element> elements) { return listFilter(elements, CONSTRUCTOR_KIND, ExecutableElement.class); }
[ "public", "static", "List", "<", "ExecutableElement", ">", "constructorsIn", "(", "Iterable", "<", "?", "extends", "Element", ">", "elements", ")", "{", "return", "listFilter", "(", "elements", ",", "CONSTRUCTOR_KIND", ",", "ExecutableElement", ".", "class", ")"...
Returns a list of constructors in {@code elements}. @return a list of constructors in {@code elements} @param elements the elements to filter
[ "Returns", "a", "list", "of", "constructors", "in", "{" ]
train
https://github.com/google/error-prone-javac/blob/a53d069bbdb2c60232ed3811c19b65e41c3e60e0/src/java.compiler/share/classes/javax/lang/model/util/ElementFilter.java#L112-L115
meertensinstituut/mtas
src/main/java/mtas/solr/handler/component/util/MtasSolrResultMerge.java
MtasSolrResultMerge.mergeResponsesSortedSet
private void mergeResponsesSortedSet(SortedSet<Object> originalList, SortedSet<Object> shardList) { """ Merge responses sorted set. @param originalList the original list @param shardList the shard list """ for (Object item : shardList) { originalList.add(item); } }
java
private void mergeResponsesSortedSet(SortedSet<Object> originalList, SortedSet<Object> shardList) { for (Object item : shardList) { originalList.add(item); } }
[ "private", "void", "mergeResponsesSortedSet", "(", "SortedSet", "<", "Object", ">", "originalList", ",", "SortedSet", "<", "Object", ">", "shardList", ")", "{", "for", "(", "Object", "item", ":", "shardList", ")", "{", "originalList", ".", "add", "(", "item"...
Merge responses sorted set. @param originalList the original list @param shardList the shard list
[ "Merge", "responses", "sorted", "set", "." ]
train
https://github.com/meertensinstituut/mtas/blob/f02ae730848616bd88b553efa7f9eddc32818e64/src/main/java/mtas/solr/handler/component/util/MtasSolrResultMerge.java#L239-L243
camunda/camunda-bpmn-model
src/main/java/org/camunda/bpm/model/bpmn/builder/AbstractSignalEventDefinitionBuilder.java
AbstractSignalEventDefinitionBuilder.camundaInSourceExpressionTarget
public B camundaInSourceExpressionTarget(String sourceExpression, String target) { """ Sets a "camunda:in" parameter to pass an expression from the signal-throwing process instance to a variable in the signal-catching process instance @param sourceExpression the expression in the signal-throwing process instan...
java
public B camundaInSourceExpressionTarget(String sourceExpression, String target) { CamundaIn param = modelInstance.newInstance(CamundaIn.class); param.setCamundaSourceExpression(sourceExpression); param.setCamundaTarget(target); addExtensionElement(param); return myself; }
[ "public", "B", "camundaInSourceExpressionTarget", "(", "String", "sourceExpression", ",", "String", "target", ")", "{", "CamundaIn", "param", "=", "modelInstance", ".", "newInstance", "(", "CamundaIn", ".", "class", ")", ";", "param", ".", "setCamundaSourceExpressio...
Sets a "camunda:in" parameter to pass an expression from the signal-throwing process instance to a variable in the signal-catching process instance @param sourceExpression the expression in the signal-throwing process instance @param target the name of the variable in the signal-catching process instance @return the b...
[ "Sets", "a", "camunda", ":", "in", "parameter", "to", "pass", "an", "expression", "from", "the", "signal", "-", "throwing", "process", "instance", "to", "a", "variable", "in", "the", "signal", "-", "catching", "process", "instance" ]
train
https://github.com/camunda/camunda-bpmn-model/blob/debcadf041d10fa62b799de0307b832cea84e5d4/src/main/java/org/camunda/bpm/model/bpmn/builder/AbstractSignalEventDefinitionBuilder.java#L59-L68
nguyenq/tess4j
src/main/java/net/sourceforge/tess4j/util/PdfBoxUtilities.java
PdfBoxUtilities.convertPdf2Png
public static File[] convertPdf2Png(File inputPdfFile) throws IOException { """ Converts PDF to PNG format. @param inputPdfFile input file @return an array of PNG images @throws java.io.IOException """ Path path = Files.createTempDirectory("tessimages"); File imageDir = path.toFile(); ...
java
public static File[] convertPdf2Png(File inputPdfFile) throws IOException { Path path = Files.createTempDirectory("tessimages"); File imageDir = path.toFile(); PDDocument document = null; try { document = PDDocument.load(inputPdfFile); PDFRenderer pdfRenderer = n...
[ "public", "static", "File", "[", "]", "convertPdf2Png", "(", "File", "inputPdfFile", ")", "throws", "IOException", "{", "Path", "path", "=", "Files", ".", "createTempDirectory", "(", "\"tessimages\"", ")", ";", "File", "imageDir", "=", "path", ".", "toFile", ...
Converts PDF to PNG format. @param inputPdfFile input file @return an array of PNG images @throws java.io.IOException
[ "Converts", "PDF", "to", "PNG", "format", "." ]
train
https://github.com/nguyenq/tess4j/blob/cfcd4a8a44042f150b4aaf7bdf5ffc485a2236e1/src/main/java/net/sourceforge/tess4j/util/PdfBoxUtilities.java#L85-L132
kiegroup/jbpm
jbpm-runtime-manager/src/main/java/org/jbpm/runtime/manager/impl/RuntimeEnvironmentBuilder.java
RuntimeEnvironmentBuilder.getDefaultInMemory
public static RuntimeEnvironmentBuilder getDefaultInMemory() { """ Provides default configuration of <code>RuntimeEnvironmentBuilder</code> that is based on: <ul> <li>DefaultRuntimeEnvironment</li> </ul> but it does not have persistence for process engine configured so it will only store process instances in m...
java
public static RuntimeEnvironmentBuilder getDefaultInMemory() { RuntimeEnvironmentBuilder builder = new RuntimeEnvironmentBuilder(new DefaultRuntimeEnvironment(null, false)); builder .addConfiguration("drools.processSignalManagerFactory", DefaultSignalManagerFactory.class.getName()) .addC...
[ "public", "static", "RuntimeEnvironmentBuilder", "getDefaultInMemory", "(", ")", "{", "RuntimeEnvironmentBuilder", "builder", "=", "new", "RuntimeEnvironmentBuilder", "(", "new", "DefaultRuntimeEnvironment", "(", "null", ",", "false", ")", ")", ";", "builder", ".", "a...
Provides default configuration of <code>RuntimeEnvironmentBuilder</code> that is based on: <ul> <li>DefaultRuntimeEnvironment</li> </ul> but it does not have persistence for process engine configured so it will only store process instances in memory @return new instance of <code>RuntimeEnvironmentBuilder</code> that is...
[ "Provides", "default", "configuration", "of", "<code", ">", "RuntimeEnvironmentBuilder<", "/", "code", ">", "that", "is", "based", "on", ":", "<ul", ">", "<li", ">", "DefaultRuntimeEnvironment<", "/", "li", ">", "<", "/", "ul", ">", "but", "it", "does", "n...
train
https://github.com/kiegroup/jbpm/blob/c3473c728aa382ebbea01e380c5e754a96647b82/jbpm-runtime-manager/src/main/java/org/jbpm/runtime/manager/impl/RuntimeEnvironmentBuilder.java#L122-L129
Impetus/Kundera
src/kundera-cassandra/cassandra-core/src/main/java/com/impetus/client/cassandra/datahandler/CassandraDataHandlerBase.java
CassandraDataHandlerBase.prepareSuperColumn
private void prepareSuperColumn(ThriftRow tr, EntityMetadata m, Object value, byte[] name, long timestamp) { """ Prepare super column. @param tr the tr @param m the m @param value the value @param name the name @param timestamp the timestamp """ if (value != null) { if (...
java
private void prepareSuperColumn(ThriftRow tr, EntityMetadata m, Object value, byte[] name, long timestamp) { if (value != null) { if (m.isCounterColumnType()) { CounterSuperColumn counterSuper = new CounterSuperColumn(); counterSuper.setName(na...
[ "private", "void", "prepareSuperColumn", "(", "ThriftRow", "tr", ",", "EntityMetadata", "m", ",", "Object", "value", ",", "byte", "[", "]", "name", ",", "long", "timestamp", ")", "{", "if", "(", "value", "!=", "null", ")", "{", "if", "(", "m", ".", "...
Prepare super column. @param tr the tr @param m the m @param value the value @param name the name @param timestamp the timestamp
[ "Prepare", "super", "column", "." ]
train
https://github.com/Impetus/Kundera/blob/268958ab1ec09d14ec4d9184f0c8ded7a9158908/src/kundera-cassandra/cassandra-core/src/main/java/com/impetus/client/cassandra/datahandler/CassandraDataHandlerBase.java#L2105-L2130
apache/groovy
src/main/java/org/codehaus/groovy/runtime/DefaultGroovyMethods.java
DefaultGroovyMethods.putAt
public static void putAt(Object self, String property, Object newValue) { """ Allows the subscript operator to be used to set dynamically named property values. <code>bean[somePropertyNameExpression] = foo</code>. The normal property notation of groovy is neater and more concise but only works with property name...
java
public static void putAt(Object self, String property, Object newValue) { InvokerHelper.setProperty(self, property, newValue); }
[ "public", "static", "void", "putAt", "(", "Object", "self", ",", "String", "property", ",", "Object", "newValue", ")", "{", "InvokerHelper", ".", "setProperty", "(", "self", ",", "property", ",", "newValue", ")", ";", "}" ]
Allows the subscript operator to be used to set dynamically named property values. <code>bean[somePropertyNameExpression] = foo</code>. The normal property notation of groovy is neater and more concise but only works with property names which are known at compile time. @param self the object to act upon @param pro...
[ "Allows", "the", "subscript", "operator", "to", "be", "used", "to", "set", "dynamically", "named", "property", "values", ".", "<code", ">", "bean", "[", "somePropertyNameExpression", "]", "=", "foo<", "/", "code", ">", ".", "The", "normal", "property", "nota...
train
https://github.com/apache/groovy/blob/71cf20addb611bb8d097a59e395fd20bc7f31772/src/main/java/org/codehaus/groovy/runtime/DefaultGroovyMethods.java#L419-L421
dashorst/wicket-stuff-markup-validator
jing/src/main/java/com/thaiopensource/validate/nvdl/FilteredAttributes.java
FilteredAttributes.getRealIndex
private int getRealIndex(String uri, String localName) { """ Get the real index, in the initial attributes list of a given attribute. If the attribute is filtered out then return -1. @param uri The attribute uri. @param localName The attribute local name. @return The real index if the attribute is present and ...
java
private int getRealIndex(String uri, String localName) { int index = attributes.getIndex(uri, localName); if (index < 0 || reverseIndex(index) < 0) return -1; return index; }
[ "private", "int", "getRealIndex", "(", "String", "uri", ",", "String", "localName", ")", "{", "int", "index", "=", "attributes", ".", "getIndex", "(", "uri", ",", "localName", ")", ";", "if", "(", "index", "<", "0", "||", "reverseIndex", "(", "index", ...
Get the real index, in the initial attributes list of a given attribute. If the attribute is filtered out then return -1. @param uri The attribute uri. @param localName The attribute local name. @return The real index if the attribute is present and not filtered out, otherwise -1.
[ "Get", "the", "real", "index", "in", "the", "initial", "attributes", "list", "of", "a", "given", "attribute", ".", "If", "the", "attribute", "is", "filtered", "out", "then", "return", "-", "1", "." ]
train
https://github.com/dashorst/wicket-stuff-markup-validator/blob/9e529a4dc8bfdbbe4c794f3132ef400a006560a1/jing/src/main/java/com/thaiopensource/validate/nvdl/FilteredAttributes.java#L133-L138
datacleaner/DataCleaner
desktop/ui/src/main/java/org/datacleaner/widgets/tabs/Packer.java
Packer.setInsetLeft
public Packer setInsetLeft(final int val) { """ sets left Insets on the constraints for the current component to the value specified. """ Insets i = gc.insets; if (i == null) { i = new Insets(0, 0, 0, 0); } gc.insets = new Insets(i.top, val, i.bottom, i.right); ...
java
public Packer setInsetLeft(final int val) { Insets i = gc.insets; if (i == null) { i = new Insets(0, 0, 0, 0); } gc.insets = new Insets(i.top, val, i.bottom, i.right); setConstraints(comp, gc); return this; }
[ "public", "Packer", "setInsetLeft", "(", "final", "int", "val", ")", "{", "Insets", "i", "=", "gc", ".", "insets", ";", "if", "(", "i", "==", "null", ")", "{", "i", "=", "new", "Insets", "(", "0", ",", "0", ",", "0", ",", "0", ")", ";", "}", ...
sets left Insets on the constraints for the current component to the value specified.
[ "sets", "left", "Insets", "on", "the", "constraints", "for", "the", "current", "component", "to", "the", "value", "specified", "." ]
train
https://github.com/datacleaner/DataCleaner/blob/9aa01fdac3560cef51c55df3cb2ac5c690b57639/desktop/ui/src/main/java/org/datacleaner/widgets/tabs/Packer.java#L851-L859
geomajas/geomajas-project-geometry
core/src/main/java/org/geomajas/geometry/service/GeometryIndexService.java
GeometryIndexService.getNextVertex
public GeometryIndex getNextVertex(GeometryIndex index) { """ Given a certain index, find the next vertex in line. @param index The index to start out from. Must point to either a vertex or and edge. @return Returns the next vertex index. Note that no geometry is given, and so no actual checking is done. It j...
java
public GeometryIndex getNextVertex(GeometryIndex index) { if (index.hasChild()) { return new GeometryIndex(index.getType(), index.getValue(), getNextVertex(index.getChild())); } else { return new GeometryIndex(GeometryIndexType.TYPE_VERTEX, index.getValue() + 1, null); } }
[ "public", "GeometryIndex", "getNextVertex", "(", "GeometryIndex", "index", ")", "{", "if", "(", "index", ".", "hasChild", "(", ")", ")", "{", "return", "new", "GeometryIndex", "(", "index", ".", "getType", "(", ")", ",", "index", ".", "getValue", "(", ")...
Given a certain index, find the next vertex in line. @param index The index to start out from. Must point to either a vertex or and edge. @return Returns the next vertex index. Note that no geometry is given, and so no actual checking is done. It just returns the theoretical answer.
[ "Given", "a", "certain", "index", "find", "the", "next", "vertex", "in", "line", "." ]
train
https://github.com/geomajas/geomajas-project-geometry/blob/09a214fede69c9c01e41630828c4abbb551a557d/core/src/main/java/org/geomajas/geometry/service/GeometryIndexService.java#L500-L506
looly/hutool
hutool-core/src/main/java/cn/hutool/core/builder/HashCodeBuilder.java
HashCodeBuilder.reflectionHashCode
public static int reflectionHashCode(final Object object, final Collection<String> excludeFields) { """ <p> Uses reflection to build a valid hash code from the fields of {@code object}. </p> <p> This constructor uses two hard coded choices for the constants needed to build a hash code. </p> <p> It uses ...
java
public static int reflectionHashCode(final Object object, final Collection<String> excludeFields) { return reflectionHashCode(object, ArrayUtil.toArray(excludeFields, String.class)); }
[ "public", "static", "int", "reflectionHashCode", "(", "final", "Object", "object", ",", "final", "Collection", "<", "String", ">", "excludeFields", ")", "{", "return", "reflectionHashCode", "(", "object", ",", "ArrayUtil", ".", "toArray", "(", "excludeFields", "...
<p> Uses reflection to build a valid hash code from the fields of {@code object}. </p> <p> This constructor uses two hard coded choices for the constants needed to build a hash code. </p> <p> It uses <code>AccessibleObject.setAccessible</code> to gain access to private fields. This means that it will throw a security...
[ "<p", ">", "Uses", "reflection", "to", "build", "a", "valid", "hash", "code", "from", "the", "fields", "of", "{", "@code", "object", "}", ".", "<", "/", "p", ">" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/builder/HashCodeBuilder.java#L418-L420
bmwcarit/joynr
java/core/libjoynr/src/main/java/io/joynr/dispatching/subscription/PublicationManagerImpl.java
PublicationManagerImpl.restoreQueuedSubscription
private void restoreQueuedSubscription(String providerId, ProviderContainer providerContainer) { """ Called every time a provider is registered to check whether there are already subscriptionRequests waiting. @param providerId provider id @param providerContainer provider container """ Collection<...
java
private void restoreQueuedSubscription(String providerId, ProviderContainer providerContainer) { Collection<PublicationInformation> queuedRequests = queuedSubscriptionRequests.get(providerId); Iterator<PublicationInformation> queuedRequestsIterator = queuedRequests.iterator(); while (queuedReque...
[ "private", "void", "restoreQueuedSubscription", "(", "String", "providerId", ",", "ProviderContainer", "providerContainer", ")", "{", "Collection", "<", "PublicationInformation", ">", "queuedRequests", "=", "queuedSubscriptionRequests", ".", "get", "(", "providerId", ")",...
Called every time a provider is registered to check whether there are already subscriptionRequests waiting. @param providerId provider id @param providerContainer provider container
[ "Called", "every", "time", "a", "provider", "is", "registered", "to", "check", "whether", "there", "are", "already", "subscriptionRequests", "waiting", "." ]
train
https://github.com/bmwcarit/joynr/blob/b7a92bad1cf2f093de080facd2c803560f4c6c26/java/core/libjoynr/src/main/java/io/joynr/dispatching/subscription/PublicationManagerImpl.java#L602-L615
code4everything/util
src/main/java/com/zhazhapan/util/dialog/Alerts.java
Alerts.showWarning
public static Optional<ButtonType> showWarning(String title, String content) { """ 弹出警告框 @param title 标题 @param content 内容 @return {@link ButtonType} """ return showWarning(title, null, content); }
java
public static Optional<ButtonType> showWarning(String title, String content) { return showWarning(title, null, content); }
[ "public", "static", "Optional", "<", "ButtonType", ">", "showWarning", "(", "String", "title", ",", "String", "content", ")", "{", "return", "showWarning", "(", "title", ",", "null", ",", "content", ")", ";", "}" ]
弹出警告框 @param title 标题 @param content 内容 @return {@link ButtonType}
[ "弹出警告框" ]
train
https://github.com/code4everything/util/blob/1fc9f0ead1108f4d7208ba7c000df4244f708418/src/main/java/com/zhazhapan/util/dialog/Alerts.java#L57-L59
google/closure-compiler
src/com/google/javascript/jscomp/modules/ResolveExportResult.java
ResolveExportResult.copy
ResolveExportResult copy(Node sourceNode, Binding.CreatedBy createdBy) { """ Creates a new result that has the given node for the source of the binding and given type of binding. """ checkNotNull(sourceNode); if (binding == null) { return this; } return new ResolveExportResult(binding....
java
ResolveExportResult copy(Node sourceNode, Binding.CreatedBy createdBy) { checkNotNull(sourceNode); if (binding == null) { return this; } return new ResolveExportResult(binding.copy(sourceNode, createdBy), state); }
[ "ResolveExportResult", "copy", "(", "Node", "sourceNode", ",", "Binding", ".", "CreatedBy", "createdBy", ")", "{", "checkNotNull", "(", "sourceNode", ")", ";", "if", "(", "binding", "==", "null", ")", "{", "return", "this", ";", "}", "return", "new", "Reso...
Creates a new result that has the given node for the source of the binding and given type of binding.
[ "Creates", "a", "new", "result", "that", "has", "the", "given", "node", "for", "the", "source", "of", "the", "binding", "and", "given", "type", "of", "binding", "." ]
train
https://github.com/google/closure-compiler/blob/d81e36740f6a9e8ac31a825ee8758182e1dc5aae/src/com/google/javascript/jscomp/modules/ResolveExportResult.java#L47-L55
dbflute-session/tomcat-boot
src/main/java/org/dbflute/tomcat/util/BotmReflectionUtil.java
BotmReflectionUtil.getAccessibleMethodFlexibly
public static Method getAccessibleMethodFlexibly(Class<?> clazz, String methodName, Class<?>[] argTypes) { """ Get the accessible method that means as follows: <pre> o target class's methods = all o superclass's methods = public or protected </pre> And it has the flexibly searching so you can specify types ...
java
public static Method getAccessibleMethodFlexibly(Class<?> clazz, String methodName, Class<?>[] argTypes) { assertObjectNotNull("clazz", clazz); assertStringNotNullAndNotTrimmedEmpty("methodName", methodName); return findMethod(clazz, methodName, argTypes, VisibilityType.ACCESSIBLE, true); }
[ "public", "static", "Method", "getAccessibleMethodFlexibly", "(", "Class", "<", "?", ">", "clazz", ",", "String", "methodName", ",", "Class", "<", "?", ">", "[", "]", "argTypes", ")", "{", "assertObjectNotNull", "(", "\"clazz\"", ",", "clazz", ")", ";", "a...
Get the accessible method that means as follows: <pre> o target class's methods = all o superclass's methods = public or protected </pre> And it has the flexibly searching so you can specify types of sub-class to argTypes. But if overload methods exist, it returns the first-found method. @param clazz The type of clas...
[ "Get", "the", "accessible", "method", "that", "means", "as", "follows", ":", "<pre", ">", "o", "target", "class", "s", "methods", "=", "all", "o", "superclass", "s", "methods", "=", "public", "or", "protected", "<", "/", "pre", ">", "And", "it", "has",...
train
https://github.com/dbflute-session/tomcat-boot/blob/fe941f88b6be083781873126f5b12d4c16bb9073/src/main/java/org/dbflute/tomcat/util/BotmReflectionUtil.java#L355-L359
spotbugs/spotbugs
spotbugs/src/main/java/edu/umd/cs/findbugs/PluginLoader.java
PluginLoader.guessManifest
@CheckForNull private static File guessManifest(@Nonnull File parent) { """ Trying to find the manifest of "exploded plugin" in the current dir, "standard jar" manifest location or "standard" Eclipse location (sibling to the current classpath) """ File file = new File(parent, "MANIFEST.MF"); ...
java
@CheckForNull private static File guessManifest(@Nonnull File parent) { File file = new File(parent, "MANIFEST.MF"); if(!file.isFile()){ file = new File(parent, "META-INF/MANIFEST.MF"); } if(!file.isFile()){ file = new File(parent, "../META-INF/MANIFEST.MF"); ...
[ "@", "CheckForNull", "private", "static", "File", "guessManifest", "(", "@", "Nonnull", "File", "parent", ")", "{", "File", "file", "=", "new", "File", "(", "parent", ",", "\"MANIFEST.MF\"", ")", ";", "if", "(", "!", "file", ".", "isFile", "(", ")", ")...
Trying to find the manifest of "exploded plugin" in the current dir, "standard jar" manifest location or "standard" Eclipse location (sibling to the current classpath)
[ "Trying", "to", "find", "the", "manifest", "of", "exploded", "plugin", "in", "the", "current", "dir", "standard", "jar", "manifest", "location", "or", "standard", "Eclipse", "location", "(", "sibling", "to", "the", "current", "classpath", ")" ]
train
https://github.com/spotbugs/spotbugs/blob/f6365c6eea6515035bded38efa4a7c8b46ccf28c/spotbugs/src/main/java/edu/umd/cs/findbugs/PluginLoader.java#L359-L372
UrielCh/ovh-java-sdk
ovh-java-sdk-telephony/src/main/java/net/minidev/ovh/api/ApiOvhTelephony.java
ApiOvhTelephony.billingAccount_line_serviceName_dissociateDevice_POST
public void billingAccount_line_serviceName_dissociateDevice_POST(String billingAccount, String serviceName, String ipAddress, String macAddress) throws IOException { """ Dissociate a device from the current line with the device mac address REST: POST /telephony/{billingAccount}/line/{serviceName}/dissociateDev...
java
public void billingAccount_line_serviceName_dissociateDevice_POST(String billingAccount, String serviceName, String ipAddress, String macAddress) throws IOException { String qPath = "/telephony/{billingAccount}/line/{serviceName}/dissociateDevice"; StringBuilder sb = path(qPath, billingAccount, serviceName); Hash...
[ "public", "void", "billingAccount_line_serviceName_dissociateDevice_POST", "(", "String", "billingAccount", ",", "String", "serviceName", ",", "String", "ipAddress", ",", "String", "macAddress", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/telephony/{bil...
Dissociate a device from the current line with the device mac address REST: POST /telephony/{billingAccount}/line/{serviceName}/dissociateDevice @param macAddress [required] The mac address of the device you want to dissociate from the line (format: AABBCCDDEEFF) @param ipAddress [required] The public phone IP address...
[ "Dissociate", "a", "device", "from", "the", "current", "line", "with", "the", "device", "mac", "address" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-telephony/src/main/java/net/minidev/ovh/api/ApiOvhTelephony.java#L2162-L2169
spring-projects/spring-data-solr
src/main/java/org/springframework/data/solr/core/QueryParserBase.java
QueryParserBase.appendRequestHandler
protected void appendRequestHandler(SolrQuery solrQuery, @Nullable String requestHandler) { """ Set request handler parameter for {@link SolrQuery} @param solrQuery @param requestHandler """ if (StringUtils.isNotBlank(requestHandler)) { solrQuery.add(CommonParams.QT, requestHandler); } }
java
protected void appendRequestHandler(SolrQuery solrQuery, @Nullable String requestHandler) { if (StringUtils.isNotBlank(requestHandler)) { solrQuery.add(CommonParams.QT, requestHandler); } }
[ "protected", "void", "appendRequestHandler", "(", "SolrQuery", "solrQuery", ",", "@", "Nullable", "String", "requestHandler", ")", "{", "if", "(", "StringUtils", ".", "isNotBlank", "(", "requestHandler", ")", ")", "{", "solrQuery", ".", "add", "(", "CommonParams...
Set request handler parameter for {@link SolrQuery} @param solrQuery @param requestHandler
[ "Set", "request", "handler", "parameter", "for", "{", "@link", "SolrQuery", "}" ]
train
https://github.com/spring-projects/spring-data-solr/blob/20be5cb82498b70134dfda6c1a91ad21f8e657e0/src/main/java/org/springframework/data/solr/core/QueryParserBase.java#L499-L503
jbundle/jbundle
app/program/packages/src/main/java/org/jbundle/app/program/packages/screen/PackagesScreen.java
PackagesScreen.doCommand
public boolean doCommand(String strCommand, ScreenField sourceSField, int iCommandOptions) { """ Process the command. <br />Step 1 - Process the command if possible and return true if processed. <br />Step 2 - If I can't process, pass to all children (with me as the source). <br />Step 3 - If children didn't pr...
java
public boolean doCommand(String strCommand, ScreenField sourceSField, int iCommandOptions) { if (Packages.SCAN.equalsIgnoreCase(strCommand)) { Map<String,Object> properties = new HashMap<String,Object>(); properties.put(DBParams.PROCESS, ScanPackagesProcess.class.getName()); ...
[ "public", "boolean", "doCommand", "(", "String", "strCommand", ",", "ScreenField", "sourceSField", ",", "int", "iCommandOptions", ")", "{", "if", "(", "Packages", ".", "SCAN", ".", "equalsIgnoreCase", "(", "strCommand", ")", ")", "{", "Map", "<", "String", "...
Process the command. <br />Step 1 - Process the command if possible and return true if processed. <br />Step 2 - If I can't process, pass to all children (with me as the source). <br />Step 3 - If children didn't process, pass to parent (with me as the source). <br />Note: Never pass to a parent or child that matches t...
[ "Process", "the", "command", ".", "<br", "/", ">", "Step", "1", "-", "Process", "the", "command", "if", "possible", "and", "return", "true", "if", "processed", ".", "<br", "/", ">", "Step", "2", "-", "If", "I", "can", "t", "process", "pass", "to", ...
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/app/program/packages/src/main/java/org/jbundle/app/program/packages/screen/PackagesScreen.java#L122-L135
gosu-lang/gosu-lang
gosu-core-api/src/main/java/gw/util/GosuStringUtil.java
GosuStringUtil.countMatches
public static int countMatches(String str, String sub) { """ <p>Counts how many times the substring appears in the larger String.</p> <p>A <code>null</code> or empty ("") String input returns <code>0</code>.</p> <pre> GosuStringUtil.countMatches(null, *) = 0 GosuStringUtil.countMatches("", *) ...
java
public static int countMatches(String str, String sub) { if (isEmpty(str) || isEmpty(sub)) { return 0; } int count = 0; int idx = 0; while ((idx = str.indexOf(sub, idx)) != -1) { count++; idx += sub.length(); } return count; }
[ "public", "static", "int", "countMatches", "(", "String", "str", ",", "String", "sub", ")", "{", "if", "(", "isEmpty", "(", "str", ")", "||", "isEmpty", "(", "sub", ")", ")", "{", "return", "0", ";", "}", "int", "count", "=", "0", ";", "int", "id...
<p>Counts how many times the substring appears in the larger String.</p> <p>A <code>null</code> or empty ("") String input returns <code>0</code>.</p> <pre> GosuStringUtil.countMatches(null, *) = 0 GosuStringUtil.countMatches("", *) = 0 GosuStringUtil.countMatches("abba", null) = 0 GosuStringUtil.count...
[ "<p", ">", "Counts", "how", "many", "times", "the", "substring", "appears", "in", "the", "larger", "String", ".", "<", "/", "p", ">" ]
train
https://github.com/gosu-lang/gosu-lang/blob/d6e9261b137ce66fef3726cabe7826d4a1f946b7/gosu-core-api/src/main/java/gw/util/GosuStringUtil.java#L4859-L4870
julienledem/brennus
brennus-asm/src/main/java/brennus/asm/specializer/Specializer.java
Specializer.specializeInstance
private Object specializeInstance(ClassDescriptor specializedClass, Object t) { """ creates a specialized copy of the given instance @param specializedClass target specialized class to create an instance of @param t the object to copy and specialize @return the specialized instance. Should be functionally equiv...
java
private Object specializeInstance(ClassDescriptor specializedClass, Object t) { try (Logger l = new Logger("specializeInstance(" + specializedClass.getSpecializedClass().getSimpleName() + " , " + t + ")")) { if (!specializedClass.isSpecialized()) { l.log("value unchanged"); return t; } ...
[ "private", "Object", "specializeInstance", "(", "ClassDescriptor", "specializedClass", ",", "Object", "t", ")", "{", "try", "(", "Logger", "l", "=", "new", "Logger", "(", "\"specializeInstance(\"", "+", "specializedClass", ".", "getSpecializedClass", "(", ")", "."...
creates a specialized copy of the given instance @param specializedClass target specialized class to create an instance of @param t the object to copy and specialize @return the specialized instance. Should be functionally equivalent to t
[ "creates", "a", "specialized", "copy", "of", "the", "given", "instance" ]
train
https://github.com/julienledem/brennus/blob/0798fb565d95af19ddc5accd084e58c4e882dbd0/brennus-asm/src/main/java/brennus/asm/specializer/Specializer.java#L79-L111
auth0/jwks-rsa-java
src/main/java/com/auth0/jwk/Jwk.java
Jwk.getPublicKey
@SuppressWarnings("WeakerAccess") public PublicKey getPublicKey() throws InvalidPublicKeyException { """ Returns a {@link PublicKey} if the {@code 'alg'} is {@code 'RSA'} @return a public key @throws InvalidPublicKeyException if the key cannot be built or the key type is not RSA """ if (!PUBLIC...
java
@SuppressWarnings("WeakerAccess") public PublicKey getPublicKey() throws InvalidPublicKeyException { if (!PUBLIC_KEY_ALGORITHM.equalsIgnoreCase(type)) { throw new InvalidPublicKeyException("The key is not of type RSA", null); } try { KeyFactory kf = KeyFactory.getInst...
[ "@", "SuppressWarnings", "(", "\"WeakerAccess\"", ")", "public", "PublicKey", "getPublicKey", "(", ")", "throws", "InvalidPublicKeyException", "{", "if", "(", "!", "PUBLIC_KEY_ALGORITHM", ".", "equalsIgnoreCase", "(", "type", ")", ")", "{", "throw", "new", "Invali...
Returns a {@link PublicKey} if the {@code 'alg'} is {@code 'RSA'} @return a public key @throws InvalidPublicKeyException if the key cannot be built or the key type is not RSA
[ "Returns", "a", "{", "@link", "PublicKey", "}", "if", "the", "{", "@code", "alg", "}", "is", "{", "@code", "RSA", "}" ]
train
https://github.com/auth0/jwks-rsa-java/blob/9deba212be4278e50ae75a54b3bc6c96359b7e69/src/main/java/com/auth0/jwk/Jwk.java#L167-L182
kuali/ojb-1.0.4
src/java/org/apache/ojb/broker/metadata/RepositoryPersistor.java
RepositoryPersistor.writeToFile
public void writeToFile(DescriptorRepository repository, ConnectionRepository conRepository, OutputStream out) { """ Write the {@link DescriptorRepository} to the given output object. """ RepositoryTags tags = RepositoryTags.getInstance(); try { if (log.isDebugEnabled())...
java
public void writeToFile(DescriptorRepository repository, ConnectionRepository conRepository, OutputStream out) { RepositoryTags tags = RepositoryTags.getInstance(); try { if (log.isDebugEnabled()) log.debug("## Write repository file ##" + ...
[ "public", "void", "writeToFile", "(", "DescriptorRepository", "repository", ",", "ConnectionRepository", "conRepository", ",", "OutputStream", "out", ")", "{", "RepositoryTags", "tags", "=", "RepositoryTags", ".", "getInstance", "(", ")", ";", "try", "{", "if", "(...
Write the {@link DescriptorRepository} to the given output object.
[ "Write", "the", "{" ]
train
https://github.com/kuali/ojb-1.0.4/blob/9a544372f67ce965f662cdc71609dd03683c8f04/src/java/org/apache/ojb/broker/metadata/RepositoryPersistor.java#L82-L126
rhuss/jolokia
agent/jvm/src/main/java/org/jolokia/jvmagent/client/util/OptionsAndArgs.java
OptionsAndArgs.getProcessPattern
public Pattern getProcessPattern() { """ A pattern used for matching a process name. If {@link #getPid()} return a non-null value, this method returns always null @return pattern to match a process name or null """ String arg = extraArgs.size() > 0 ? extraArgs.get(0) : null; try { ...
java
public Pattern getProcessPattern() { String arg = extraArgs.size() > 0 ? extraArgs.get(0) : null; try { return arg != null && getPid() == null ? Pattern.compile(arg, Pattern.CASE_INSENSITIVE) : null; } catch (PatternSyntaxException exp) { ...
[ "public", "Pattern", "getProcessPattern", "(", ")", "{", "String", "arg", "=", "extraArgs", ".", "size", "(", ")", ">", "0", "?", "extraArgs", ".", "get", "(", "0", ")", ":", "null", ";", "try", "{", "return", "arg", "!=", "null", "&&", "getPid", "...
A pattern used for matching a process name. If {@link #getPid()} return a non-null value, this method returns always null @return pattern to match a process name or null
[ "A", "pattern", "used", "for", "matching", "a", "process", "name", ".", "If", "{", "@link", "#getPid", "()", "}", "return", "a", "non", "-", "null", "value", "this", "method", "returns", "always", "null" ]
train
https://github.com/rhuss/jolokia/blob/dc95e7bef859b1829776c5a84c8f7738f5d7d9c3/agent/jvm/src/main/java/org/jolokia/jvmagent/client/util/OptionsAndArgs.java#L172-L182
stephanenicolas/robospice
robospice-core-parent/robospice/src/main/java/com/octo/android/robospice/SpiceManager.java
SpiceManager.putInCache
public <T> void putInCache(final Class<? super T> clazz, final Object requestCacheKey, final T data) { """ Adds some data to the cache, asynchronously. Same as {@link #putInCache(Class, Object, Object, RequestListener)} with a null listener. Operation will take place but you won't be notified. @param clazz a s...
java
public <T> void putInCache(final Class<? super T> clazz, final Object requestCacheKey, final T data) { putInCache(clazz, requestCacheKey, data, null); }
[ "public", "<", "T", ">", "void", "putInCache", "(", "final", "Class", "<", "?", "super", "T", ">", "clazz", ",", "final", "Object", "requestCacheKey", ",", "final", "T", "data", ")", "{", "putInCache", "(", "clazz", ",", "requestCacheKey", ",", "data", ...
Adds some data to the cache, asynchronously. Same as {@link #putInCache(Class, Object, Object, RequestListener)} with a null listener. Operation will take place but you won't be notified. @param clazz a super class or the class of data. @param requestCacheKey the request cache key that data will be stored in. @param da...
[ "Adds", "some", "data", "to", "the", "cache", "asynchronously", ".", "Same", "as", "{" ]
train
https://github.com/stephanenicolas/robospice/blob/8bffde88b3534a961a13cab72a8f07a755f0a0fe/robospice-core-parent/robospice/src/main/java/com/octo/android/robospice/SpiceManager.java#L562-L564
apache/incubator-gobblin
gobblin-config-management/gobblin-config-core/src/main/java/org/apache/gobblin/config/store/hdfs/SimpleHadoopFilesystemConfigStoreFactory.java
SimpleHadoopFilesystemConfigStoreFactory.createConfigStore
@Override public SimpleHadoopFilesystemConfigStore createConfigStore(URI configKey) throws ConfigStoreCreationException { """ Creates a {@link SimpleHadoopFilesystemConfigStore} for the given {@link URI}. The {@link URI} specified should be the fully qualified path to the dataset in question. For example, {@co...
java
@Override public SimpleHadoopFilesystemConfigStore createConfigStore(URI configKey) throws ConfigStoreCreationException { FileSystem fs = createFileSystem(configKey); URI physicalStoreRoot = getStoreRoot(fs, configKey); URI logicalStoreRoot = URI.create(getSchemePrefix() + physicalStoreRoot); return n...
[ "@", "Override", "public", "SimpleHadoopFilesystemConfigStore", "createConfigStore", "(", "URI", "configKey", ")", "throws", "ConfigStoreCreationException", "{", "FileSystem", "fs", "=", "createFileSystem", "(", "configKey", ")", ";", "URI", "physicalStoreRoot", "=", "g...
Creates a {@link SimpleHadoopFilesystemConfigStore} for the given {@link URI}. The {@link URI} specified should be the fully qualified path to the dataset in question. For example, {@code simple-hdfs://[authority]:[port][path-to-config-store][path-to-dataset]}. It is important to note that the path to the config store ...
[ "Creates", "a", "{", "@link", "SimpleHadoopFilesystemConfigStore", "}", "for", "the", "given", "{", "@link", "URI", "}", ".", "The", "{", "@link", "URI", "}", "specified", "should", "be", "the", "fully", "qualified", "path", "to", "the", "dataset", "in", "...
train
https://github.com/apache/incubator-gobblin/blob/f029b4c0fea0fe4aa62f36dda2512344ff708bae/gobblin-config-management/gobblin-config-core/src/main/java/org/apache/gobblin/config/store/hdfs/SimpleHadoopFilesystemConfigStoreFactory.java#L181-L187
netscaler/nitro
src/main/java/com/citrix/netscaler/nitro/resource/stat/cache/cachepolicy_stats.java
cachepolicy_stats.get
public static cachepolicy_stats get(nitro_service service, String policyname) throws Exception { """ Use this API to fetch statistics of cachepolicy_stats resource of given name . """ cachepolicy_stats obj = new cachepolicy_stats(); obj.set_policyname(policyname); cachepolicy_stats response = (cachepolic...
java
public static cachepolicy_stats get(nitro_service service, String policyname) throws Exception{ cachepolicy_stats obj = new cachepolicy_stats(); obj.set_policyname(policyname); cachepolicy_stats response = (cachepolicy_stats) obj.stat_resource(service); return response; }
[ "public", "static", "cachepolicy_stats", "get", "(", "nitro_service", "service", ",", "String", "policyname", ")", "throws", "Exception", "{", "cachepolicy_stats", "obj", "=", "new", "cachepolicy_stats", "(", ")", ";", "obj", ".", "set_policyname", "(", "policynam...
Use this API to fetch statistics of cachepolicy_stats resource of given name .
[ "Use", "this", "API", "to", "fetch", "statistics", "of", "cachepolicy_stats", "resource", "of", "given", "name", "." ]
train
https://github.com/netscaler/nitro/blob/2a98692dcf4e4ec430c7d7baab8382e4ba5a35e4/src/main/java/com/citrix/netscaler/nitro/resource/stat/cache/cachepolicy_stats.java#L169-L174
google/j2objc
jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/Currency.java
Currency.registerInstance
public static Object registerInstance(Currency currency, ULocale locale) { """ Registers a new currency for the provided locale. The returned object is a key that can be used to unregister this currency object. <p>Because ICU may choose to cache Currency objects internally, this must be called at application...
java
public static Object registerInstance(Currency currency, ULocale locale) { return getShim().registerInstance(currency, locale); }
[ "public", "static", "Object", "registerInstance", "(", "Currency", "currency", ",", "ULocale", "locale", ")", "{", "return", "getShim", "(", ")", ".", "registerInstance", "(", "currency", ",", "locale", ")", ";", "}" ]
Registers a new currency for the provided locale. The returned object is a key that can be used to unregister this currency object. <p>Because ICU may choose to cache Currency objects internally, this must be called at application startup, prior to any calls to Currency.getInstance to avoid undefined behavior. @para...
[ "Registers", "a", "new", "currency", "for", "the", "provided", "locale", ".", "The", "returned", "object", "is", "a", "key", "that", "can", "be", "used", "to", "unregister", "this", "currency", "object", "." ]
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/Currency.java#L322-L324
Azure/azure-sdk-for-java
compute/resource-manager/v2017_03_30/src/main/java/com/microsoft/azure/management/compute/v2017_03_30/implementation/VirtualMachineScaleSetsInner.java
VirtualMachineScaleSetsInner.restartAsync
public Observable<OperationStatusResponseInner> restartAsync(String resourceGroupName, String vmScaleSetName) { """ Restarts one or more virtual machines in a VM scale set. @param resourceGroupName The name of the resource group. @param vmScaleSetName The name of the VM scale set. @throws IllegalArgumentExcep...
java
public Observable<OperationStatusResponseInner> restartAsync(String resourceGroupName, String vmScaleSetName) { return restartWithServiceResponseAsync(resourceGroupName, vmScaleSetName).map(new Func1<ServiceResponse<OperationStatusResponseInner>, OperationStatusResponseInner>() { @Override ...
[ "public", "Observable", "<", "OperationStatusResponseInner", ">", "restartAsync", "(", "String", "resourceGroupName", ",", "String", "vmScaleSetName", ")", "{", "return", "restartWithServiceResponseAsync", "(", "resourceGroupName", ",", "vmScaleSetName", ")", ".", "map", ...
Restarts one or more virtual machines in a VM scale set. @param resourceGroupName The name of the resource group. @param vmScaleSetName The name of the VM scale set. @throws IllegalArgumentException thrown if parameters fail the validation @return the observable for the request
[ "Restarts", "one", "or", "more", "virtual", "machines", "in", "a", "VM", "scale", "set", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/compute/resource-manager/v2017_03_30/src/main/java/com/microsoft/azure/management/compute/v2017_03_30/implementation/VirtualMachineScaleSetsInner.java#L2080-L2087
apache/incubator-shardingsphere
sharding-jdbc/sharding-jdbc-core/src/main/java/org/apache/shardingsphere/shardingjdbc/jdbc/core/resultset/ResultSetUtil.java
ResultSetUtil.convertValue
public static Object convertValue(final Object value, final Class<?> convertType) { """ Convert value via expected class type. @param value original value @param convertType expected class type @return converted value """ if (null == value) { return convertNullValue(convertType); ...
java
public static Object convertValue(final Object value, final Class<?> convertType) { if (null == value) { return convertNullValue(convertType); } if (value.getClass() == convertType) { return value; } if (value instanceof Number) { return conve...
[ "public", "static", "Object", "convertValue", "(", "final", "Object", "value", ",", "final", "Class", "<", "?", ">", "convertType", ")", "{", "if", "(", "null", "==", "value", ")", "{", "return", "convertNullValue", "(", "convertType", ")", ";", "}", "if...
Convert value via expected class type. @param value original value @param convertType expected class type @return converted value
[ "Convert", "value", "via", "expected", "class", "type", "." ]
train
https://github.com/apache/incubator-shardingsphere/blob/f88fd29fc345dfb31fdce12e9e96cbfa0fd2402d/sharding-jdbc/sharding-jdbc-core/src/main/java/org/apache/shardingsphere/shardingjdbc/jdbc/core/resultset/ResultSetUtil.java#L44-L62
VoltDB/voltdb
src/frontend/org/voltdb/compiler/VoltDDLElementTracker.java
VoltDDLElementTracker.addPartition
void addPartition(String tableName, String colName) { """ Add a table/column partition mapping for a PARTITION/REPLICATE statements. Validate input data and reject duplicates. @param tableName table name @param colName column name """ if (m_partitionMap.containsKey(tableName.toLowerCase())) { ...
java
void addPartition(String tableName, String colName) { if (m_partitionMap.containsKey(tableName.toLowerCase())) { m_compiler.addInfo(String.format("Replacing partition column %s on table %s with column %s\n", m_partitionMap.get(tableName.toLowerCase()), tableName, ...
[ "void", "addPartition", "(", "String", "tableName", ",", "String", "colName", ")", "{", "if", "(", "m_partitionMap", ".", "containsKey", "(", "tableName", ".", "toLowerCase", "(", ")", ")", ")", "{", "m_compiler", ".", "addInfo", "(", "String", ".", "forma...
Add a table/column partition mapping for a PARTITION/REPLICATE statements. Validate input data and reject duplicates. @param tableName table name @param colName column name
[ "Add", "a", "table", "/", "column", "partition", "mapping", "for", "a", "PARTITION", "/", "REPLICATE", "statements", ".", "Validate", "input", "data", "and", "reject", "duplicates", "." ]
train
https://github.com/VoltDB/voltdb/blob/8afc1031e475835344b5497ea9e7203bc95475ac/src/frontend/org/voltdb/compiler/VoltDDLElementTracker.java#L76-L85
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/cfg/JtaProcessEngineConfiguration.java
JtaProcessEngineConfiguration.initCommandExecutorDbSchemaOperations
@Override protected void initCommandExecutorDbSchemaOperations() { """ provide custom command executor that uses NON-JTA transactions """ if(commandExecutorSchemaOperations == null) { List<CommandInterceptor> commandInterceptorsDbSchemaOperations = new ArrayList<CommandInterceptor>(); command...
java
@Override protected void initCommandExecutorDbSchemaOperations() { if(commandExecutorSchemaOperations == null) { List<CommandInterceptor> commandInterceptorsDbSchemaOperations = new ArrayList<CommandInterceptor>(); commandInterceptorsDbSchemaOperations.add(new LogInterceptor()); commandIntercept...
[ "@", "Override", "protected", "void", "initCommandExecutorDbSchemaOperations", "(", ")", "{", "if", "(", "commandExecutorSchemaOperations", "==", "null", ")", "{", "List", "<", "CommandInterceptor", ">", "commandInterceptorsDbSchemaOperations", "=", "new", "ArrayList", ...
provide custom command executor that uses NON-JTA transactions
[ "provide", "custom", "command", "executor", "that", "uses", "NON", "-", "JTA", "transactions" ]
train
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/cfg/JtaProcessEngineConfiguration.java#L87-L96
scireum/s3ninja
src/main/java/ninja/S3Dispatcher.java
S3Dispatcher.getPartList
private void getPartList(WebContext ctx, Bucket bucket, String id, String uploadId) { """ Handles GET /bucket/id?uploadId=uploadId @param ctx the context describing the current request @param bucket the bucket containing the object to download @param id name of the object to use as download """ ...
java
private void getPartList(WebContext ctx, Bucket bucket, String id, String uploadId) { if (!multipartUploads.contains(uploadId)) { ctx.respondWith().error(HttpResponseStatus.NOT_FOUND, ERROR_MULTIPART_UPLOAD_DOES_NOT_EXIST); return; } Response response = ctx.respondWith()...
[ "private", "void", "getPartList", "(", "WebContext", "ctx", ",", "Bucket", "bucket", ",", "String", "id", ",", "String", "uploadId", ")", "{", "if", "(", "!", "multipartUploads", ".", "contains", "(", "uploadId", ")", ")", "{", "ctx", ".", "respondWith", ...
Handles GET /bucket/id?uploadId=uploadId @param ctx the context describing the current request @param bucket the bucket containing the object to download @param id name of the object to use as download
[ "Handles", "GET", "/", "bucket", "/", "id?uploadId", "=", "uploadId" ]
train
https://github.com/scireum/s3ninja/blob/445eec55c91780267a7f987818b3fedecae009c5/src/main/java/ninja/S3Dispatcher.java#L822-L872
visenze/visearch-sdk-java
src/main/java/com/visenze/visearch/ViSearch.java
ViSearch.insertStatus
@Override public InsertStatus insertStatus(String transId, Integer errorPage, Integer errorLimit) { """ Get insert status by insert trans id, and get errors page. @param transId the id of the insert transaction. @param errorPage page number of the error list @param errorLimit per page limit number of ...
java
@Override public InsertStatus insertStatus(String transId, Integer errorPage, Integer errorLimit) { return dataOperations.insertStatus(transId, errorPage, errorLimit); }
[ "@", "Override", "public", "InsertStatus", "insertStatus", "(", "String", "transId", ",", "Integer", "errorPage", ",", "Integer", "errorLimit", ")", "{", "return", "dataOperations", ".", "insertStatus", "(", "transId", ",", "errorPage", ",", "errorLimit", ")", "...
Get insert status by insert trans id, and get errors page. @param transId the id of the insert transaction. @param errorPage page number of the error list @param errorLimit per page limit number of the error list @return the insert transaction
[ "Get", "insert", "status", "by", "insert", "trans", "id", "and", "get", "errors", "page", "." ]
train
https://github.com/visenze/visearch-sdk-java/blob/133611b84a7489f08bf40b55912ccd2acc7f002c/src/main/java/com/visenze/visearch/ViSearch.java#L184-L187
code4everything/util
src/main/java/com/zhazhapan/util/Checker.java
Checker.checkNull
public static Short checkNull(Short value, Short elseValue) { """ 检查Short是否为null @param value 值 @param elseValue 为null返回的值 @return {@link Short} @since 1.0.8 """ return isNull(value) ? elseValue : value; }
java
public static Short checkNull(Short value, Short elseValue) { return isNull(value) ? elseValue : value; }
[ "public", "static", "Short", "checkNull", "(", "Short", "value", ",", "Short", "elseValue", ")", "{", "return", "isNull", "(", "value", ")", "?", "elseValue", ":", "value", ";", "}" ]
检查Short是否为null @param value 值 @param elseValue 为null返回的值 @return {@link Short} @since 1.0.8
[ "检查Short是否为null" ]
train
https://github.com/code4everything/util/blob/1fc9f0ead1108f4d7208ba7c000df4244f708418/src/main/java/com/zhazhapan/util/Checker.java#L1335-L1337
albfernandez/itext2
src/main/java/com/lowagie/text/rtf/table/RtfTable.java
RtfTable.importTable
private void importTable(PdfPTable table) { """ Imports the rows and settings from the Table into this RtfTable. @param table The source PdfPTable @since 2.1.3 """ this.rows = new ArrayList(); this.tableWidthPercent = table.getWidthPercentage(); // this.tableWidthPercent = table.get...
java
private void importTable(PdfPTable table) { this.rows = new ArrayList(); this.tableWidthPercent = table.getWidthPercentage(); // this.tableWidthPercent = table.getWidth(); this.proportionalWidths = table.getAbsoluteWidths(); // this.proportionalWidths = table.getProportionalWidths(...
[ "private", "void", "importTable", "(", "PdfPTable", "table", ")", "{", "this", ".", "rows", "=", "new", "ArrayList", "(", ")", ";", "this", ".", "tableWidthPercent", "=", "table", ".", "getWidthPercentage", "(", ")", ";", "// this.tableWidthPercent = tabl...
Imports the rows and settings from the Table into this RtfTable. @param table The source PdfPTable @since 2.1.3
[ "Imports", "the", "rows", "and", "settings", "from", "the", "Table", "into", "this", "RtfTable", "." ]
train
https://github.com/albfernandez/itext2/blob/438fc1899367fd13dfdfa8dfdca9a3c1a7783b84/src/main/java/com/lowagie/text/rtf/table/RtfTable.java#L189-L228
Waikato/moa
moa/src/main/java/moa/gui/visualization/AbstractGraphAxes.java
AbstractGraphAxes.yAxis
private void yAxis(Graphics g) { """ Draws the y axis, containing og the axis line, the horizontal helping line and the labels. @param g the Graphics context in which to paint """ // y-axis g.setColor(Color.BLACK); g.drawLine(X_OFFSET_LEFT, calcY(0), X_OFFSET_LEFT, Y_OFFSET_TOP); ...
java
private void yAxis(Graphics g) { // y-axis g.setColor(Color.BLACK); g.drawLine(X_OFFSET_LEFT, calcY(0), X_OFFSET_LEFT, Y_OFFSET_TOP); // center horizontal line g.setColor(new Color(220, 220, 220)); g.drawLine(X_OFFSET_LEFT, height / 2 + Y_OFFSET_TOP, getWidth(), ...
[ "private", "void", "yAxis", "(", "Graphics", "g", ")", "{", "// y-axis", "g", ".", "setColor", "(", "Color", ".", "BLACK", ")", ";", "g", ".", "drawLine", "(", "X_OFFSET_LEFT", ",", "calcY", "(", "0", ")", ",", "X_OFFSET_LEFT", ",", "Y_OFFSET_TOP", ")"...
Draws the y axis, containing og the axis line, the horizontal helping line and the labels. @param g the Graphics context in which to paint
[ "Draws", "the", "y", "axis", "containing", "og", "the", "axis", "line", "the", "horizontal", "helping", "line", "and", "the", "labels", "." ]
train
https://github.com/Waikato/moa/blob/395982e5100bfe75a3a4d26115462ce2cc74cbb0/moa/src/main/java/moa/gui/visualization/AbstractGraphAxes.java#L153-L186
gturri/aXMLRPC
src/main/java/de/timroes/axmlrpc/XMLUtil.java
XMLUtil.makeXmlTag
public static XmlElement makeXmlTag(String type, String content) { """ Creates an xml tag with a given type and content. @param type The type of the xml tag. What will be filled in the <..>. @param content The content of the tag. @return The xml tag with its content as a string. """ XmlElement xml = new...
java
public static XmlElement makeXmlTag(String type, String content) { XmlElement xml = new XmlElement(type); xml.setContent(content); return xml; }
[ "public", "static", "XmlElement", "makeXmlTag", "(", "String", "type", ",", "String", "content", ")", "{", "XmlElement", "xml", "=", "new", "XmlElement", "(", "type", ")", ";", "xml", ".", "setContent", "(", "content", ")", ";", "return", "xml", ";", "}"...
Creates an xml tag with a given type and content. @param type The type of the xml tag. What will be filled in the <..>. @param content The content of the tag. @return The xml tag with its content as a string.
[ "Creates", "an", "xml", "tag", "with", "a", "given", "type", "and", "content", "." ]
train
https://github.com/gturri/aXMLRPC/blob/8ca6f95f7eb3a28efaef3569d53adddeb32b6bda/src/main/java/de/timroes/axmlrpc/XMLUtil.java#L120-L124
OpenLiberty/open-liberty
dev/com.ibm.ws.jca.cm/src/com/ibm/ejs/j2c/ConnectorProperties.java
ConnectorProperties.findConnectorPropertyString
public String findConnectorPropertyString(String desiredPropertyName, String defaultValue) { """ Given this ConnectorProperties Vector, find the String identified by the input desiredPropertyName. If not found, return the defaultValue. @param desiredPropertyName Name of com.ibm.ejs.j2c.ConnectorProperty entry ...
java
public String findConnectorPropertyString(String desiredPropertyName, String defaultValue) { String retVal = defaultValue; String name = null; ConnectorProperty property = null; Enumeration<Object> e = this.elements(); while (e.hasMoreElements()) { property = (Conn...
[ "public", "String", "findConnectorPropertyString", "(", "String", "desiredPropertyName", ",", "String", "defaultValue", ")", "{", "String", "retVal", "=", "defaultValue", ";", "String", "name", "=", "null", ";", "ConnectorProperty", "property", "=", "null", ";", "...
Given this ConnectorProperties Vector, find the String identified by the input desiredPropertyName. If not found, return the defaultValue. @param desiredPropertyName Name of com.ibm.ejs.j2c.ConnectorProperty entry to look for. @param defaultValue value to return if the desiredPropertyName is not found, or its value is...
[ "Given", "this", "ConnectorProperties", "Vector", "find", "the", "String", "identified", "by", "the", "input", "desiredPropertyName", ".", "If", "not", "found", "return", "the", "defaultValue", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.jca.cm/src/com/ibm/ejs/j2c/ConnectorProperties.java#L77-L97
jamesagnew/hapi-fhir
hapi-fhir-structures-r4/src/main/java/org/hl7/fhir/r4/utils/client/ResourceAddress.java
ResourceAddress.parseCreateLocation
public static ResourceAddress.ResourceVersionedIdentifier parseCreateLocation(String locationResponseHeader) { """ For now, assume this type of location header structure. Generalize later: http://hl7connect.healthintersections.com.au/svc/fhir/318/_history/1 @param serviceBase @param locationHeader """ ...
java
public static ResourceAddress.ResourceVersionedIdentifier parseCreateLocation(String locationResponseHeader) { Pattern pattern = Pattern.compile(REGEX_ID_WITH_HISTORY); Matcher matcher = pattern.matcher(locationResponseHeader); ResourceVersionedIdentifier parsedHeader = null; if(matcher.matches()){ Stri...
[ "public", "static", "ResourceAddress", ".", "ResourceVersionedIdentifier", "parseCreateLocation", "(", "String", "locationResponseHeader", ")", "{", "Pattern", "pattern", "=", "Pattern", ".", "compile", "(", "REGEX_ID_WITH_HISTORY", ")", ";", "Matcher", "matcher", "=", ...
For now, assume this type of location header structure. Generalize later: http://hl7connect.healthintersections.com.au/svc/fhir/318/_history/1 @param serviceBase @param locationHeader
[ "For", "now", "assume", "this", "type", "of", "location", "header", "structure", ".", "Generalize", "later", ":", "http", ":", "//", "hl7connect", ".", "healthintersections", ".", "com", ".", "au", "/", "svc", "/", "fhir", "/", "318", "/", "_history", "/...
train
https://github.com/jamesagnew/hapi-fhir/blob/150a84d52fe691b7f48fcb28247c4bddb7aec352/hapi-fhir-structures-r4/src/main/java/org/hl7/fhir/r4/utils/client/ResourceAddress.java#L232-L244
aehrc/snorocket
snorocket-core/src/main/java/au/csiro/snorocket/core/axioms/GCI.java
GCI.rule5
boolean rule5(final IFactory factory, final Inclusion[] gcis) { """ C' &#8849; D' &rarr; {C' &#8849; A, A &#8849; D'} @param gcis @return """ boolean result = false; if (!(lhs instanceof Concept) && !(rhs instanceof Concept)) { result = true; Concept a = getA(f...
java
boolean rule5(final IFactory factory, final Inclusion[] gcis) { boolean result = false; if (!(lhs instanceof Concept) && !(rhs instanceof Concept)) { result = true; Concept a = getA(factory, lhs); gcis[0] = new GCI(lhs, a); gcis[1] = new GCI(a, rhs...
[ "boolean", "rule5", "(", "final", "IFactory", "factory", ",", "final", "Inclusion", "[", "]", "gcis", ")", "{", "boolean", "result", "=", "false", ";", "if", "(", "!", "(", "lhs", "instanceof", "Concept", ")", "&&", "!", "(", "rhs", "instanceof", "Conc...
C' &#8849; D' &rarr; {C' &#8849; A, A &#8849; D'} @param gcis @return
[ "C", "&#8849", ";", "D", "&rarr", ";", "{", "C", "&#8849", ";", "A", "A", "&#8849", ";", "D", "}" ]
train
https://github.com/aehrc/snorocket/blob/e33c1e216f8a66d6502e3a14e80876811feedd8b/snorocket-core/src/main/java/au/csiro/snorocket/core/axioms/GCI.java#L228-L239
eclipse/xtext-extras
org.eclipse.xtext.xbase/src/org/eclipse/xtext/xbase/typesystem/util/MultimapJoiner.java
MultimapJoiner.appendTo
public StringBuilder appendTo(StringBuilder builder, Iterable<? extends Entry<?, ? extends Collection<?>>> entries) { """ Appends the string representation of each entry in {@code entries}, using the previously configured separator and key-value separator, to {@code builder}. Identical to {@link #appendTo(Appenda...
java
public StringBuilder appendTo(StringBuilder builder, Iterable<? extends Entry<?, ? extends Collection<?>>> entries) { try { appendTo((Appendable) builder, entries); } catch (IOException impossible) { throw new AssertionError(impossible); } return builder; }
[ "public", "StringBuilder", "appendTo", "(", "StringBuilder", "builder", ",", "Iterable", "<", "?", "extends", "Entry", "<", "?", ",", "?", "extends", "Collection", "<", "?", ">", ">", ">", "entries", ")", "{", "try", "{", "appendTo", "(", "(", "Appendabl...
Appends the string representation of each entry in {@code entries}, using the previously configured separator and key-value separator, to {@code builder}. Identical to {@link #appendTo(Appendable, Iterable)}, except that it does not throw {@link IOException}.
[ "Appends", "the", "string", "representation", "of", "each", "entry", "in", "{" ]
train
https://github.com/eclipse/xtext-extras/blob/451359541295323a29f5855e633f770cec02069a/org.eclipse.xtext.xbase/src/org/eclipse/xtext/xbase/typesystem/util/MultimapJoiner.java#L112-L119
xerial/snappy-java
src/main/java/org/xerial/snappy/Snappy.java
Snappy.arrayCopy
public static void arrayCopy(Object src, int offset, int byteLength, Object dest, int dest_offset) throws IOException { """ Copy bytes from source to destination @param src pointer to the source array @param offset byte offset in the source array @param byteLength the number of bytes to copy @par...
java
public static void arrayCopy(Object src, int offset, int byteLength, Object dest, int dest_offset) throws IOException { impl.arrayCopy(src, offset, byteLength, dest, dest_offset); }
[ "public", "static", "void", "arrayCopy", "(", "Object", "src", ",", "int", "offset", ",", "int", "byteLength", ",", "Object", "dest", ",", "int", "dest_offset", ")", "throws", "IOException", "{", "impl", ".", "arrayCopy", "(", "src", ",", "offset", ",", ...
Copy bytes from source to destination @param src pointer to the source array @param offset byte offset in the source array @param byteLength the number of bytes to copy @param dest pointer to the destination array @param dest_offset byte offset in the destination array @throws IOException
[ "Copy", "bytes", "from", "source", "to", "destination" ]
train
https://github.com/xerial/snappy-java/blob/9df6ed7bbce88186c82f2e7cdcb7b974421b3340/src/main/java/org/xerial/snappy/Snappy.java#L82-L86
rhuss/jolokia
agent/core/src/main/java/org/jolokia/util/JmxUtil.java
JmxUtil.removeMBeanRegistrationListener
public static void removeMBeanRegistrationListener(MBeanServerConnection pServer,NotificationListener pListener) { """ Remove a notification listener from the given MBeanServer while listening for MBeanServer registration events @param pServer server from where to unregister @param pListener listener to unregist...
java
public static void removeMBeanRegistrationListener(MBeanServerConnection pServer,NotificationListener pListener) { try { pServer.removeNotificationListener(JmxUtil.getMBeanServerDelegateName(), pListener); } catch (ListenerNotFoundException e) { // We silently ignore listeners no...
[ "public", "static", "void", "removeMBeanRegistrationListener", "(", "MBeanServerConnection", "pServer", ",", "NotificationListener", "pListener", ")", "{", "try", "{", "pServer", ".", "removeNotificationListener", "(", "JmxUtil", ".", "getMBeanServerDelegateName", "(", ")...
Remove a notification listener from the given MBeanServer while listening for MBeanServer registration events @param pServer server from where to unregister @param pListener listener to unregister
[ "Remove", "a", "notification", "listener", "from", "the", "given", "MBeanServer", "while", "listening", "for", "MBeanServer", "registration", "events" ]
train
https://github.com/rhuss/jolokia/blob/dc95e7bef859b1829776c5a84c8f7738f5d7d9c3/agent/core/src/main/java/org/jolokia/util/JmxUtil.java#L62-L73
tommyettinger/RegExodus
src/main/java/regexodus/Matcher.java
Matcher.setTarget
public void setTarget(CharSequence text, int start, int len) { """ Supplies a text to search in/match with, as a part of String. Resets current search position to zero. @param text - a data source @param start - where the target starts @param len - how long is the target @see Matcher#setTarget(regexodus....
java
public void setTarget(CharSequence text, int start, int len) { char[] mychars = data; if (mychars == null || shared || mychars.length < len) { data = mychars = new char[(int) (1.7f * len)]; shared = false; } for (int i = start, p = 0; i < len; i++, p++) { ...
[ "public", "void", "setTarget", "(", "CharSequence", "text", ",", "int", "start", ",", "int", "len", ")", "{", "char", "[", "]", "mychars", "=", "data", ";", "if", "(", "mychars", "==", "null", "||", "shared", "||", "mychars", ".", "length", "<", "len...
Supplies a text to search in/match with, as a part of String. Resets current search position to zero. @param text - a data source @param start - where the target starts @param len - how long is the target @see Matcher#setTarget(regexodus.Matcher, int) @see Matcher#setTarget(java.lang.CharSequence) @see Matcher#setT...
[ "Supplies", "a", "text", "to", "search", "in", "/", "match", "with", "as", "a", "part", "of", "String", ".", "Resets", "current", "search", "position", "to", "zero", "." ]
train
https://github.com/tommyettinger/RegExodus/blob/d4af9bb7c132c5f9d29f45b76121f93b2f89de16/src/main/java/regexodus/Matcher.java#L257-L275
liferay/com-liferay-commerce
commerce-user-segment-service/src/main/java/com/liferay/commerce/user/segment/service/persistence/impl/CommerceUserSegmentCriterionPersistenceImpl.java
CommerceUserSegmentCriterionPersistenceImpl.findAll
@Override public List<CommerceUserSegmentCriterion> findAll(int start, int end) { """ Returns a range of all the commerce user segment criterions. <p> Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are...
java
@Override public List<CommerceUserSegmentCriterion> findAll(int start, int end) { return findAll(start, end, null); }
[ "@", "Override", "public", "List", "<", "CommerceUserSegmentCriterion", ">", "findAll", "(", "int", "start", ",", "int", "end", ")", "{", "return", "findAll", "(", "start", ",", "end", ",", "null", ")", ";", "}" ]
Returns a range of all the commerce user segment criterions. <p> Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting...
[ "Returns", "a", "range", "of", "all", "the", "commerce", "user", "segment", "criterions", "." ]
train
https://github.com/liferay/com-liferay-commerce/blob/9e54362d7f59531fc684016ba49ee7cdc3a2f22b/commerce-user-segment-service/src/main/java/com/liferay/commerce/user/segment/service/persistence/impl/CommerceUserSegmentCriterionPersistenceImpl.java#L1185-L1188
haraldk/TwelveMonkeys
common/common-lang/src/main/java/com/twelvemonkeys/util/IgnoreCaseMap.java
IgnoreCaseMap.put
public V put(String pKey, V pValue) { """ Maps the specified key to the specified value in this map. Note: If the key used is a string, the key will not be case-sensitive. @param pKey the map key. @param pValue the value. @return the previous value of the specified key in this map, or null if it did not h...
java
public V put(String pKey, V pValue) { String key = (String) toUpper(pKey); return unwrap(entries.put(key, new BasicEntry<String, V>(key, pValue))); }
[ "public", "V", "put", "(", "String", "pKey", ",", "V", "pValue", ")", "{", "String", "key", "=", "(", "String", ")", "toUpper", "(", "pKey", ")", ";", "return", "unwrap", "(", "entries", ".", "put", "(", "key", ",", "new", "BasicEntry", "<", "Strin...
Maps the specified key to the specified value in this map. Note: If the key used is a string, the key will not be case-sensitive. @param pKey the map key. @param pValue the value. @return the previous value of the specified key in this map, or null if it did not have one.
[ "Maps", "the", "specified", "key", "to", "the", "specified", "value", "in", "this", "map", ".", "Note", ":", "If", "the", "key", "used", "is", "a", "string", "the", "key", "will", "not", "be", "case", "-", "sensitive", "." ]
train
https://github.com/haraldk/TwelveMonkeys/blob/7fad4d5cd8cb3a6728c7fd3f28a7b84d8ce0101d/common/common-lang/src/main/java/com/twelvemonkeys/util/IgnoreCaseMap.java#L110-L113
Azure/azure-sdk-for-java
network/resource-manager/v2018_08_01/src/main/java/com/microsoft/azure/management/network/v2018_08_01/implementation/VpnSitesInner.java
VpnSitesInner.createOrUpdateAsync
public Observable<VpnSiteInner> createOrUpdateAsync(String resourceGroupName, String vpnSiteName, VpnSiteInner vpnSiteParameters) { """ Creates a VpnSite resource if it doesn't exist else updates the existing VpnSite. @param resourceGroupName The resource group name of the VpnSite. @param vpnSiteName The name ...
java
public Observable<VpnSiteInner> createOrUpdateAsync(String resourceGroupName, String vpnSiteName, VpnSiteInner vpnSiteParameters) { return createOrUpdateWithServiceResponseAsync(resourceGroupName, vpnSiteName, vpnSiteParameters).map(new Func1<ServiceResponse<VpnSiteInner>, VpnSiteInner>() { @Overrid...
[ "public", "Observable", "<", "VpnSiteInner", ">", "createOrUpdateAsync", "(", "String", "resourceGroupName", ",", "String", "vpnSiteName", ",", "VpnSiteInner", "vpnSiteParameters", ")", "{", "return", "createOrUpdateWithServiceResponseAsync", "(", "resourceGroupName", ",", ...
Creates a VpnSite resource if it doesn't exist else updates the existing VpnSite. @param resourceGroupName The resource group name of the VpnSite. @param vpnSiteName The name of the VpnSite being created or updated. @param vpnSiteParameters Parameters supplied to create or update VpnSite. @throws IllegalArgumentExcept...
[ "Creates", "a", "VpnSite", "resource", "if", "it", "doesn", "t", "exist", "else", "updates", "the", "existing", "VpnSite", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/network/resource-manager/v2018_08_01/src/main/java/com/microsoft/azure/management/network/v2018_08_01/implementation/VpnSitesInner.java#L238-L245
BranchMetrics/android-branch-deep-linking
Branch-SDK/src/io/branch/referral/ServerRequest.java
ServerRequest.addGetParam
protected void addGetParam(String paramKey, String paramValue) { """ Adds a param and its value to the get request @param paramKey A {@link String} value for the get param key @param paramValue A {@link String} value for the get param value """ try { params_.put(paramKey, paramValue);...
java
protected void addGetParam(String paramKey, String paramValue) { try { params_.put(paramKey, paramValue); } catch (JSONException ignore) { } }
[ "protected", "void", "addGetParam", "(", "String", "paramKey", ",", "String", "paramValue", ")", "{", "try", "{", "params_", ".", "put", "(", "paramKey", ",", "paramValue", ")", ";", "}", "catch", "(", "JSONException", "ignore", ")", "{", "}", "}" ]
Adds a param and its value to the get request @param paramKey A {@link String} value for the get param key @param paramValue A {@link String} value for the get param value
[ "Adds", "a", "param", "and", "its", "value", "to", "the", "get", "request" ]
train
https://github.com/BranchMetrics/android-branch-deep-linking/blob/e3bee2ccfcbf6d4bf1a5815b5b86666e4ff8f848/Branch-SDK/src/io/branch/referral/ServerRequest.java#L266-L271
eiichiro/gig
gig-appengine/src/main/java/org/eiichiro/gig/appengine/KeyConverter.java
KeyConverter.convertToType
@SuppressWarnings("rawtypes") @Override protected Object convertToType(Class type, Object value) throws Throwable { """ Converts the specified value to {@code com.google.appengine.api.datastore.Key}. @see org.apache.commons.beanutils.converters.AbstractConverter#convertToType(java.lang.Class, java.lang.Objec...
java
@SuppressWarnings("rawtypes") @Override protected Object convertToType(Class type, Object value) throws Throwable { return KeyFactory.stringToKey(value.toString()); }
[ "@", "SuppressWarnings", "(", "\"rawtypes\"", ")", "@", "Override", "protected", "Object", "convertToType", "(", "Class", "type", ",", "Object", "value", ")", "throws", "Throwable", "{", "return", "KeyFactory", ".", "stringToKey", "(", "value", ".", "toString", ...
Converts the specified value to {@code com.google.appengine.api.datastore.Key}. @see org.apache.commons.beanutils.converters.AbstractConverter#convertToType(java.lang.Class, java.lang.Object)
[ "Converts", "the", "specified", "value", "to", "{", "@code", "com", ".", "google", ".", "appengine", ".", "api", ".", "datastore", ".", "Key", "}", "." ]
train
https://github.com/eiichiro/gig/blob/21181fb36a17d2154f989e5e8c6edbb39fc81900/gig-appengine/src/main/java/org/eiichiro/gig/appengine/KeyConverter.java#L39-L43
oehf/ipf-oht-atna
auditor/src/main/java/org/openhealthtools/ihe/atna/auditor/PIXAuditor.java
PIXAuditor.auditPatientRecordEvent
protected void auditPatientRecordEvent(boolean systemIsSource, IHETransactionEventTypeCodes transaction, RFC3881EventOutcomeCodes eventOutcome, RFC3881EventActionCodes eventActionCode, String sourceFacility, String sourceApp, String sourceAltUserId, String sourceNetworkId, String destinationFacility, String de...
java
protected void auditPatientRecordEvent(boolean systemIsSource, IHETransactionEventTypeCodes transaction, RFC3881EventOutcomeCodes eventOutcome, RFC3881EventActionCodes eventActionCode, String sourceFacility, String sourceApp, String sourceAltUserId, String sourceNetworkId, String destinationFacility, String de...
[ "protected", "void", "auditPatientRecordEvent", "(", "boolean", "systemIsSource", ",", "IHETransactionEventTypeCodes", "transaction", ",", "RFC3881EventOutcomeCodes", "eventOutcome", ",", "RFC3881EventActionCodes", "eventActionCode", ",", "String", "sourceFacility", ",", "Strin...
Audit a PATIENT RECORD event for Patient Identity Source transactions. Variable on the event action (Create, Update, Delete) audit patient identity feeds (create, update, merge [update/delete]) for both PIX Source and PIX Managers actors. @param systemIsSource Whether the system sending the message is the source acti...
[ "Audit", "a", "PATIENT", "RECORD", "event", "for", "Patient", "Identity", "Source", "transactions", ".", "Variable", "on", "the", "event", "action", "(", "Create", "Update", "Delete", ")", "audit", "patient", "identity", "feeds", "(", "create", "update", "merg...
train
https://github.com/oehf/ipf-oht-atna/blob/25ed1e926825169c94923a2c89a4618f60478ae8/auditor/src/main/java/org/openhealthtools/ihe/atna/auditor/PIXAuditor.java#L120-L149
Azure/azure-sdk-for-java
edgegateway/resource-manager/v2019_03_01/src/main/java/com/microsoft/azure/management/edgegateway/v2019_03_01/implementation/JobsInner.java
JobsInner.getAsync
public Observable<JobInner> getAsync(String deviceName, String name, String resourceGroupName) { """ Gets the details of a specified job on a data box edge/gateway device. @param deviceName The device name. @param name The job name. @param resourceGroupName The resource group name. @throws IllegalArgumentExc...
java
public Observable<JobInner> getAsync(String deviceName, String name, String resourceGroupName) { return getWithServiceResponseAsync(deviceName, name, resourceGroupName).map(new Func1<ServiceResponse<JobInner>, JobInner>() { @Override public JobInner call(ServiceResponse<JobInner> respons...
[ "public", "Observable", "<", "JobInner", ">", "getAsync", "(", "String", "deviceName", ",", "String", "name", ",", "String", "resourceGroupName", ")", "{", "return", "getWithServiceResponseAsync", "(", "deviceName", ",", "name", ",", "resourceGroupName", ")", ".",...
Gets the details of a specified job on a data box edge/gateway device. @param deviceName The device name. @param name The job name. @param resourceGroupName The resource group name. @throws IllegalArgumentException thrown if parameters fail the validation @return the observable to the JobInner object
[ "Gets", "the", "details", "of", "a", "specified", "job", "on", "a", "data", "box", "edge", "/", "gateway", "device", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/edgegateway/resource-manager/v2019_03_01/src/main/java/com/microsoft/azure/management/edgegateway/v2019_03_01/implementation/JobsInner.java#L98-L105
geomajas/geomajas-project-server
impl/src/main/java/org/geomajas/internal/service/ConfigurationServiceImpl.java
ConfigurationServiceImpl.getBeanOrNull
private <T> T getBeanOrNull(String name, Class<T> requiredType) { """ Get a bean from the application context. Returns null if the bean does not exist. @param name name of bean @param requiredType type of bean @return the bean or null """ if (name == null || !applicationContext.containsBean(name)) { re...
java
private <T> T getBeanOrNull(String name, Class<T> requiredType) { if (name == null || !applicationContext.containsBean(name)) { return null; } else { try { return applicationContext.getBean(name, requiredType); } catch (BeansException be) { log.error("Error during getBeanOrNull, not rethrown, " + b...
[ "private", "<", "T", ">", "T", "getBeanOrNull", "(", "String", "name", ",", "Class", "<", "T", ">", "requiredType", ")", "{", "if", "(", "name", "==", "null", "||", "!", "applicationContext", ".", "containsBean", "(", "name", ")", ")", "{", "return", ...
Get a bean from the application context. Returns null if the bean does not exist. @param name name of bean @param requiredType type of bean @return the bean or null
[ "Get", "a", "bean", "from", "the", "application", "context", ".", "Returns", "null", "if", "the", "bean", "does", "not", "exist", "." ]
train
https://github.com/geomajas/geomajas-project-server/blob/904b7d7deed1350d28955589098dd1e0a786d76e/impl/src/main/java/org/geomajas/internal/service/ConfigurationServiceImpl.java#L105-L116
playn/playn
html/src/playn/super/java/nio/ByteBuffer.java
ByteBuffer.putShort
public final ByteBuffer putShort(int baseOffset, short value) { """ Writes the given short to the specified index of this buffer. <p> The short is converted to bytes using the current byte order. The position is not changed. </p> @param index the index, must not be negative and equal or less than {@code limit...
java
public final ByteBuffer putShort(int baseOffset, short value) { if (order == ByteOrder.BIG_ENDIAN) { byteArray.set(baseOffset, (byte)((value >> 8) & 0xFF)); byteArray.set(baseOffset + 1, (byte)(value & 0xFF)); } else { byteArray.set(baseOffset + 1, (byte)((value >> 8) & 0xFF));...
[ "public", "final", "ByteBuffer", "putShort", "(", "int", "baseOffset", ",", "short", "value", ")", "{", "if", "(", "order", "==", "ByteOrder", ".", "BIG_ENDIAN", ")", "{", "byteArray", ".", "set", "(", "baseOffset", ",", "(", "byte", ")", "(", "(", "va...
Writes the given short to the specified index of this buffer. <p> The short is converted to bytes using the current byte order. The position is not changed. </p> @param index the index, must not be negative and equal or less than {@code limit - 2}. @param value the short to write. @return this buffer. @exception Index...
[ "Writes", "the", "given", "short", "to", "the", "specified", "index", "of", "this", "buffer", ".", "<p", ">", "The", "short", "is", "converted", "to", "bytes", "using", "the", "current", "byte", "order", ".", "The", "position", "is", "not", "changed", "....
train
https://github.com/playn/playn/blob/7e7a9d048ba6afe550dc0cdeaca3e1d5b0d01c66/html/src/playn/super/java/nio/ByteBuffer.java#L891-L900
UrielCh/ovh-java-sdk
ovh-java-sdk-caasregistry/src/main/java/net/minidev/ovh/api/ApiOvhCaasregistry.java
ApiOvhCaasregistry.serviceName_namespaces_namespaceId_images_imageId_tags_tagId_GET
public OvhTag serviceName_namespaces_namespaceId_images_imageId_tags_tagId_GET(String serviceName, String namespaceId, String imageId, String tagId) throws IOException { """ Inspect image tag REST: GET /caas/registry/{serviceName}/namespaces/{namespaceId}/images/{imageId}/tags/{tagId} @param imageId [required]...
java
public OvhTag serviceName_namespaces_namespaceId_images_imageId_tags_tagId_GET(String serviceName, String namespaceId, String imageId, String tagId) throws IOException { String qPath = "/caas/registry/{serviceName}/namespaces/{namespaceId}/images/{imageId}/tags/{tagId}"; StringBuilder sb = path(qPath, serviceName, ...
[ "public", "OvhTag", "serviceName_namespaces_namespaceId_images_imageId_tags_tagId_GET", "(", "String", "serviceName", ",", "String", "namespaceId", ",", "String", "imageId", ",", "String", "tagId", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/caas/regist...
Inspect image tag REST: GET /caas/registry/{serviceName}/namespaces/{namespaceId}/images/{imageId}/tags/{tagId} @param imageId [required] Image id @param namespaceId [required] Namespace id @param serviceName [required] Service name @param tagId [required] Tag id API beta
[ "Inspect", "image", "tag" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-caasregistry/src/main/java/net/minidev/ovh/api/ApiOvhCaasregistry.java#L235-L240
landawn/AbacusUtil
src/com/landawn/abacus/util/N.java
N.copyOfRange
public static <T> T[] copyOfRange(final T[] original, int from, final int to, final int step, final Class<? extends T[]> newType) { """ Copy all the elements in <code>original</code>, through <code>to</code>-<code>from</code>, by <code>step</code>. @param original @param from @param to @param step @return ...
java
public static <T> T[] copyOfRange(final T[] original, int from, final int to, final int step, final Class<? extends T[]> newType) { N.checkFromToIndex(from < to ? from : (to == -1 ? 0 : to), from < to ? to : from, original.length); if (step == 0) { throw new IllegalArgumentException("Th...
[ "public", "static", "<", "T", ">", "T", "[", "]", "copyOfRange", "(", "final", "T", "[", "]", "original", ",", "int", "from", ",", "final", "int", "to", ",", "final", "int", "step", ",", "final", "Class", "<", "?", "extends", "T", "[", "]", ">", ...
Copy all the elements in <code>original</code>, through <code>to</code>-<code>from</code>, by <code>step</code>. @param original @param from @param to @param step @return @see N#copyOfRange(int[], int, int, int)
[ "Copy", "all", "the", "elements", "in", "<code", ">", "original<", "/", "code", ">", "through", "<code", ">", "to<", "/", "code", ">", "-", "<code", ">", "from<", "/", "code", ">", "by", "<code", ">", "step<", "/", "code", ">", "." ]
train
https://github.com/landawn/AbacusUtil/blob/544b7720175d15e9329f83dd22a8cc5fa4515e12/src/com/landawn/abacus/util/N.java#L10971-L10995
netscaler/sdx_nitro
src/main/java/com/citrix/sdx/nitro/resource/config/ns/ns_aaasession.java
ns_aaasession.get_nitro_bulk_response
protected base_resource[] get_nitro_bulk_response(nitro_service service, String response) throws Exception { """ <pre> Converts API response of bulk operation into object and returns the object array in case of get request. </pre> """ ns_aaasession_responses result = (ns_aaasession_responses) service.get_...
java
protected base_resource[] get_nitro_bulk_response(nitro_service service, String response) throws Exception { ns_aaasession_responses result = (ns_aaasession_responses) service.get_payload_formatter().string_to_resource(ns_aaasession_responses.class, response); if(result.errorcode != 0) { if (result.error...
[ "protected", "base_resource", "[", "]", "get_nitro_bulk_response", "(", "nitro_service", "service", ",", "String", "response", ")", "throws", "Exception", "{", "ns_aaasession_responses", "result", "=", "(", "ns_aaasession_responses", ")", "service", ".", "get_payload_fo...
<pre> Converts API response of bulk operation into object and returns the object array in case of get request. </pre>
[ "<pre", ">", "Converts", "API", "response", "of", "bulk", "operation", "into", "object", "and", "returns", "the", "object", "array", "in", "case", "of", "get", "request", ".", "<", "/", "pre", ">" ]
train
https://github.com/netscaler/sdx_nitro/blob/c840919f1a8f7c0a5634c0f23d34fa14d1765ff1/src/main/java/com/citrix/sdx/nitro/resource/config/ns/ns_aaasession.java#L236-L253
googlegenomics/utils-java
src/main/java/com/google/cloud/genomics/utils/grpc/VariantStreamIterator.java
VariantStreamIterator.enforceShardBoundary
public static VariantStreamIterator enforceShardBoundary(ManagedChannel channel, StreamVariantsRequest request, Requirement shardBoundary, String fields) { """ Create a stream iterator that can enforce shard boundary semantics. @param channel The ManagedChannel. @param request The request for the shard o...
java
public static VariantStreamIterator enforceShardBoundary(ManagedChannel channel, StreamVariantsRequest request, Requirement shardBoundary, String fields) { Predicate<Variant> shardPredicate; if(ShardBoundary.Requirement.STRICT == shardBoundary) { shardPredicate = ShardBoundary.getStrictVariantPredic...
[ "public", "static", "VariantStreamIterator", "enforceShardBoundary", "(", "ManagedChannel", "channel", ",", "StreamVariantsRequest", "request", ",", "Requirement", "shardBoundary", ",", "String", "fields", ")", "{", "Predicate", "<", "Variant", ">", "shardPredicate", ";...
Create a stream iterator that can enforce shard boundary semantics. @param channel The ManagedChannel. @param request The request for the shard of data. @param shardBoundary The shard boundary semantics to enforce. @param fields Used to check whether the specified fields would meet the minimum required fields for the ...
[ "Create", "a", "stream", "iterator", "that", "can", "enforce", "shard", "boundary", "semantics", "." ]
train
https://github.com/googlegenomics/utils-java/blob/7205d5b4e4f61fc6b93acb4bdd76b93df5b5f612/src/main/java/com/google/cloud/genomics/utils/grpc/VariantStreamIterator.java#L70-L80
cdk/cdk
base/standard/src/main/java/org/openscience/cdk/graph/EdmondsMaximumMatching.java
EdmondsMaximumMatching.buildPath
private int buildPath(int[] path, int i, int start, int goal) { """ Builds the path backwards from the specified 'start' vertex until the 'goal'. If the path reaches a blossom then the path through the blossom is lifted to the original graph. @param path path storage @param i offset (in path) @param st...
java
private int buildPath(int[] path, int i, int start, int goal) { while (true) { // lift the path through the contracted blossom while (odd[start] != NIL) { Tuple bridge = bridges.get(start); // add to the path from the bridge down to where 'start' ...
[ "private", "int", "buildPath", "(", "int", "[", "]", "path", ",", "int", "i", ",", "int", "start", ",", "int", "goal", ")", "{", "while", "(", "true", ")", "{", "// lift the path through the contracted blossom", "while", "(", "odd", "[", "start", "]", "!...
Builds the path backwards from the specified 'start' vertex until the 'goal'. If the path reaches a blossom then the path through the blossom is lifted to the original graph. @param path path storage @param i offset (in path) @param start start vertex @param goal end vertex @return the number of items set to the...
[ "Builds", "the", "path", "backwards", "from", "the", "specified", "start", "vertex", "until", "the", "goal", ".", "If", "the", "path", "reaches", "a", "blossom", "then", "the", "path", "through", "the", "blossom", "is", "lifted", "to", "the", "original", "...
train
https://github.com/cdk/cdk/blob/c3d0f16502bf08df50365fee392e11d7c9856657/base/standard/src/main/java/org/openscience/cdk/graph/EdmondsMaximumMatching.java#L333-L363
mgormley/prim
src/main/java_generated/edu/jhu/prim/vector/IntDoubleDenseVector.java
IntDoubleDenseVector.add
public void add(IntDoubleVector other) { """ Updates this vector to be the entrywise sum of this vector with the other. """ if (other instanceof IntDoubleUnsortedVector) { IntDoubleUnsortedVector vec = (IntDoubleUnsortedVector) other; for (int i=0; i<vec.top; i++) { ...
java
public void add(IntDoubleVector other) { if (other instanceof IntDoubleUnsortedVector) { IntDoubleUnsortedVector vec = (IntDoubleUnsortedVector) other; for (int i=0; i<vec.top; i++) { this.add(vec.idx[i], vec.vals[i]); } } else { // TODO: ...
[ "public", "void", "add", "(", "IntDoubleVector", "other", ")", "{", "if", "(", "other", "instanceof", "IntDoubleUnsortedVector", ")", "{", "IntDoubleUnsortedVector", "vec", "=", "(", "IntDoubleUnsortedVector", ")", "other", ";", "for", "(", "int", "i", "=", "0...
Updates this vector to be the entrywise sum of this vector with the other.
[ "Updates", "this", "vector", "to", "be", "the", "entrywise", "sum", "of", "this", "vector", "with", "the", "other", "." ]
train
https://github.com/mgormley/prim/blob/5dce5e1ae94a9ae558a6262fc246e1a24f56686c/src/main/java_generated/edu/jhu/prim/vector/IntDoubleDenseVector.java#L143-L153
kefirfromperm/kefirbb
src/org/kefirsf/bb/DomConfigurationFactory.java
DomConfigurationFactory.parseFix
private Template parseFix(Document dc, String tagname) { """ Parse prefix or suffix. @param dc DOM-document. @param tagname tag name. @return template. """ Template fix; NodeList prefixElementList = dc.getElementsByTagNameNS(SCHEMA_LOCATION, tagname); if (prefixElementList.get...
java
private Template parseFix(Document dc, String tagname) { Template fix; NodeList prefixElementList = dc.getElementsByTagNameNS(SCHEMA_LOCATION, tagname); if (prefixElementList.getLength() > 0) { fix = parseTemplate(prefixElementList.item(0)); } else { fix = new Tem...
[ "private", "Template", "parseFix", "(", "Document", "dc", ",", "String", "tagname", ")", "{", "Template", "fix", ";", "NodeList", "prefixElementList", "=", "dc", ".", "getElementsByTagNameNS", "(", "SCHEMA_LOCATION", ",", "tagname", ")", ";", "if", "(", "prefi...
Parse prefix or suffix. @param dc DOM-document. @param tagname tag name. @return template.
[ "Parse", "prefix", "or", "suffix", "." ]
train
https://github.com/kefirfromperm/kefirbb/blob/8c36fc3d3dc27459b0cdc179b87582df30420856/src/org/kefirsf/bb/DomConfigurationFactory.java#L194-L203
google/error-prone-javac
src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java
HtmlTree.LINK
public static HtmlTree LINK(String rel, String type, String href, String title) { """ Generates a LINK tag with the rel, type, href and title attributes. @param rel relevance of the link @param type type of link @param href the path for the link @param title title for the link @return an HtmlTree object for...
java
public static HtmlTree LINK(String rel, String type, String href, String title) { HtmlTree htmltree = new HtmlTree(HtmlTag.LINK); htmltree.addAttr(HtmlAttr.REL, nullCheck(rel)); htmltree.addAttr(HtmlAttr.TYPE, nullCheck(type)); htmltree.addAttr(HtmlAttr.HREF, nullCheck(href)); ht...
[ "public", "static", "HtmlTree", "LINK", "(", "String", "rel", ",", "String", "type", ",", "String", "href", ",", "String", "title", ")", "{", "HtmlTree", "htmltree", "=", "new", "HtmlTree", "(", "HtmlTag", ".", "LINK", ")", ";", "htmltree", ".", "addAttr...
Generates a LINK tag with the rel, type, href and title attributes. @param rel relevance of the link @param type type of link @param href the path for the link @param title title for the link @return an HtmlTree object for the LINK tag
[ "Generates", "a", "LINK", "tag", "with", "the", "rel", "type", "href", "and", "title", "attributes", "." ]
train
https://github.com/google/error-prone-javac/blob/a53d069bbdb2c60232ed3811c19b65e41c3e60e0/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java#L521-L528
OpenLiberty/open-liberty
dev/com.ibm.ws.transport.http/src/com/ibm/ws/http/channel/internal/HttpChannelConfig.java
HttpChannelConfig.parseOutgoingVersion
private void parseOutgoingVersion(Map<Object, Object> props) { """ Check the input configuration for the default outgoing HTTP version setting. @param props """ String value = getProp(props, HttpConfigConstants.PROPNAME_OUTGOING_VERSION); if ("1.0".equals(value)) { this.outgoing...
java
private void parseOutgoingVersion(Map<Object, Object> props) { String value = getProp(props, HttpConfigConstants.PROPNAME_OUTGOING_VERSION); if ("1.0".equals(value)) { this.outgoingHttpVersion = VersionValues.V10; if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {...
[ "private", "void", "parseOutgoingVersion", "(", "Map", "<", "Object", ",", "Object", ">", "props", ")", "{", "String", "value", "=", "getProp", "(", "props", ",", "HttpConfigConstants", ".", "PROPNAME_OUTGOING_VERSION", ")", ";", "if", "(", "\"1.0\"", ".", "...
Check the input configuration for the default outgoing HTTP version setting. @param props
[ "Check", "the", "input", "configuration", "for", "the", "default", "outgoing", "HTTP", "version", "setting", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.transport.http/src/com/ibm/ws/http/channel/internal/HttpChannelConfig.java#L534-L542
Alluxio/alluxio
core/common/src/main/java/alluxio/util/network/NetworkAddressUtils.java
NetworkAddressUtils.getConnectHost
public static String getConnectHost(ServiceType service, AlluxioConfiguration conf) { """ Provides an externally resolvable hostname for client to communicate with the service. If the hostname is not explicitly specified, Alluxio will try to use the bind host. If the bind host is wildcard, Alluxio will automatic...
java
public static String getConnectHost(ServiceType service, AlluxioConfiguration conf) { if (conf.isSet(service.mHostNameKey)) { String connectHost = conf.get(service.mHostNameKey); if (!connectHost.isEmpty() && !connectHost.equals(WILDCARD_ADDRESS)) { return connectHost; } } if (conf...
[ "public", "static", "String", "getConnectHost", "(", "ServiceType", "service", ",", "AlluxioConfiguration", "conf", ")", "{", "if", "(", "conf", ".", "isSet", "(", "service", ".", "mHostNameKey", ")", ")", "{", "String", "connectHost", "=", "conf", ".", "get...
Provides an externally resolvable hostname for client to communicate with the service. If the hostname is not explicitly specified, Alluxio will try to use the bind host. If the bind host is wildcard, Alluxio will automatically determine an appropriate hostname from local machine. The various possibilities shown in the...
[ "Provides", "an", "externally", "resolvable", "hostname", "for", "client", "to", "communicate", "with", "the", "service", ".", "If", "the", "hostname", "is", "not", "explicitly", "specified", "Alluxio", "will", "try", "to", "use", "the", "bind", "host", ".", ...
train
https://github.com/Alluxio/alluxio/blob/af38cf3ab44613355b18217a3a4d961f8fec3a10/core/common/src/main/java/alluxio/util/network/NetworkAddressUtils.java#L284-L298
Azure/azure-sdk-for-java
network/resource-manager/v2018_08_01/src/main/java/com/microsoft/azure/management/network/v2018_08_01/implementation/LoadBalancersInner.java
LoadBalancersInner.createOrUpdateAsync
public Observable<LoadBalancerInner> createOrUpdateAsync(String resourceGroupName, String loadBalancerName, LoadBalancerInner parameters) { """ Creates or updates a load balancer. @param resourceGroupName The name of the resource group. @param loadBalancerName The name of the load balancer. @param parameters ...
java
public Observable<LoadBalancerInner> createOrUpdateAsync(String resourceGroupName, String loadBalancerName, LoadBalancerInner parameters) { return createOrUpdateWithServiceResponseAsync(resourceGroupName, loadBalancerName, parameters).map(new Func1<ServiceResponse<LoadBalancerInner>, LoadBalancerInner>() { ...
[ "public", "Observable", "<", "LoadBalancerInner", ">", "createOrUpdateAsync", "(", "String", "resourceGroupName", ",", "String", "loadBalancerName", ",", "LoadBalancerInner", "parameters", ")", "{", "return", "createOrUpdateWithServiceResponseAsync", "(", "resourceGroupName",...
Creates or updates a load balancer. @param resourceGroupName The name of the resource group. @param loadBalancerName The name of the load balancer. @param parameters Parameters supplied to the create or update load balancer operation. @throws IllegalArgumentException thrown if parameters fail the validation @return th...
[ "Creates", "or", "updates", "a", "load", "balancer", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/network/resource-manager/v2018_08_01/src/main/java/com/microsoft/azure/management/network/v2018_08_01/implementation/LoadBalancersInner.java#L471-L478
Swagger2Markup/swagger2markup
src/main/java/io/github/swagger2markup/internal/utils/InlineSchemaUtils.java
InlineSchemaUtils.createInlineType
public static Type createInlineType(Type type, String name, String uniqueName, List<ObjectType> inlineDefinitions) { """ Returns a RefType to a new inlined type named with {@code name} and {@code uniqueName}.<br> The returned RefType point to the new inlined type which is added to the {@code inlineDefinitions} co...
java
public static Type createInlineType(Type type, String name, String uniqueName, List<ObjectType> inlineDefinitions) { if (type instanceof ObjectType) { return createInlineObjectType(type, name, uniqueName, inlineDefinitions); } else if (type instanceof ArrayType) { ArrayType array...
[ "public", "static", "Type", "createInlineType", "(", "Type", "type", ",", "String", "name", ",", "String", "uniqueName", ",", "List", "<", "ObjectType", ">", "inlineDefinitions", ")", "{", "if", "(", "type", "instanceof", "ObjectType", ")", "{", "return", "c...
Returns a RefType to a new inlined type named with {@code name} and {@code uniqueName}.<br> The returned RefType point to the new inlined type which is added to the {@code inlineDefinitions} collection.<br> The function is recursive and support collections (ArrayType and MapType).<br> The function is transparent : {@co...
[ "Returns", "a", "RefType", "to", "a", "new", "inlined", "type", "named", "with", "{", "@code", "name", "}", "and", "{", "@code", "uniqueName", "}", ".", "<br", ">", "The", "returned", "RefType", "point", "to", "the", "new", "inlined", "type", "which", ...
train
https://github.com/Swagger2Markup/swagger2markup/blob/da83465f19a2f8a0f1fba873b5762bca8587896b/src/main/java/io/github/swagger2markup/internal/utils/InlineSchemaUtils.java#L38-L55
RestComm/sip-servlets
sip-servlets-examples/facebook-c2c/src/main/java/com/facebook/api/FacebookRestClient.java
FacebookRestClient.photos_upload
public T photos_upload(File photo, String caption) throws FacebookException, IOException { """ Uploads a photo to Facebook. @param photo an image file @param caption a description of the image contents @return a T with the standard Facebook photo information @see <a href="http://wiki.developers.facebook.co...
java
public T photos_upload(File photo, String caption) throws FacebookException, IOException { return photos_upload(photo, caption, /*albumId*/null) ; }
[ "public", "T", "photos_upload", "(", "File", "photo", ",", "String", "caption", ")", "throws", "FacebookException", ",", "IOException", "{", "return", "photos_upload", "(", "photo", ",", "caption", ",", "/*albumId*/", "null", ")", ";", "}" ]
Uploads a photo to Facebook. @param photo an image file @param caption a description of the image contents @return a T with the standard Facebook photo information @see <a href="http://wiki.developers.facebook.com/index.php/Photos.upload"> Developers wiki: Photos.upload</a>
[ "Uploads", "a", "photo", "to", "Facebook", "." ]
train
https://github.com/RestComm/sip-servlets/blob/fd7011d2803ab1d205b140768a760c8c69e0c997/sip-servlets-examples/facebook-c2c/src/main/java/com/facebook/api/FacebookRestClient.java#L1295-L1298
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.getTags
public List<Tag> getTags(UUID projectId, GetTagsOptionalParameter getTagsOptionalParameter) { """ Get the tags for a given project and iteration. @param projectId The project id @param getTagsOptionalParameter the object representing the optional parameters to be set before calling this API @throws IllegalArg...
java
public List<Tag> getTags(UUID projectId, GetTagsOptionalParameter getTagsOptionalParameter) { return getTagsWithServiceResponseAsync(projectId, getTagsOptionalParameter).toBlocking().single().body(); }
[ "public", "List", "<", "Tag", ">", "getTags", "(", "UUID", "projectId", ",", "GetTagsOptionalParameter", "getTagsOptionalParameter", ")", "{", "return", "getTagsWithServiceResponseAsync", "(", "projectId", ",", "getTagsOptionalParameter", ")", ".", "toBlocking", "(", ...
Get the tags for a given project and iteration. @param projectId The project id @param getTagsOptionalParameter the object representing the optional parameters to be set before calling this API @throws IllegalArgumentException thrown if parameters fail the validation @throws CloudException thrown if the request is rej...
[ "Get", "the", "tags", "for", "a", "given", "project", "and", "iteration", "." ]
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#L453-L455
yanzhenjie/Album
album/src/main/java/com/yanzhenjie/album/util/AlbumUtils.java
AlbumUtils.getNowDateTime
@NonNull public static String getNowDateTime(@NonNull String format) { """ Format the current time in the specified format. @return the time string. """ SimpleDateFormat formatter = new SimpleDateFormat(format, Locale.ENGLISH); Date curDate = new Date(System.currentTimeMillis()); ...
java
@NonNull public static String getNowDateTime(@NonNull String format) { SimpleDateFormat formatter = new SimpleDateFormat(format, Locale.ENGLISH); Date curDate = new Date(System.currentTimeMillis()); return formatter.format(curDate); }
[ "@", "NonNull", "public", "static", "String", "getNowDateTime", "(", "@", "NonNull", "String", "format", ")", "{", "SimpleDateFormat", "formatter", "=", "new", "SimpleDateFormat", "(", "format", ",", "Locale", ".", "ENGLISH", ")", ";", "Date", "curDate", "=", ...
Format the current time in the specified format. @return the time string.
[ "Format", "the", "current", "time", "in", "the", "specified", "format", "." ]
train
https://github.com/yanzhenjie/Album/blob/b17506440d32909d42aba41f6a388041a25c8363/album/src/main/java/com/yanzhenjie/album/util/AlbumUtils.java#L266-L271
google/closure-compiler
src/com/google/javascript/jscomp/CheckMissingAndExtraRequires.java
CheckMissingAndExtraRequires.maybeAddWeakUsage
private void maybeAddWeakUsage(NodeTraversal t, Node n, Node typeNode) { """ Adds a weak usage for the given type expression (unless it references a variable that is defined in the externs, in which case no goog.require() is needed). When a "weak usage" is added, it means that a goog.require for that type is opt...
java
private void maybeAddWeakUsage(NodeTraversal t, Node n, Node typeNode) { maybeAddUsage(t, n, typeNode, false, Predicates.alwaysTrue()); }
[ "private", "void", "maybeAddWeakUsage", "(", "NodeTraversal", "t", ",", "Node", "n", ",", "Node", "typeNode", ")", "{", "maybeAddUsage", "(", "t", ",", "n", ",", "typeNode", ",", "false", ",", "Predicates", ".", "alwaysTrue", "(", ")", ")", ";", "}" ]
Adds a weak usage for the given type expression (unless it references a variable that is defined in the externs, in which case no goog.require() is needed). When a "weak usage" is added, it means that a goog.require for that type is optional: No warning is given whether the require is there or not.
[ "Adds", "a", "weak", "usage", "for", "the", "given", "type", "expression", "(", "unless", "it", "references", "a", "variable", "that", "is", "defined", "in", "the", "externs", "in", "which", "case", "no", "goog", ".", "require", "()", "is", "needed", ")"...
train
https://github.com/google/closure-compiler/blob/d81e36740f6a9e8ac31a825ee8758182e1dc5aae/src/com/google/javascript/jscomp/CheckMissingAndExtraRequires.java#L708-L710
ocelotds/ocelot
ocelot-web/src/main/java/org/ocelotds/core/mtc/MessageToClientManager.java
MessageToClientManager._createMessageToClient
MessageToClient _createMessageToClient(MessageFromClient message, T session) { """ Create a MessageToClient from MessageFromClient for session Only for available test use case @param message @param session @return """ MessageToClient messageToClient = new MessageToClient(); messageToClient.setId(mes...
java
MessageToClient _createMessageToClient(MessageFromClient message, T session) { MessageToClient messageToClient = new MessageToClient(); messageToClient.setId(message.getId()); try { Class cls = Class.forName(message.getDataService()); Object dataService = this.getDataService(session, cls); logger.d...
[ "MessageToClient", "_createMessageToClient", "(", "MessageFromClient", "message", ",", "T", "session", ")", "{", "MessageToClient", "messageToClient", "=", "new", "MessageToClient", "(", ")", ";", "messageToClient", ".", "setId", "(", "message", ".", "getId", "(", ...
Create a MessageToClient from MessageFromClient for session Only for available test use case @param message @param session @return
[ "Create", "a", "MessageToClient", "from", "MessageFromClient", "for", "session", "Only", "for", "available", "test", "use", "case" ]
train
https://github.com/ocelotds/ocelot/blob/5f0ac37afd8fa4dc9f7234a2aac8abbb522128e7/ocelot-web/src/main/java/org/ocelotds/core/mtc/MessageToClientManager.java#L133-L165
Azure/azure-sdk-for-java
sql/resource-manager/v2017_10_01_preview/src/main/java/com/microsoft/azure/management/sql/v2017_10_01_preview/implementation/ManagedInstanceKeysInner.java
ManagedInstanceKeysInner.beginCreateOrUpdate
public ManagedInstanceKeyInner beginCreateOrUpdate(String resourceGroupName, String managedInstanceName, String keyName, ManagedInstanceKeyInner parameters) { """ Creates or updates a managed instance key. @param resourceGroupName The name of the resource group that contains the resource. You can obtain this va...
java
public ManagedInstanceKeyInner beginCreateOrUpdate(String resourceGroupName, String managedInstanceName, String keyName, ManagedInstanceKeyInner parameters) { return beginCreateOrUpdateWithServiceResponseAsync(resourceGroupName, managedInstanceName, keyName, parameters).toBlocking().single().body(); }
[ "public", "ManagedInstanceKeyInner", "beginCreateOrUpdate", "(", "String", "resourceGroupName", ",", "String", "managedInstanceName", ",", "String", "keyName", ",", "ManagedInstanceKeyInner", "parameters", ")", "{", "return", "beginCreateOrUpdateWithServiceResponseAsync", "(", ...
Creates or updates a managed instance key. @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 managedInstanceName The name of the managed instance. @param keyName The name of the managed instance key to...
[ "Creates", "or", "updates", "a", "managed", "instance", "key", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/sql/resource-manager/v2017_10_01_preview/src/main/java/com/microsoft/azure/management/sql/v2017_10_01_preview/implementation/ManagedInstanceKeysInner.java#L528-L530
google/openrtb-doubleclick
doubleclick-core/src/main/java/com/google/doubleclick/crypto/DoubleClickCrypto.java
DoubleClickCrypto.createInitVector
public byte[] createInitVector(long timestamp, long serverId) { """ Creates the initialization vector from component {@code (timestamp, serverId)} fields. This is the format used by DoubleClick, and it's a good format generally, even though the initialization vector can be any random data (a cryptographic nonce)...
java
public byte[] createInitVector(long timestamp, long serverId) { byte[] initVector = new byte[INITV_SIZE]; ByteBuffer byteBuffer = ByteBuffer.wrap(initVector); byteBuffer.putLong(INITV_TIMESTAMP_OFFSET, timestamp); byteBuffer.putLong(INITV_SERVERID_OFFSET, serverId); return initVector; }
[ "public", "byte", "[", "]", "createInitVector", "(", "long", "timestamp", ",", "long", "serverId", ")", "{", "byte", "[", "]", "initVector", "=", "new", "byte", "[", "INITV_SIZE", "]", ";", "ByteBuffer", "byteBuffer", "=", "ByteBuffer", ".", "wrap", "(", ...
Creates the initialization vector from component {@code (timestamp, serverId)} fields. This is the format used by DoubleClick, and it's a good format generally, even though the initialization vector can be any random data (a cryptographic nonce). <p>NOTE: Follow the advice from https://developers.google.com/ad-exchang...
[ "Creates", "the", "initialization", "vector", "from", "component", "{", "@code", "(", "timestamp", "serverId", ")", "}", "fields", ".", "This", "is", "the", "format", "used", "by", "DoubleClick", "and", "it", "s", "a", "good", "format", "generally", "even", ...
train
https://github.com/google/openrtb-doubleclick/blob/2dbbbb54fd7079f107a3dfdd748d2e44e18605c3/doubleclick-core/src/main/java/com/google/doubleclick/crypto/DoubleClickCrypto.java#L222-L228
reactor/reactor-netty
src/main/java/reactor/netty/udp/UdpServer.java
UdpServer.wiretap
public final UdpServer wiretap(String category, LogLevel level) { """ Apply a wire logger configuration using the specified category and logger level @param category the logger category @param level the logger level @return a new {@link UdpServer} """ Objects.requireNonNull(category, "category"); O...
java
public final UdpServer wiretap(String category, LogLevel level) { Objects.requireNonNull(category, "category"); Objects.requireNonNull(level, "level"); return bootstrap(b -> BootstrapHandlers.updateLogSupport(b, new LoggingHandler(category, level))); }
[ "public", "final", "UdpServer", "wiretap", "(", "String", "category", ",", "LogLevel", "level", ")", "{", "Objects", ".", "requireNonNull", "(", "category", ",", "\"category\"", ")", ";", "Objects", ".", "requireNonNull", "(", "level", ",", "\"level\"", ")", ...
Apply a wire logger configuration using the specified category and logger level @param category the logger category @param level the logger level @return a new {@link UdpServer}
[ "Apply", "a", "wire", "logger", "configuration", "using", "the", "specified", "category", "and", "logger", "level" ]
train
https://github.com/reactor/reactor-netty/blob/4ed14316e1d7fca3cecd18d6caa5f2251e159e49/src/main/java/reactor/netty/udp/UdpServer.java#L396-L401
op4j/op4j
src/main/java/org/op4j/Op.java
Op.onArray
public static <T> Level0ArrayOperator<Calendar[],Calendar> onArray(final Calendar[] target) { """ <p> Creates an <i>operation expression</i> on the specified target object. </p> @param target the target object on which the expression will execute @return an operator, ready for chaining """ retur...
java
public static <T> Level0ArrayOperator<Calendar[],Calendar> onArray(final Calendar[] target) { return onArrayOf(Types.CALENDAR, target); }
[ "public", "static", "<", "T", ">", "Level0ArrayOperator", "<", "Calendar", "[", "]", ",", "Calendar", ">", "onArray", "(", "final", "Calendar", "[", "]", "target", ")", "{", "return", "onArrayOf", "(", "Types", ".", "CALENDAR", ",", "target", ")", ";", ...
<p> Creates an <i>operation expression</i> on the specified target object. </p> @param target the target object on which the expression will execute @return an operator, ready for chaining
[ "<p", ">", "Creates", "an", "<i", ">", "operation", "expression<", "/", "i", ">", "on", "the", "specified", "target", "object", ".", "<", "/", "p", ">" ]
train
https://github.com/op4j/op4j/blob/b577596dfe462089d3dd169666defc6de7ad289a/src/main/java/org/op4j/Op.java#L806-L808
BranchMetrics/android-branch-deep-linking
Branch-SDK/src/io/branch/referral/BranchAsyncTask.java
BranchAsyncTask.executeTask
public AsyncTask<Params, Progress, Result> executeTask(Params... params) { """ Execute Params in back ground depending on the platform version. This executes task in parallel with the {@link AsyncTask#THREAD_POOL_EXECUTOR} @param params Params for executing this Async task @return This object for method chaini...
java
public AsyncTask<Params, Progress, Result> executeTask(Params... params) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB) { try { return executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, params); } catch (Throwable t) { return execute(params);...
[ "public", "AsyncTask", "<", "Params", ",", "Progress", ",", "Result", ">", "executeTask", "(", "Params", "...", "params", ")", "{", "if", "(", "Build", ".", "VERSION", ".", "SDK_INT", ">=", "Build", ".", "VERSION_CODES", ".", "HONEYCOMB", ")", "{", "try"...
Execute Params in back ground depending on the platform version. This executes task in parallel with the {@link AsyncTask#THREAD_POOL_EXECUTOR} @param params Params for executing this Async task @return This object for method chaining
[ "Execute", "Params", "in", "back", "ground", "depending", "on", "the", "platform", "version", ".", "This", "executes", "task", "in", "parallel", "with", "the", "{", "@link", "AsyncTask#THREAD_POOL_EXECUTOR", "}" ]
train
https://github.com/BranchMetrics/android-branch-deep-linking/blob/e3bee2ccfcbf6d4bf1a5815b5b86666e4ff8f848/Branch-SDK/src/io/branch/referral/BranchAsyncTask.java#L19-L28
hal/core
gui/src/main/java/org/jboss/as/console/client/core/CircuitPresenter.java
CircuitPresenter.onError
protected void onError(Action action, String reason) { """ When this method is called it's guaranteed that the presenter is visible. """ Console.error(Console.CONSTANTS.lastActionError(), reason); }
java
protected void onError(Action action, String reason) { Console.error(Console.CONSTANTS.lastActionError(), reason); }
[ "protected", "void", "onError", "(", "Action", "action", ",", "String", "reason", ")", "{", "Console", ".", "error", "(", "Console", ".", "CONSTANTS", ".", "lastActionError", "(", ")", ",", "reason", ")", ";", "}" ]
When this method is called it's guaranteed that the presenter is visible.
[ "When", "this", "method", "is", "called", "it", "s", "guaranteed", "that", "the", "presenter", "is", "visible", "." ]
train
https://github.com/hal/core/blob/d6d03f0bb128dc0470f5dc75fdb1ea1014400602/gui/src/main/java/org/jboss/as/console/client/core/CircuitPresenter.java#L109-L111
Azure/azure-sdk-for-java
keyvault/data-plane/azure-keyvault/src/main/java/com/microsoft/azure/keyvault/implementation/KeyVaultClientBaseImpl.java
KeyVaultClientBaseImpl.getCertificateOperationAsync
public ServiceFuture<CertificateOperation> getCertificateOperationAsync(String vaultBaseUrl, String certificateName, final ServiceCallback<CertificateOperation> serviceCallback) { """ Gets the creation operation of a certificate. Gets the creation operation associated with a specified certificate. This operation ...
java
public ServiceFuture<CertificateOperation> getCertificateOperationAsync(String vaultBaseUrl, String certificateName, final ServiceCallback<CertificateOperation> serviceCallback) { return ServiceFuture.fromResponse(getCertificateOperationWithServiceResponseAsync(vaultBaseUrl, certificateName), serviceCallback); ...
[ "public", "ServiceFuture", "<", "CertificateOperation", ">", "getCertificateOperationAsync", "(", "String", "vaultBaseUrl", ",", "String", "certificateName", ",", "final", "ServiceCallback", "<", "CertificateOperation", ">", "serviceCallback", ")", "{", "return", "Service...
Gets the creation operation of a certificate. Gets the creation operation associated with a specified certificate. This operation requires the certificates/get permission. @param vaultBaseUrl The vault name, for example https://myvault.vault.azure.net. @param certificateName The name of the certificate. @param service...
[ "Gets", "the", "creation", "operation", "of", "a", "certificate", ".", "Gets", "the", "creation", "operation", "associated", "with", "a", "specified", "certificate", ".", "This", "operation", "requires", "the", "certificates", "/", "get", "permission", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/keyvault/data-plane/azure-keyvault/src/main/java/com/microsoft/azure/keyvault/implementation/KeyVaultClientBaseImpl.java#L7748-L7750
kuujo/vertigo
core/src/main/java/net/kuujo/vertigo/cluster/manager/impl/DefaultClusterManager.java
DefaultClusterManager.removeDeployment
private void removeDeployment(final String deploymentID, Handler<AsyncResult<String>> doneHandler) { """ Removes a deployment from the deployments map and returns the real deploymentID. """ context.execute(new Action<String>() { @Override public String perform() { Collection<String> clu...
java
private void removeDeployment(final String deploymentID, Handler<AsyncResult<String>> doneHandler) { context.execute(new Action<String>() { @Override public String perform() { Collection<String> clusterDeployments = deployments.get(cluster); if (clusterDeployments != null) { St...
[ "private", "void", "removeDeployment", "(", "final", "String", "deploymentID", ",", "Handler", "<", "AsyncResult", "<", "String", ">", ">", "doneHandler", ")", "{", "context", ".", "execute", "(", "new", "Action", "<", "String", ">", "(", ")", "{", "@", ...
Removes a deployment from the deployments map and returns the real deploymentID.
[ "Removes", "a", "deployment", "from", "the", "deployments", "map", "and", "returns", "the", "real", "deploymentID", "." ]
train
https://github.com/kuujo/vertigo/blob/c5869dbc5fff89eb5262e83f7a81719b01a5ba6f/core/src/main/java/net/kuujo/vertigo/cluster/manager/impl/DefaultClusterManager.java#L1253-L1275
jenkinsci/jenkins
core/src/main/java/hudson/model/listeners/RunListener.java
RunListener.setUpEnvironment
public Environment setUpEnvironment( AbstractBuild build, Launcher launcher, BuildListener listener ) throws IOException, InterruptedException, RunnerAbortedException { """ Runs before the {@link SCM#checkout(AbstractBuild, Launcher, FilePath, BuildListener, File)} runs, and performs a set up. Can contribute addi...
java
public Environment setUpEnvironment( AbstractBuild build, Launcher launcher, BuildListener listener ) throws IOException, InterruptedException, RunnerAbortedException { return new Environment() {}; }
[ "public", "Environment", "setUpEnvironment", "(", "AbstractBuild", "build", ",", "Launcher", "launcher", ",", "BuildListener", "listener", ")", "throws", "IOException", ",", "InterruptedException", ",", "RunnerAbortedException", "{", "return", "new", "Environment", "(",...
Runs before the {@link SCM#checkout(AbstractBuild, Launcher, FilePath, BuildListener, File)} runs, and performs a set up. Can contribute additional properties/env vars to the environment. <p> A typical strategy is for implementations to check {@link JobProperty}s and other configuration of the project to determine the...
[ "Runs", "before", "the", "{", "@link", "SCM#checkout", "(", "AbstractBuild", "Launcher", "FilePath", "BuildListener", "File", ")", "}", "runs", "and", "performs", "a", "set", "up", ".", "Can", "contribute", "additional", "properties", "/", "env", "vars", "to",...
train
https://github.com/jenkinsci/jenkins/blob/44c4d3989232082c254d27ae360aa810669f44b7/core/src/main/java/hudson/model/listeners/RunListener.java#L161-L163
elki-project/elki
elki-index-mtree/src/main/java/de/lmu/ifi/dbs/elki/index/tree/metrical/mtreevariants/mktrees/mkapp/MkAppTreeIndex.java
MkAppTreeIndex.createNewLeafEntry
protected MkAppEntry createNewLeafEntry(DBID id, O object, double parentDistance) { """ Creates a new leaf entry representing the specified data object in the specified subtree. @param object the data object to be represented by the new entry @param parentDistance the distance from the object to the routing o...
java
protected MkAppEntry createNewLeafEntry(DBID id, O object, double parentDistance) { return new MkAppLeafEntry(id, parentDistance, null); }
[ "protected", "MkAppEntry", "createNewLeafEntry", "(", "DBID", "id", ",", "O", "object", ",", "double", "parentDistance", ")", "{", "return", "new", "MkAppLeafEntry", "(", "id", ",", "parentDistance", ",", "null", ")", ";", "}" ]
Creates a new leaf entry representing the specified data object in the specified subtree. @param object the data object to be represented by the new entry @param parentDistance the distance from the object to the routing object of the parent node
[ "Creates", "a", "new", "leaf", "entry", "representing", "the", "specified", "data", "object", "in", "the", "specified", "subtree", "." ]
train
https://github.com/elki-project/elki/blob/b54673327e76198ecd4c8a2a901021f1a9174498/elki-index-mtree/src/main/java/de/lmu/ifi/dbs/elki/index/tree/metrical/mtreevariants/mktrees/mkapp/MkAppTreeIndex.java#L77-L79
killbill/killbill
invoice/src/main/java/org/killbill/billing/invoice/tree/ItemsNodeInterval.java
ItemsNodeInterval.buildForExistingItems
public void buildForExistingItems(final Collection<Item> output, final UUID targetInvoiceId) { """ <p/> There is no limit in the depth of the tree, and the build strategy is to first consider the lowest child for a given period and go up the tree adding missing interval if needed. For e.g, one of the possible s...
java
public void buildForExistingItems(final Collection<Item> output, final UUID targetInvoiceId) { // We start by pruning useless entries to simplify the build phase. pruneAndValidateTree(); build(output, targetInvoiceId, false); }
[ "public", "void", "buildForExistingItems", "(", "final", "Collection", "<", "Item", ">", "output", ",", "final", "UUID", "targetInvoiceId", ")", "{", "// We start by pruning useless entries to simplify the build phase.", "pruneAndValidateTree", "(", ")", ";", "build", "("...
<p/> There is no limit in the depth of the tree, and the build strategy is to first consider the lowest child for a given period and go up the tree adding missing interval if needed. For e.g, one of the possible scenario: <pre> D1 D2 |------------------------------------...
[ "<p", "/", ">", "There", "is", "no", "limit", "in", "the", "depth", "of", "the", "tree", "and", "the", "build", "strategy", "is", "to", "first", "consider", "the", "lowest", "child", "for", "a", "given", "period", "and", "go", "up", "the", "tree", "a...
train
https://github.com/killbill/killbill/blob/6457b485fb32a182c76197a83f428123331f1380/invoice/src/main/java/org/killbill/billing/invoice/tree/ItemsNodeInterval.java#L117-L122
gallandarakhneorg/afc
core/maths/mathtree/src/main/java/org/arakhne/afc/math/tree/node/OctTreeNode.java
OctTreeNode.moveTo
public boolean moveTo(N newParent, OctTreeZone zone) { """ Move this node in the given new node. <p>This function is preferred to a sequence of calls to {@link #removeFromParent()} and {@link #setChildAt(int, OctTreeNode)} because it fires a limited set of events dedicated to the move the node. @param new...
java
public boolean moveTo(N newParent, OctTreeZone zone) { if (zone != null) { return moveTo(newParent, zone.ordinal()); } return false; }
[ "public", "boolean", "moveTo", "(", "N", "newParent", ",", "OctTreeZone", "zone", ")", "{", "if", "(", "zone", "!=", "null", ")", "{", "return", "moveTo", "(", "newParent", ",", "zone", ".", "ordinal", "(", ")", ")", ";", "}", "return", "false", ";",...
Move this node in the given new node. <p>This function is preferred to a sequence of calls to {@link #removeFromParent()} and {@link #setChildAt(int, OctTreeNode)} because it fires a limited set of events dedicated to the move the node. @param newParent is the new parent for this node. @param zone is the position of ...
[ "Move", "this", "node", "in", "the", "given", "new", "node", "." ]
train
https://github.com/gallandarakhneorg/afc/blob/0c7d2e1ddefd4167ef788416d970a6c1ef6f8bbb/core/maths/mathtree/src/main/java/org/arakhne/afc/math/tree/node/OctTreeNode.java#L366-L371
marvinlabs/android-intents
library/src/main/java/com/marvinlabs/intents/EmailIntents.java
EmailIntents.newEmailIntent
public static Intent newEmailIntent(String address, String subject, String body) { """ Create an intent to send an email to a single recipient @param address The recipient address (or null if not specified) @param subject The subject of the email (or null if not specified) @param body The body of the email...
java
public static Intent newEmailIntent(String address, String subject, String body) { return newEmailIntent(address, subject, body, null); }
[ "public", "static", "Intent", "newEmailIntent", "(", "String", "address", ",", "String", "subject", ",", "String", "body", ")", "{", "return", "newEmailIntent", "(", "address", ",", "subject", ",", "body", ",", "null", ")", ";", "}" ]
Create an intent to send an email to a single recipient @param address The recipient address (or null if not specified) @param subject The subject of the email (or null if not specified) @param body The body of the email (or null if not specified) @return the intent
[ "Create", "an", "intent", "to", "send", "an", "email", "to", "a", "single", "recipient" ]
train
https://github.com/marvinlabs/android-intents/blob/33e79c825188b6a97601869522533cc825801f6e/library/src/main/java/com/marvinlabs/intents/EmailIntents.java#L37-L39
timols/java-gitlab-api
src/main/java/org/gitlab/api/GitlabAPI.java
GitlabAPI.deleteAward
public void deleteAward(GitlabIssue issue, Integer noteId, GitlabAward award) throws IOException { """ Delete an award for an issue note @param issue @param noteId @param award @throws IOException on gitlab api call error """ String tailUrl = GitlabProject.URL + "/" + issue.getProjectId() + Gitla...
java
public void deleteAward(GitlabIssue issue, Integer noteId, GitlabAward award) throws IOException { String tailUrl = GitlabProject.URL + "/" + issue.getProjectId() + GitlabIssue.URL + "/" + issue.getId() + GitlabNote.URL + noteId + GitlabAward.URL + "/" + award.getId(); retrieve().method(...
[ "public", "void", "deleteAward", "(", "GitlabIssue", "issue", ",", "Integer", "noteId", ",", "GitlabAward", "award", ")", "throws", "IOException", "{", "String", "tailUrl", "=", "GitlabProject", ".", "URL", "+", "\"/\"", "+", "issue", ".", "getProjectId", "(",...
Delete an award for an issue note @param issue @param noteId @param award @throws IOException on gitlab api call error
[ "Delete", "an", "award", "for", "an", "issue", "note" ]
train
https://github.com/timols/java-gitlab-api/blob/f03eedf952cfbb40306be3bf9234dcf78fab029e/src/main/java/org/gitlab/api/GitlabAPI.java#L3605-L3609