repository_name
stringlengths
7
58
func_path_in_repository
stringlengths
11
204
func_name
stringlengths
5
103
whole_func_string
stringlengths
87
3.44k
language
stringclasses
1 value
func_code_string
stringlengths
87
3.44k
func_code_tokens
listlengths
21
714
func_documentation_string
stringlengths
61
1.95k
func_documentation_tokens
listlengths
1
482
split_name
stringclasses
1 value
func_code_url
stringlengths
102
309
aspectran/aspectran
core/src/main/java/com/aspectran/core/util/StringUtils.java
StringUtils.trimTrailingCharacter
public static String trimTrailingCharacter(String str, char trailingCharacter) { if (!hasLength(str)) { return str; } StringBuilder buf = new StringBuilder(str); while (buf.length() > 0 && buf.charAt(buf.length() - 1) == trailingCharacter) { buf.deleteCharAt(buf.l...
java
public static String trimTrailingCharacter(String str, char trailingCharacter) { if (!hasLength(str)) { return str; } StringBuilder buf = new StringBuilder(str); while (buf.length() > 0 && buf.charAt(buf.length() - 1) == trailingCharacter) { buf.deleteCharAt(buf.l...
[ "public", "static", "String", "trimTrailingCharacter", "(", "String", "str", ",", "char", "trailingCharacter", ")", "{", "if", "(", "!", "hasLength", "(", "str", ")", ")", "{", "return", "str", ";", "}", "StringBuilder", "buf", "=", "new", "StringBuilder", ...
Trim all occurrences of the supplied trailing character from the given {@code String}. @param str the {@code String} to check @param trailingCharacter the trailing character to be trimmed @return the trimmed {@code String}
[ "Trim", "all", "occurrences", "of", "the", "supplied", "trailing", "character", "from", "the", "given", "{", "@code", "String", "}", "." ]
train
https://github.com/aspectran/aspectran/blob/2d758a2a28b71ee85b42823c12dc44674d7f2c70/core/src/main/java/com/aspectran/core/util/StringUtils.java#L252-L261
netty/netty
common/src/main/java/io/netty/util/internal/PlatformDependent.java
PlatformDependent.hashCodeAsciiCompute
private static int hashCodeAsciiCompute(CharSequence value, int offset, int hash) { if (BIG_ENDIAN_NATIVE_ORDER) { return hash * HASH_CODE_C1 + // Low order int hashCodeAsciiSanitizeInt(value, offset + 4) * HASH_CODE_C2 + // High order int ...
java
private static int hashCodeAsciiCompute(CharSequence value, int offset, int hash) { if (BIG_ENDIAN_NATIVE_ORDER) { return hash * HASH_CODE_C1 + // Low order int hashCodeAsciiSanitizeInt(value, offset + 4) * HASH_CODE_C2 + // High order int ...
[ "private", "static", "int", "hashCodeAsciiCompute", "(", "CharSequence", "value", ",", "int", "offset", ",", "int", "hash", ")", "{", "if", "(", "BIG_ENDIAN_NATIVE_ORDER", ")", "{", "return", "hash", "*", "HASH_CODE_C1", "+", "// Low order int", "hashCodeAsciiSani...
Identical to {@link PlatformDependent0#hashCodeAsciiCompute(long, int)} but for {@link CharSequence}.
[ "Identical", "to", "{" ]
train
https://github.com/netty/netty/blob/ba06eafa1c1824bd154f1a380019e7ea2edf3c4c/common/src/main/java/io/netty/util/internal/PlatformDependent.java#L503-L516
google/j2objc
xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xalan/transformer/TransformerHandlerImpl.java
TransformerHandlerImpl.startDTD
public void startDTD(String name, String publicId, String systemId) throws SAXException { if (DEBUG) System.out.println("TransformerHandlerImpl#startDTD: " + name + ", " + publicId + ", " + systemId); if (null != m_lexicalHandler) { m_lexicalHandler.startDT...
java
public void startDTD(String name, String publicId, String systemId) throws SAXException { if (DEBUG) System.out.println("TransformerHandlerImpl#startDTD: " + name + ", " + publicId + ", " + systemId); if (null != m_lexicalHandler) { m_lexicalHandler.startDT...
[ "public", "void", "startDTD", "(", "String", "name", ",", "String", "publicId", ",", "String", "systemId", ")", "throws", "SAXException", "{", "if", "(", "DEBUG", ")", "System", ".", "out", ".", "println", "(", "\"TransformerHandlerImpl#startDTD: \"", "+", "na...
Report the start of DTD declarations, if any. <p>Any declarations are assumed to be in the internal subset unless otherwise indicated by a {@link #startEntity startEntity} event.</p> <p>Note that the start/endDTD events will appear within the start/endDocument events from ContentHandler and before the first startElem...
[ "Report", "the", "start", "of", "DTD", "declarations", "if", "any", "." ]
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xalan/transformer/TransformerHandlerImpl.java#L768-L780
JOML-CI/JOML
src/org/joml/Matrix4x3f.java
Matrix4x3f.orthoSymmetric
public Matrix4x3f orthoSymmetric(float width, float height, float zNear, float zFar, boolean zZeroToOne) { return orthoSymmetric(width, height, zNear, zFar, zZeroToOne, this); }
java
public Matrix4x3f orthoSymmetric(float width, float height, float zNear, float zFar, boolean zZeroToOne) { return orthoSymmetric(width, height, zNear, zFar, zZeroToOne, this); }
[ "public", "Matrix4x3f", "orthoSymmetric", "(", "float", "width", ",", "float", "height", ",", "float", "zNear", ",", "float", "zFar", ",", "boolean", "zZeroToOne", ")", "{", "return", "orthoSymmetric", "(", "width", ",", "height", ",", "zNear", ",", "zFar", ...
Apply a symmetric orthographic projection transformation for a right-handed coordinate system using the given NDC z range to this matrix. <p> This method is equivalent to calling {@link #ortho(float, float, float, float, float, float, boolean) ortho()} with <code>left=-width/2</code>, <code>right=+width/2</code>, <code...
[ "Apply", "a", "symmetric", "orthographic", "projection", "transformation", "for", "a", "right", "-", "handed", "coordinate", "system", "using", "the", "given", "NDC", "z", "range", "to", "this", "matrix", ".", "<p", ">", "This", "method", "is", "equivalent", ...
train
https://github.com/JOML-CI/JOML/blob/ce2652fc236b42bda3875c591f8e6645048a678f/src/org/joml/Matrix4x3f.java#L5323-L5325
tzaeschke/zoodb
src/org/zoodb/internal/GenericObject.java
GenericObject.newEmptyInstance
static GenericObject newEmptyInstance(ZooClassDef def, AbstractCache cache) { long oid = def.getProvidedContext().getNode().getOidBuffer().allocateOid(); return newEmptyInstance(oid, def, cache); }
java
static GenericObject newEmptyInstance(ZooClassDef def, AbstractCache cache) { long oid = def.getProvidedContext().getNode().getOidBuffer().allocateOid(); return newEmptyInstance(oid, def, cache); }
[ "static", "GenericObject", "newEmptyInstance", "(", "ZooClassDef", "def", ",", "AbstractCache", "cache", ")", "{", "long", "oid", "=", "def", ".", "getProvidedContext", "(", ")", ".", "getNode", "(", ")", ".", "getOidBuffer", "(", ")", ".", "allocateOid", "(...
Creates new instances. @param def @return A new empty generic object.
[ "Creates", "new", "instances", "." ]
train
https://github.com/tzaeschke/zoodb/blob/058d0ff161a8ee9d53244c433aca97ee9c654410/src/org/zoodb/internal/GenericObject.java#L135-L138
lucee/Lucee
core/src/main/java/lucee/runtime/interpreter/CFMLExpressionInterpreter.java
CFMLExpressionInterpreter.startElement
private Ref startElement(String name) throws PageException { // check function if (!limited && cfml.isCurrent('(')) { FunctionLibFunction function = fld.getFunction(name); Ref[] arguments = functionArg(name, true, function, ')'); if (function != null) return new BIFCall(function, arguments); Ref...
java
private Ref startElement(String name) throws PageException { // check function if (!limited && cfml.isCurrent('(')) { FunctionLibFunction function = fld.getFunction(name); Ref[] arguments = functionArg(name, true, function, ')'); if (function != null) return new BIFCall(function, arguments); Ref...
[ "private", "Ref", "startElement", "(", "String", "name", ")", "throws", "PageException", "{", "// check function", "if", "(", "!", "limited", "&&", "cfml", ".", "isCurrent", "(", "'", "'", ")", ")", "{", "FunctionLibFunction", "function", "=", "fld", ".", ...
Extrahiert den Start Element einer Variale, dies ist entweder eine Funktion, eine Scope Definition oder eine undefinierte Variable. <br /> EBNF:<br /> <code>identifier "(" functionArg ")" | scope | identifier;</code> @param name Einstiegsname @return CFXD Element @throws PageException
[ "Extrahiert", "den", "Start", "Element", "einer", "Variale", "dies", "ist", "entweder", "eine", "Funktion", "eine", "Scope", "Definition", "oder", "eine", "undefinierte", "Variable", ".", "<br", "/", ">", "EBNF", ":", "<br", "/", ">", "<code", ">", "identifi...
train
https://github.com/lucee/Lucee/blob/29b153fc4e126e5edb97da937f2ee2e231b87593/core/src/main/java/lucee/runtime/interpreter/CFMLExpressionInterpreter.java#L1277-L1290
Azure/azure-sdk-for-java
containerregistry/resource-manager/v2017_06_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2017_06_01_preview/implementation/ReplicationsInner.java
ReplicationsInner.beginCreate
public ReplicationInner beginCreate(String resourceGroupName, String registryName, String replicationName, ReplicationInner replication) { return beginCreateWithServiceResponseAsync(resourceGroupName, registryName, replicationName, replication).toBlocking().single().body(); }
java
public ReplicationInner beginCreate(String resourceGroupName, String registryName, String replicationName, ReplicationInner replication) { return beginCreateWithServiceResponseAsync(resourceGroupName, registryName, replicationName, replication).toBlocking().single().body(); }
[ "public", "ReplicationInner", "beginCreate", "(", "String", "resourceGroupName", ",", "String", "registryName", ",", "String", "replicationName", ",", "ReplicationInner", "replication", ")", "{", "return", "beginCreateWithServiceResponseAsync", "(", "resourceGroupName", ","...
Creates a replication for a container registry with the specified parameters. @param resourceGroupName The name of the resource group to which the container registry belongs. @param registryName The name of the container registry. @param replicationName The name of the replication. @param replication The parameters fo...
[ "Creates", "a", "replication", "for", "a", "container", "registry", "with", "the", "specified", "parameters", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/containerregistry/resource-manager/v2017_06_01_preview/src/main/java/com/microsoft/azure/management/containerregistry/v2017_06_01_preview/implementation/ReplicationsInner.java#L294-L296
brianwhu/xillium
data/src/main/java/org/xillium/data/persistence/Persistence.java
Persistence.doReadOnly
public <T, F> T doReadOnly(F facility, Task<T, F> task) { return doTransaction(facility, task, _readonly); }
java
public <T, F> T doReadOnly(F facility, Task<T, F> task) { return doTransaction(facility, task, _readonly); }
[ "public", "<", "T", ",", "F", ">", "T", "doReadOnly", "(", "F", "facility", ",", "Task", "<", "T", ",", "F", ">", "task", ")", "{", "return", "doTransaction", "(", "facility", ",", "task", ",", "_readonly", ")", ";", "}" ]
Executes a task within a read-only transaction. Any exception rolls back the transaction and gets rethrown as a RuntimeException.
[ "Executes", "a", "task", "within", "a", "read", "-", "only", "transaction", ".", "Any", "exception", "rolls", "back", "the", "transaction", "and", "gets", "rethrown", "as", "a", "RuntimeException", "." ]
train
https://github.com/brianwhu/xillium/blob/e8dbf8cb6589fa1031a0bfcdcb58cb03d2ba7799/data/src/main/java/org/xillium/data/persistence/Persistence.java#L36-L38
bazaarvoice/emodb
sor-client-common/src/main/java/com/bazaarvoice/emodb/sor/client/DataStoreStreaming.java
DataStoreStreaming.updateAllForFacade
public static void updateAllForFacade(DataStore dataStore, Iterator<Update> updateIter, Set<String> tags) { // Invoke dataStore.updateAll() with smallish batches so if one batch fails due to server failure, we will // fail over to another server using the Ostrich retry/failover infrastructure and contin...
java
public static void updateAllForFacade(DataStore dataStore, Iterator<Update> updateIter, Set<String> tags) { // Invoke dataStore.updateAll() with smallish batches so if one batch fails due to server failure, we will // fail over to another server using the Ostrich retry/failover infrastructure and contin...
[ "public", "static", "void", "updateAllForFacade", "(", "DataStore", "dataStore", ",", "Iterator", "<", "Update", ">", "updateIter", ",", "Set", "<", "String", ">", "tags", ")", "{", "// Invoke dataStore.updateAll() with smallish batches so if one batch fails due to server f...
Creates, updates or deletes zero or more pieces of content in the data store facades.
[ "Creates", "updates", "or", "deletes", "zero", "or", "more", "pieces", "of", "content", "in", "the", "data", "store", "facades", "." ]
train
https://github.com/bazaarvoice/emodb/blob/97ec7671bc78b47fc2a1c11298c0c872bd5ec7fb/sor-client-common/src/main/java/com/bazaarvoice/emodb/sor/client/DataStoreStreaming.java#L185-L199
alkacon/opencms-core
src/org/opencms/ade/containerpage/inherited/CmsInheritedContainerState.java
CmsInheritedContainerState.addConfigurations
public void addConfigurations(CmsContainerConfigurationCache cache, String rootPath, String name) { String currentPath = rootPath; List<CmsContainerConfiguration> configurations = new ArrayList<CmsContainerConfiguration>(); CmsContainerConfigurationCacheState state = cache.getState(); ...
java
public void addConfigurations(CmsContainerConfigurationCache cache, String rootPath, String name) { String currentPath = rootPath; List<CmsContainerConfiguration> configurations = new ArrayList<CmsContainerConfiguration>(); CmsContainerConfigurationCacheState state = cache.getState(); ...
[ "public", "void", "addConfigurations", "(", "CmsContainerConfigurationCache", "cache", ",", "String", "rootPath", ",", "String", "name", ")", "{", "String", "currentPath", "=", "rootPath", ";", "List", "<", "CmsContainerConfiguration", ">", "configurations", "=", "n...
Reads the configurations for a root path and its parents from a cache instance and adds them to this state.<p> @param cache the cache instance @param rootPath the root path @param name the name of the container configuration
[ "Reads", "the", "configurations", "for", "a", "root", "path", "and", "its", "parents", "from", "a", "cache", "instance", "and", "adds", "them", "to", "this", "state", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/ade/containerpage/inherited/CmsInheritedContainerState.java#L70-L90
datacleaner/AnalyzerBeans
core/src/main/java/org/eobjects/analyzer/util/SystemProperties.java
SystemProperties.getString
public static String getString(String key, String valueIfNull) { String value = System.getProperty(key); if (Strings.isNullOrEmpty(value)) { return valueIfNull; } return value; }
java
public static String getString(String key, String valueIfNull) { String value = System.getProperty(key); if (Strings.isNullOrEmpty(value)) { return valueIfNull; } return value; }
[ "public", "static", "String", "getString", "(", "String", "key", ",", "String", "valueIfNull", ")", "{", "String", "value", "=", "System", ".", "getProperty", "(", "key", ")", ";", "if", "(", "Strings", ".", "isNullOrEmpty", "(", "value", ")", ")", "{", ...
Gets a system property string, or a replacement value if the property is null or blank. @param key @param valueIfNull @return
[ "Gets", "a", "system", "property", "string", "or", "a", "replacement", "value", "if", "the", "property", "is", "null", "or", "blank", "." ]
train
https://github.com/datacleaner/AnalyzerBeans/blob/f82dae080d80d2a647b706a5fb22b3ea250613b3/core/src/main/java/org/eobjects/analyzer/util/SystemProperties.java#L47-L53
sebastiangraf/treetank
interfacemodules/xml/src/main/java/org/treetank/service/xml/xpath/PipelineBuilder.java
PipelineBuilder.addAndExpression
public void addAndExpression(final INodeReadTrx mTransaction) { assert getPipeStack().size() >= 2; final AbsAxis mOperand2 = getPipeStack().pop().getExpr(); final AbsAxis operand1 = getPipeStack().pop().getExpr(); if (getPipeStack().empty() || getExpression().getSize() != 0) { ...
java
public void addAndExpression(final INodeReadTrx mTransaction) { assert getPipeStack().size() >= 2; final AbsAxis mOperand2 = getPipeStack().pop().getExpr(); final AbsAxis operand1 = getPipeStack().pop().getExpr(); if (getPipeStack().empty() || getExpression().getSize() != 0) { ...
[ "public", "void", "addAndExpression", "(", "final", "INodeReadTrx", "mTransaction", ")", "{", "assert", "getPipeStack", "(", ")", ".", "size", "(", ")", ">=", "2", ";", "final", "AbsAxis", "mOperand2", "=", "getPipeStack", "(", ")", ".", "pop", "(", ")", ...
Adds a and expression to the pipeline. @param mTransaction Transaction to operate with.
[ "Adds", "a", "and", "expression", "to", "the", "pipeline", "." ]
train
https://github.com/sebastiangraf/treetank/blob/9b96d631b6c2a8502a0cc958dcb02bd6a6fd8b60/interfacemodules/xml/src/main/java/org/treetank/service/xml/xpath/PipelineBuilder.java#L420-L429
looly/hutool
hutool-core/src/main/java/cn/hutool/core/util/ReUtil.java
ReUtil.findAll
public static <T extends Collection<String>> T findAll(String regex, CharSequence content, int group, T collection) { if (null == regex) { return collection; } return findAll(Pattern.compile(regex, Pattern.DOTALL), content, group, collection); }
java
public static <T extends Collection<String>> T findAll(String regex, CharSequence content, int group, T collection) { if (null == regex) { return collection; } return findAll(Pattern.compile(regex, Pattern.DOTALL), content, group, collection); }
[ "public", "static", "<", "T", "extends", "Collection", "<", "String", ">", ">", "T", "findAll", "(", "String", "regex", ",", "CharSequence", "content", ",", "int", "group", ",", "T", "collection", ")", "{", "if", "(", "null", "==", "regex", ")", "{", ...
取得内容中匹配的所有结果 @param <T> 集合类型 @param regex 正则 @param content 被查找的内容 @param group 正则的分组 @param collection 返回的集合类型 @return 结果集
[ "取得内容中匹配的所有结果" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/util/ReUtil.java#L402-L408
versionone/VersionOne.SDK.Java.ObjectModel
src/main/java/com/versionone/om/Project.java
Project.createEpic
public Epic createEpic(String name, Map<String, Object> attributes) { return getInstance().create().epic(name, this, attributes); }
java
public Epic createEpic(String name, Map<String, Object> attributes) { return getInstance().create().epic(name, this, attributes); }
[ "public", "Epic", "createEpic", "(", "String", "name", ",", "Map", "<", "String", ",", "Object", ">", "attributes", ")", "{", "return", "getInstance", "(", ")", ".", "create", "(", ")", ".", "epic", "(", "name", ",", "this", ",", "attributes", ")", "...
Create a new Epic in this Project. @param name The initial name of the Epic. @param attributes additional attributes for the Epic. @return A new Epic.
[ "Create", "a", "new", "Epic", "in", "this", "Project", "." ]
train
https://github.com/versionone/VersionOne.SDK.Java.ObjectModel/blob/59d35b67c849299631bca45ee94143237eb2ae1a/src/main/java/com/versionone/om/Project.java#L195-L197
google/j2objc
jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/zip/Deflater.java
Deflater.setDictionary
public void setDictionary(byte[] b, int off, int len) { if (b == null) { throw new NullPointerException(); } if (off < 0 || len < 0 || off > b.length - len) { throw new ArrayIndexOutOfBoundsException(); } synchronized (zsRef) { ensureOpen(); ...
java
public void setDictionary(byte[] b, int off, int len) { if (b == null) { throw new NullPointerException(); } if (off < 0 || len < 0 || off > b.length - len) { throw new ArrayIndexOutOfBoundsException(); } synchronized (zsRef) { ensureOpen(); ...
[ "public", "void", "setDictionary", "(", "byte", "[", "]", "b", ",", "int", "off", ",", "int", "len", ")", "{", "if", "(", "b", "==", "null", ")", "{", "throw", "new", "NullPointerException", "(", ")", ";", "}", "if", "(", "off", "<", "0", "||", ...
Sets preset dictionary for compression. A preset dictionary is used when the history buffer can be predetermined. When the data is later uncompressed with Inflater.inflate(), Inflater.getAdler() can be called in order to get the Adler-32 value of the dictionary required for decompression. @param b the dictionary data b...
[ "Sets", "preset", "dictionary", "for", "compression", ".", "A", "preset", "dictionary", "is", "used", "when", "the", "history", "buffer", "can", "be", "predetermined", ".", "When", "the", "data", "is", "later", "uncompressed", "with", "Inflater", ".", "inflate...
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/zip/Deflater.java#L237-L248
Trilarion/java-vorbis-support
src/main/java/com/github/trilarion/sound/sampled/spi/TAudioFileReader.java
TAudioFileReader.getAudioFileFormat
@Override public AudioFileFormat getAudioFileFormat(InputStream inputStream) throws UnsupportedAudioFileException, IOException { LOG.log(Level.FINE, "TAudioFileReader.getAudioFileFormat(InputStream): begin (class: {0})", getClass().getSimpleName()); long lFileLengthInBytes = AudioSystem....
java
@Override public AudioFileFormat getAudioFileFormat(InputStream inputStream) throws UnsupportedAudioFileException, IOException { LOG.log(Level.FINE, "TAudioFileReader.getAudioFileFormat(InputStream): begin (class: {0})", getClass().getSimpleName()); long lFileLengthInBytes = AudioSystem....
[ "@", "Override", "public", "AudioFileFormat", "getAudioFileFormat", "(", "InputStream", "inputStream", ")", "throws", "UnsupportedAudioFileException", ",", "IOException", "{", "LOG", ".", "log", "(", "Level", ".", "FINE", ",", "\"TAudioFileReader.getAudioFileFormat(InputS...
Get an AudioFileFormat object for an InputStream. This method calls getAudioFileFormat(InputStream, long). Subclasses should not override this method unless there are really severe reasons. Normally, it is sufficient to implement getAudioFileFormat(InputStream, long). @param inputStream the stream to read from. @retur...
[ "Get", "an", "AudioFileFormat", "object", "for", "an", "InputStream", ".", "This", "method", "calls", "getAudioFileFormat", "(", "InputStream", "long", ")", ".", "Subclasses", "should", "not", "override", "this", "method", "unless", "there", "are", "really", "se...
train
https://github.com/Trilarion/java-vorbis-support/blob/f72aba7d97167fe0ff20b1b719fdb5bb662ff736/src/main/java/com/github/trilarion/sound/sampled/spi/TAudioFileReader.java#L132-L153
poetix/protonpack
src/main/java/com/codepoetics/protonpack/StreamUtils.java
StreamUtils.mergeToList
@SafeVarargs public static <T> Stream<List<T>> mergeToList(Stream<T>...streams) { return merge(ArrayList::new, (l, x) -> { l.add(x); return l; }, streams); }
java
@SafeVarargs public static <T> Stream<List<T>> mergeToList(Stream<T>...streams) { return merge(ArrayList::new, (l, x) -> { l.add(x); return l; }, streams); }
[ "@", "SafeVarargs", "public", "static", "<", "T", ">", "Stream", "<", "List", "<", "T", ">", ">", "mergeToList", "(", "Stream", "<", "T", ">", "...", "streams", ")", "{", "return", "merge", "(", "ArrayList", "::", "new", ",", "(", "l", ",", "x", ...
Construct a stream which merges together values from the supplied streams into lists of values, somewhat in the manner of the stream constructed by {@link com.codepoetics.protonpack.StreamUtils#zip(java.util.stream.Stream, java.util.stream.Stream, java.util.function.BiFunction)}, but for an arbitrary number of streams....
[ "Construct", "a", "stream", "which", "merges", "together", "values", "from", "the", "supplied", "streams", "into", "lists", "of", "values", "somewhat", "in", "the", "manner", "of", "the", "stream", "constructed", "by", "{", "@link", "com", ".", "codepoetics", ...
train
https://github.com/poetix/protonpack/blob/00c55a05a4779926d02d5f4e6c820560a773f9f1/src/main/java/com/codepoetics/protonpack/StreamUtils.java#L394-L400
arquillian/arquillian-core
container/spi/src/main/java/org/jboss/arquillian/container/spi/client/deployment/Validate.java
Validate.notNullOrEmpty
public static void notNullOrEmpty(final String string, final String message) throws IllegalArgumentException { if (string == null || string.length() == 0) { throw new IllegalArgumentException(message); } }
java
public static void notNullOrEmpty(final String string, final String message) throws IllegalArgumentException { if (string == null || string.length() == 0) { throw new IllegalArgumentException(message); } }
[ "public", "static", "void", "notNullOrEmpty", "(", "final", "String", "string", ",", "final", "String", "message", ")", "throws", "IllegalArgumentException", "{", "if", "(", "string", "==", "null", "||", "string", ".", "length", "(", ")", "==", "0", ")", "...
Checks that the specified String is not null or empty, throws exception if it is. @param string The object to check @param message The exception message @throws IllegalArgumentException Thrown if obj is null
[ "Checks", "that", "the", "specified", "String", "is", "not", "null", "or", "empty", "throws", "exception", "if", "it", "is", "." ]
train
https://github.com/arquillian/arquillian-core/blob/a85b91789b80cc77e0f0c2e2abac65c2255c0a81/container/spi/src/main/java/org/jboss/arquillian/container/spi/client/deployment/Validate.java#L103-L107
GoogleCloudPlatform/bigdata-interop
util-hadoop/src/main/java/com/google/cloud/hadoop/util/ConfigurationUtil.java
ConfigurationUtil.getMandatoryConfig
public static String getMandatoryConfig(Configuration config, String key) throws IOException { String value = config.get(key); if (Strings.isNullOrEmpty(value)) { throw new IOException("Must supply a value for configuration setting: " + key); } return value; }
java
public static String getMandatoryConfig(Configuration config, String key) throws IOException { String value = config.get(key); if (Strings.isNullOrEmpty(value)) { throw new IOException("Must supply a value for configuration setting: " + key); } return value; }
[ "public", "static", "String", "getMandatoryConfig", "(", "Configuration", "config", ",", "String", "key", ")", "throws", "IOException", "{", "String", "value", "=", "config", ".", "get", "(", "key", ")", ";", "if", "(", "Strings", ".", "isNullOrEmpty", "(", ...
Gets value for the given key or throws if value is not found.
[ "Gets", "value", "for", "the", "given", "key", "or", "throws", "if", "value", "is", "not", "found", "." ]
train
https://github.com/GoogleCloudPlatform/bigdata-interop/blob/918d91c80a63e36046edb28972a5c65d3326a858/util-hadoop/src/main/java/com/google/cloud/hadoop/util/ConfigurationUtil.java#L35-L42
alkacon/opencms-core
src/org/opencms/file/CmsObject.java
CmsObject.restoreResourceVersion
public void restoreResourceVersion(CmsUUID structureId, int version) throws CmsException { CmsResource resource = readResource(structureId, CmsResourceFilter.IGNORE_EXPIRATION); getResourceType(resource).restoreResource(this, m_securityManager, resource, version); }
java
public void restoreResourceVersion(CmsUUID structureId, int version) throws CmsException { CmsResource resource = readResource(structureId, CmsResourceFilter.IGNORE_EXPIRATION); getResourceType(resource).restoreResource(this, m_securityManager, resource, version); }
[ "public", "void", "restoreResourceVersion", "(", "CmsUUID", "structureId", ",", "int", "version", ")", "throws", "CmsException", "{", "CmsResource", "resource", "=", "readResource", "(", "structureId", ",", "CmsResourceFilter", ".", "IGNORE_EXPIRATION", ")", ";", "g...
Restores a resource in the current project with a version from the historical archive.<p> @param structureId the structure id of the resource to restore from the archive @param version the desired version of the resource to be restored @throws CmsException if something goes wrong @see #readResource(CmsUUID, int)
[ "Restores", "a", "resource", "in", "the", "current", "project", "with", "a", "version", "from", "the", "historical", "archive", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/file/CmsObject.java#L3699-L3703
groovy/groovy-core
src/main/org/codehaus/groovy/runtime/StringGroovyMethods.java
StringGroovyMethods.replaceAll
public static String replaceAll(final CharSequence self, final CharSequence regex, final CharSequence replacement) { return self.toString().replaceAll(regex.toString(), replacement.toString()); }
java
public static String replaceAll(final CharSequence self, final CharSequence regex, final CharSequence replacement) { return self.toString().replaceAll(regex.toString(), replacement.toString()); }
[ "public", "static", "String", "replaceAll", "(", "final", "CharSequence", "self", ",", "final", "CharSequence", "regex", ",", "final", "CharSequence", "replacement", ")", "{", "return", "self", ".", "toString", "(", ")", ".", "replaceAll", "(", "regex", ".", ...
Replaces each substring of this CharSequence that matches the given regular expression with the given replacement. @param self a CharSequence @param regex the capturing regex @param replacement the string to be substituted for each match @return the toString() of the CharSequence with content replaced @th...
[ "Replaces", "each", "substring", "of", "this", "CharSequence", "that", "matches", "the", "given", "regular", "expression", "with", "the", "given", "replacement", "." ]
train
https://github.com/groovy/groovy-core/blob/01309f9d4be34ddf93c4a9943b5a97843bff6181/src/main/org/codehaus/groovy/runtime/StringGroovyMethods.java#L2468-L2470
google/j2objc
jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/ULocale.java
ULocale.setDefault
public static synchronized void setDefault(Category category, ULocale newLocale) { Locale newJavaDefault = newLocale.toLocale(); int idx = category.ordinal(); defaultCategoryULocales[idx] = newLocale; defaultCategoryLocales[idx] = newJavaDefault; JDKLocaleHelper.setDefault(catego...
java
public static synchronized void setDefault(Category category, ULocale newLocale) { Locale newJavaDefault = newLocale.toLocale(); int idx = category.ordinal(); defaultCategoryULocales[idx] = newLocale; defaultCategoryLocales[idx] = newJavaDefault; JDKLocaleHelper.setDefault(catego...
[ "public", "static", "synchronized", "void", "setDefault", "(", "Category", "category", ",", "ULocale", "newLocale", ")", "{", "Locale", "newJavaDefault", "=", "newLocale", ".", "toLocale", "(", ")", ";", "int", "idx", "=", "category", ".", "ordinal", "(", ")...
Sets the default <code>ULocale</code> for the specified <code>Category</code>. This also sets the default <code>Locale</code> for the specified <code>Category</code> of the JVM. If the caller does not have write permission to the user.language property, a security exception will be thrown, and the default ULocale for t...
[ "Sets", "the", "default", "<code", ">", "ULocale<", "/", "code", ">", "for", "the", "specified", "<code", ">", "Category<", "/", "code", ">", ".", "This", "also", "sets", "the", "default", "<code", ">", "Locale<", "/", "code", ">", "for", "the", "speci...
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/ULocale.java#L716-L722
smartsheet-platform/smartsheet-java-sdk
src/main/java/com/smartsheet/api/internal/ShareResourcesImpl.java
ShareResourcesImpl.deleteShare
public void deleteShare(long objectId, String shareId) throws SmartsheetException { this.deleteResource(getMasterResourceType() + "/" + objectId + "/shares/" + shareId, Share.class); }
java
public void deleteShare(long objectId, String shareId) throws SmartsheetException { this.deleteResource(getMasterResourceType() + "/" + objectId + "/shares/" + shareId, Share.class); }
[ "public", "void", "deleteShare", "(", "long", "objectId", ",", "String", "shareId", ")", "throws", "SmartsheetException", "{", "this", ".", "deleteResource", "(", "getMasterResourceType", "(", ")", "+", "\"/\"", "+", "objectId", "+", "\"/shares/\"", "+", "shareI...
Delete a share. It mirrors to the following Smartsheet REST API method: DELETE /workspaces/{workspaceId}/shares/{shareId} DELETE /sheets/{sheetId}/shares/{shareId} DELETE /sights/{sheetId}/shares/{shareId} DELETE /reports/{reportId}/shares/{shareId} Exceptions: InvalidRequestException : if there is any problem with t...
[ "Delete", "a", "share", "." ]
train
https://github.com/smartsheet-platform/smartsheet-java-sdk/blob/f60e264412076271f83b65889ef9b891fad83df8/src/main/java/com/smartsheet/api/internal/ShareResourcesImpl.java#L199-L201
facebookarchive/hadoop-20
src/hdfs/org/apache/hadoop/hdfs/server/namenode/BlockPlacementPolicyConfigurable.java
BlockPlacementPolicyConfigurable.inWindow
private boolean inWindow(DatanodeDescriptor first, DatanodeDescriptor testing) { readLock(); try { RackRingInfo rackInfo = racksMap.get(first.getNetworkLocation()); assert (rackInfo != null); Integer machineId = rackInfo.findNode(first); assert (machineId != null); final int rac...
java
private boolean inWindow(DatanodeDescriptor first, DatanodeDescriptor testing) { readLock(); try { RackRingInfo rackInfo = racksMap.get(first.getNetworkLocation()); assert (rackInfo != null); Integer machineId = rackInfo.findNode(first); assert (machineId != null); final int rac...
[ "private", "boolean", "inWindow", "(", "DatanodeDescriptor", "first", ",", "DatanodeDescriptor", "testing", ")", "{", "readLock", "(", ")", ";", "try", "{", "RackRingInfo", "rackInfo", "=", "racksMap", ".", "get", "(", "first", ".", "getNetworkLocation", "(", ...
Verifies if testing node is within right windows of first node @param first first node being considered @param testing node we are testing to check if it is within window or not @return We return true if it is successful, and not otherwise
[ "Verifies", "if", "testing", "node", "is", "within", "right", "windows", "of", "first", "node" ]
train
https://github.com/facebookarchive/hadoop-20/blob/2a29bc6ecf30edb1ad8dbde32aa49a317b4d44f4/src/hdfs/org/apache/hadoop/hdfs/server/namenode/BlockPlacementPolicyConfigurable.java#L448-L489
apache/incubator-gobblin
gobblin-core/src/main/java/org/apache/gobblin/state/ConstructState.java
ConstructState.addConstructState
public void addConstructState(Constructs construct, ConstructState constructState, Optional<String> infix) { addOverwriteProperties(constructState.getOverwritePropertiesMap()); constructState.removeProp(OVERWRITE_PROPS_KEY); for (String key : constructState.getPropertyNames()) { setProp(construct.nam...
java
public void addConstructState(Constructs construct, ConstructState constructState, Optional<String> infix) { addOverwriteProperties(constructState.getOverwritePropertiesMap()); constructState.removeProp(OVERWRITE_PROPS_KEY); for (String key : constructState.getPropertyNames()) { setProp(construct.nam...
[ "public", "void", "addConstructState", "(", "Constructs", "construct", ",", "ConstructState", "constructState", ",", "Optional", "<", "String", ">", "infix", ")", "{", "addOverwriteProperties", "(", "constructState", ".", "getOverwritePropertiesMap", "(", ")", ")", ...
Merge a {@link ConstructState} for a child construct into this {@link ConstructState}. <p> Non-override property names will be mutated as follows: key -> construct.name() + infix + key </p> @param construct type of the child construct. @param constructState {@link ConstructState} to merge. @param infix infix added to...
[ "Merge", "a", "{", "@link", "ConstructState", "}", "for", "a", "child", "construct", "into", "this", "{", "@link", "ConstructState", "}", "." ]
train
https://github.com/apache/incubator-gobblin/blob/f029b4c0fea0fe4aa62f36dda2512344ff708bae/gobblin-core/src/main/java/org/apache/gobblin/state/ConstructState.java#L105-L114
vatbub/common
internet/src/main/java/com/github/vatbub/common/internet/Internet.java
Internet.sendEventToIFTTTMakerChannel
public static String sendEventToIFTTTMakerChannel(String IFTTTMakerChannelApiKey, String eventName, String details1) throws IOException { return sendEventToIFTTTMakerChannel(IFTTTMakerChannelApiKey, eventName, details1, ""); }
java
public static String sendEventToIFTTTMakerChannel(String IFTTTMakerChannelApiKey, String eventName, String details1) throws IOException { return sendEventToIFTTTMakerChannel(IFTTTMakerChannelApiKey, eventName, details1, ""); }
[ "public", "static", "String", "sendEventToIFTTTMakerChannel", "(", "String", "IFTTTMakerChannelApiKey", ",", "String", "eventName", ",", "String", "details1", ")", "throws", "IOException", "{", "return", "sendEventToIFTTTMakerChannel", "(", "IFTTTMakerChannelApiKey", ",", ...
Sends an event to the IFTTT Maker Channel. See <a href="https://maker.ifttt.com/use/">https://maker.ifttt.com/use/</a> for more information. @param IFTTTMakerChannelApiKey Your Maker API Key. Get your one on <a href="https://ifttt.com/maker">https://ifttt.com/maker</a> @param eventName The name of the ev...
[ "Sends", "an", "event", "to", "the", "IFTTT", "Maker", "Channel", ".", "See", "<a", "href", "=", "https", ":", "//", "maker", ".", "ifttt", ".", "com", "/", "use", "/", ">", "https", ":", "//", "maker", ".", "ifttt", ".", "com", "/", "use", "/", ...
train
https://github.com/vatbub/common/blob/8b9fd2ece0a23d520ce53b66c84cbd094e378443/internet/src/main/java/com/github/vatbub/common/internet/Internet.java#L88-L91
looly/hutool
hutool-core/src/main/java/cn/hutool/core/comparator/ComparatorChain.java
ComparatorChain.compare
@Override public int compare(final E o1, final E o2) throws UnsupportedOperationException { if (lock == false) { checkChainIntegrity(); lock = true; } final Iterator<Comparator<E>> comparators = chain.iterator(); Comparator<? super E> comparator; int retval; for (int comparatorIndex = 0;...
java
@Override public int compare(final E o1, final E o2) throws UnsupportedOperationException { if (lock == false) { checkChainIntegrity(); lock = true; } final Iterator<Comparator<E>> comparators = chain.iterator(); Comparator<? super E> comparator; int retval; for (int comparatorIndex = 0;...
[ "@", "Override", "public", "int", "compare", "(", "final", "E", "o1", ",", "final", "E", "o2", ")", "throws", "UnsupportedOperationException", "{", "if", "(", "lock", "==", "false", ")", "{", "checkChainIntegrity", "(", ")", ";", "lock", "=", "true", ";"...
执行比较<br> 按照比较器链的顺序分别比较,如果比较出相等则转向下一个比较器,否则直接返回 @param o1 第一个对象 @param o2 第二个对象 @return -1, 0, or 1 @throws UnsupportedOperationException 如果比较器链为空,无法完成比较
[ "执行比较<br", ">", "按照比较器链的顺序分别比较,如果比较出相等则转向下一个比较器,否则直接返回" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/comparator/ComparatorChain.java#L203-L227
DDTH/ddth-commons
ddth-commons-core/src/main/java/com/github/ddth/commons/jsonrpc/JsonRpcUtils.java
JsonRpcUtils.callHttpGet
public static RequestResponse callHttpGet(String url, Map<String, Object> headers, Map<String, Object> urlParams) { return callHttpGet(httpJsonRpcClient, url, headers, urlParams); }
java
public static RequestResponse callHttpGet(String url, Map<String, Object> headers, Map<String, Object> urlParams) { return callHttpGet(httpJsonRpcClient, url, headers, urlParams); }
[ "public", "static", "RequestResponse", "callHttpGet", "(", "String", "url", ",", "Map", "<", "String", ",", "Object", ">", "headers", ",", "Map", "<", "String", ",", "Object", ">", "urlParams", ")", "{", "return", "callHttpGet", "(", "httpJsonRpcClient", ","...
Perform a HTTP GET request. @param url @param headers @param urlParams @return
[ "Perform", "a", "HTTP", "GET", "request", "." ]
train
https://github.com/DDTH/ddth-commons/blob/734f0e77321d41eeca78a557be9884df9874e46e/ddth-commons-core/src/main/java/com/github/ddth/commons/jsonrpc/JsonRpcUtils.java#L90-L93
Whiley/WhileyCompiler
src/main/java/wyc/io/WhileyFileParser.java
WhileyFileParser.parseBlock
private Stmt.Block parseBlock(EnclosingScope scope, boolean isLoop) { // First, determine the initial indentation of this block based on the // first statement (or null if there is no statement). Indent indent = getIndent(); // We must clone the environment here, in order to ensure variables // declared withi...
java
private Stmt.Block parseBlock(EnclosingScope scope, boolean isLoop) { // First, determine the initial indentation of this block based on the // first statement (or null if there is no statement). Indent indent = getIndent(); // We must clone the environment here, in order to ensure variables // declared withi...
[ "private", "Stmt", ".", "Block", "parseBlock", "(", "EnclosingScope", "scope", ",", "boolean", "isLoop", ")", "{", "// First, determine the initial indentation of this block based on the", "// first statement (or null if there is no statement).", "Indent", "indent", "=", "getInde...
Parse a block of zero or more statements which share the same indentation level. Their indentation level must be strictly greater than that of their parent, otherwise the end of block is signaled. The <i>indentation level</i> for the block is set by the first statement encountered (assuming their is one). An error occu...
[ "Parse", "a", "block", "of", "zero", "or", "more", "statements", "which", "share", "the", "same", "indentation", "level", ".", "Their", "indentation", "level", "must", "be", "strictly", "greater", "than", "that", "of", "their", "parent", "otherwise", "the", ...
train
https://github.com/Whiley/WhileyCompiler/blob/680f8a657d3fc286f8cc422755988b6d74ab3f4c/src/main/java/wyc/io/WhileyFileParser.java#L628-L663
JRebirth/JRebirth
org.jrebirth.af/presentation/src/main/java/org/jrebirth/af/presentation/ui/base/AbstractSlideModel.java
AbstractSlideModel.buildHorizontalAnimation
protected Animation buildHorizontalAnimation(final double fromX, final double toX, final double fromY, final double toY) { final double angle = findAngle(fromX, toX, fromY, toY); final MotionBlur mb = MotionBlurBuilder.create().angle(angle).build(); node().setEffect(mb); return Parall...
java
protected Animation buildHorizontalAnimation(final double fromX, final double toX, final double fromY, final double toY) { final double angle = findAngle(fromX, toX, fromY, toY); final MotionBlur mb = MotionBlurBuilder.create().angle(angle).build(); node().setEffect(mb); return Parall...
[ "protected", "Animation", "buildHorizontalAnimation", "(", "final", "double", "fromX", ",", "final", "double", "toX", ",", "final", "double", "fromY", ",", "final", "double", "toY", ")", "{", "final", "double", "angle", "=", "findAngle", "(", "fromX", ",", "...
Build a scaling animation. @param fromX the x starting point coordinate @param toX the x arrival point coordinate @param fromY the y starting point coordinate @param toY the y arrival point coordinate @return a translate animation
[ "Build", "a", "scaling", "animation", "." ]
train
https://github.com/JRebirth/JRebirth/blob/93f4fc087b83c73db540333b9686e97b4cec694d/org.jrebirth.af/presentation/src/main/java/org/jrebirth/af/presentation/ui/base/AbstractSlideModel.java#L495-L522
Waikato/moa
moa/src/main/java/moa/classifiers/meta/AccuracyWeightedEnsemble.java
AccuracyWeightedEnsemble.addToStored
protected Classifier addToStored(Classifier newClassifier, double newClassifiersWeight) { Classifier addedClassifier = null; Classifier[] newStored = new Classifier[this.storedLearners.length + 1]; double[][] newStoredWeights = new double[newStored.length][2]; for (int i = 0; i < newSto...
java
protected Classifier addToStored(Classifier newClassifier, double newClassifiersWeight) { Classifier addedClassifier = null; Classifier[] newStored = new Classifier[this.storedLearners.length + 1]; double[][] newStoredWeights = new double[newStored.length][2]; for (int i = 0; i < newSto...
[ "protected", "Classifier", "addToStored", "(", "Classifier", "newClassifier", ",", "double", "newClassifiersWeight", ")", "{", "Classifier", "addedClassifier", "=", "null", ";", "Classifier", "[", "]", "newStored", "=", "new", "Classifier", "[", "this", ".", "stor...
Adds a classifier to the storage. @param newClassifier The classifier to add. @param newClassifiersWeight The new classifiers weight.
[ "Adds", "a", "classifier", "to", "the", "storage", "." ]
train
https://github.com/Waikato/moa/blob/395982e5100bfe75a3a4d26115462ce2cc74cbb0/moa/src/main/java/moa/classifiers/meta/AccuracyWeightedEnsemble.java#L409-L429
deeplearning4j/deeplearning4j
deeplearning4j/deeplearning4j-nearestneighbors-parent/nearestneighbor-core/src/main/java/org/deeplearning4j/clustering/quadtree/QuadTree.java
QuadTree.computeNonEdgeForces
public void computeNonEdgeForces(int pointIndex, double theta, INDArray negativeForce, AtomicDouble sumQ) { // Make sure that we spend no time on empty nodes or self-interactions if (cumSize == 0 || (isLeaf() && size == 1 && index[0] == pointIndex)) return; // Compute distance betw...
java
public void computeNonEdgeForces(int pointIndex, double theta, INDArray negativeForce, AtomicDouble sumQ) { // Make sure that we spend no time on empty nodes or self-interactions if (cumSize == 0 || (isLeaf() && size == 1 && index[0] == pointIndex)) return; // Compute distance betw...
[ "public", "void", "computeNonEdgeForces", "(", "int", "pointIndex", ",", "double", "theta", ",", "INDArray", "negativeForce", ",", "AtomicDouble", "sumQ", ")", "{", "// Make sure that we spend no time on empty nodes or self-interactions", "if", "(", "cumSize", "==", "0", ...
Compute non edge forces using barnes hut @param pointIndex @param theta @param negativeForce @param sumQ
[ "Compute", "non", "edge", "forces", "using", "barnes", "hut" ]
train
https://github.com/deeplearning4j/deeplearning4j/blob/effce52f2afd7eeb53c5bcca699fcd90bd06822f/deeplearning4j/deeplearning4j-nearestneighbors-parent/nearestneighbor-core/src/main/java/org/deeplearning4j/clustering/quadtree/QuadTree.java#L236-L265
casmi/casmi
src/main/java/casmi/graphics/element/Quad.java
Quad.setCorner
public void setCorner(int index, double x, double y) { if (index <= 0) { this.x1 = x; this.y1 = y; } else if (index == 1) { this.x2 = x; this.y2 = y; } else if (index == 2) { this.x3 = x; this.y3 = y; } else if (inde...
java
public void setCorner(int index, double x, double y) { if (index <= 0) { this.x1 = x; this.y1 = y; } else if (index == 1) { this.x2 = x; this.y2 = y; } else if (index == 2) { this.x3 = x; this.y3 = y; } else if (inde...
[ "public", "void", "setCorner", "(", "int", "index", ",", "double", "x", ",", "double", "y", ")", "{", "if", "(", "index", "<=", "0", ")", "{", "this", ".", "x1", "=", "x", ";", "this", ".", "y1", "=", "y", ";", "}", "else", "if", "(", "index"...
Sets x,y-coordinate of a corner. @param index The index of a corner. @param x The x-coordinate of a corner. @param y The y-coordinate of a corner.
[ "Sets", "x", "y", "-", "coordinate", "of", "a", "corner", "." ]
train
https://github.com/casmi/casmi/blob/90f6514a9cbce0685186e7a92beb69e22a3b11c4/src/main/java/casmi/graphics/element/Quad.java#L151-L166
bignerdranch/expandable-recycler-view
expandablerecyclerview/src/main/java/com/bignerdranch/expandablerecyclerview/ExpandableRecyclerAdapter.java
ExpandableRecyclerAdapter.collapseParentRange
@UiThread public void collapseParentRange(int startParentPosition, int parentCount) { int endParentPosition = startParentPosition + parentCount; for (int i = startParentPosition; i < endParentPosition; i++) { collapseParent(i); } }
java
@UiThread public void collapseParentRange(int startParentPosition, int parentCount) { int endParentPosition = startParentPosition + parentCount; for (int i = startParentPosition; i < endParentPosition; i++) { collapseParent(i); } }
[ "@", "UiThread", "public", "void", "collapseParentRange", "(", "int", "startParentPosition", ",", "int", "parentCount", ")", "{", "int", "endParentPosition", "=", "startParentPosition", "+", "parentCount", ";", "for", "(", "int", "i", "=", "startParentPosition", "...
Collapses all parents in a range of indices in the list of parents. @param startParentPosition The index at which to to start collapsing parents @param parentCount The number of parents to collapse
[ "Collapses", "all", "parents", "in", "a", "range", "of", "indices", "in", "the", "list", "of", "parents", "." ]
train
https://github.com/bignerdranch/expandable-recycler-view/blob/930912510620894c531d236856fa79d646e2f1ed/expandablerecyclerview/src/main/java/com/bignerdranch/expandablerecyclerview/ExpandableRecyclerAdapter.java#L547-L553
facebookarchive/hadoop-20
src/mapred/org/apache/hadoop/mapred/TaskRunner.java
TaskRunner.getChildJavaOpts
@Deprecated public String getChildJavaOpts(JobConf jobConf, String defaultValue) { if (getTask().isJobSetupTask()) { return jobConf.get(JobConf.MAPRED_JOB_SETUP_TASK_JAVA_OPTS, defaultValue); } else if (getTask().isJobCleanupTask()) { return jobConf.get(JobConf.MAPRED_JOB_CLEANUP_TASK_JA...
java
@Deprecated public String getChildJavaOpts(JobConf jobConf, String defaultValue) { if (getTask().isJobSetupTask()) { return jobConf.get(JobConf.MAPRED_JOB_SETUP_TASK_JAVA_OPTS, defaultValue); } else if (getTask().isJobCleanupTask()) { return jobConf.get(JobConf.MAPRED_JOB_CLEANUP_TASK_JA...
[ "@", "Deprecated", "public", "String", "getChildJavaOpts", "(", "JobConf", "jobConf", ",", "String", "defaultValue", ")", "{", "if", "(", "getTask", "(", ")", ".", "isJobSetupTask", "(", ")", ")", "{", "return", "jobConf", ".", "get", "(", "JobConf", ".", ...
Get the java command line options for the child map/reduce tasks. Overriden by specific launchers. @param jobConf job configuration @param defaultValue default value @return the java command line options for child map/reduce tasks @deprecated Use command line options specific to map or reduce tasks set via {@link JobC...
[ "Get", "the", "java", "command", "line", "options", "for", "the", "child", "map", "/", "reduce", "tasks", ".", "Overriden", "by", "specific", "launchers", "." ]
train
https://github.com/facebookarchive/hadoop-20/blob/2a29bc6ecf30edb1ad8dbde32aa49a317b4d44f4/src/mapred/org/apache/hadoop/mapred/TaskRunner.java#L135-L149
netceteragroup/valdr-bean-validation
valdr-bean-validation/src/main/java/com/github/valdr/thirdparty/spring/AnnotationUtils.java
AnnotationUtils.findAnnotation
public static <A extends Annotation> A findAnnotation(Method method, Class<A> annotationType) { A annotation = getAnnotation(method, annotationType); Class<?> clazz = method.getDeclaringClass(); if (annotation == null) { annotation = searchOnInterfaces(method, annotationType, clazz.getInterfaces()); ...
java
public static <A extends Annotation> A findAnnotation(Method method, Class<A> annotationType) { A annotation = getAnnotation(method, annotationType); Class<?> clazz = method.getDeclaringClass(); if (annotation == null) { annotation = searchOnInterfaces(method, annotationType, clazz.getInterfaces()); ...
[ "public", "static", "<", "A", "extends", "Annotation", ">", "A", "findAnnotation", "(", "Method", "method", ",", "Class", "<", "A", ">", "annotationType", ")", "{", "A", "annotation", "=", "getAnnotation", "(", "method", ",", "annotationType", ")", ";", "C...
Get a single {@link java.lang.annotation.Annotation} of {@code annotationType} from the supplied {@link java.lang.reflect.Method}, traversing its super methods if no annotation can be found on the given method itself. <p>Annotations on methods are not inherited by default, so we need to handle this explicitly. @param m...
[ "Get", "a", "single", "{" ]
train
https://github.com/netceteragroup/valdr-bean-validation/blob/3f49f1357c575a11331be2de867cf47809a83823/valdr-bean-validation/src/main/java/com/github/valdr/thirdparty/spring/AnnotationUtils.java#L91-L114
lessthanoptimal/BoofCV
main/boofcv-sfm/src/main/java/boofcv/alg/sfm/overhead/CreateSyntheticOverheadView.java
CreateSyntheticOverheadView.configure
public void configure( CameraPinholeBrown intrinsic , Se3_F64 planeToCamera , double centerX, double centerY, double cellSize , int overheadWidth , int overheadHeight ) { this.overheadWidth = overheadWidth; this.overheadHeight = overheadHeight; Point2Transform2_F64 normToPixel = LensD...
java
public void configure( CameraPinholeBrown intrinsic , Se3_F64 planeToCamera , double centerX, double centerY, double cellSize , int overheadWidth , int overheadHeight ) { this.overheadWidth = overheadWidth; this.overheadHeight = overheadHeight; Point2Transform2_F64 normToPixel = LensD...
[ "public", "void", "configure", "(", "CameraPinholeBrown", "intrinsic", ",", "Se3_F64", "planeToCamera", ",", "double", "centerX", ",", "double", "centerY", ",", "double", "cellSize", ",", "int", "overheadWidth", ",", "int", "overheadHeight", ")", "{", "this", "....
Specifies camera configurations. @param intrinsic Intrinsic camera parameters @param planeToCamera Transform from the plane to the camera. This is the extrinsic parameters. @param centerX X-coordinate of camera center in the overhead image in world units. @param centerY Y-coordinate of camera center in the overhead im...
[ "Specifies", "camera", "configurations", "." ]
train
https://github.com/lessthanoptimal/BoofCV/blob/f01c0243da0ec086285ee722183804d5923bc3ac/main/boofcv-sfm/src/main/java/boofcv/alg/sfm/overhead/CreateSyntheticOverheadView.java#L81-L133
cdk/cdk
base/isomorphism/src/main/java/org/openscience/cdk/isomorphism/Mappings.java
Mappings.toChemObjects
public Iterable<IChemObject> toChemObjects() { return FluentIterable.from(map(new ToAtomBondMap(query, target))) .transformAndConcat(new Function<Map<IChemObject, IChemObject>, Iterable<? extends IChemObject>>() { @Override public Iterable<? extends IChemObje...
java
public Iterable<IChemObject> toChemObjects() { return FluentIterable.from(map(new ToAtomBondMap(query, target))) .transformAndConcat(new Function<Map<IChemObject, IChemObject>, Iterable<? extends IChemObject>>() { @Override public Iterable<? extends IChemObje...
[ "public", "Iterable", "<", "IChemObject", ">", "toChemObjects", "(", ")", "{", "return", "FluentIterable", ".", "from", "(", "map", "(", "new", "ToAtomBondMap", "(", "query", ",", "target", ")", ")", ")", ".", "transformAndConcat", "(", "new", "Function", ...
Obtain the chem objects (atoms and bonds) that have 'hit' in the target molecule. <blockquote><pre> for (IChemObject obj : mappings.toChemObjects()) { if (obj instanceof IAtom) { // this atom was 'hit' by the pattern } } </pre></blockquote> @return lazy iterable of chem objects
[ "Obtain", "the", "chem", "objects", "(", "atoms", "and", "bonds", ")", "that", "have", "hit", "in", "the", "target", "molecule", "." ]
train
https://github.com/cdk/cdk/blob/c3d0f16502bf08df50365fee392e11d7c9856657/base/isomorphism/src/main/java/org/openscience/cdk/isomorphism/Mappings.java#L436-L444
cose-wg/COSE-JAVA
src/main/java/COSE/Attribute.java
Attribute.AddUnprotected
@Deprecated public void AddUnprotected(CBORObject label, CBORObject value) throws CoseException { addAttribute(label, value, UNPROTECTED); }
java
@Deprecated public void AddUnprotected(CBORObject label, CBORObject value) throws CoseException { addAttribute(label, value, UNPROTECTED); }
[ "@", "Deprecated", "public", "void", "AddUnprotected", "(", "CBORObject", "label", ",", "CBORObject", "value", ")", "throws", "CoseException", "{", "addAttribute", "(", "label", ",", "value", ",", "UNPROTECTED", ")", ";", "}" ]
Set an attribute in the unprotected bucket of the COSE object @param label value identifies the attribute in the map @param value value to be associated with the label @deprecated As of COSE 0.9.1, use addAttribute(HeaderKeys, byte[], Attribute.UNPROTECTED); @exception CoseException COSE Package exception
[ "Set", "an", "attribute", "in", "the", "unprotected", "bucket", "of", "the", "COSE", "object" ]
train
https://github.com/cose-wg/COSE-JAVA/blob/f972b11ab4c9a18f911bc49a15225a6951cf6f63/src/main/java/COSE/Attribute.java#L219-L222
j-a-w-r/jawr-main-repo
jawr/jawr-core/src/main/java/net/jawr/web/resource/bundle/generator/variant/css/CssSkinGenerator.java
CssSkinGenerator.checkRootDirectoryNotOverlap
private void checkRootDirectoryNotOverlap(String dir, Set<String> skinRootDirectories) { String rootDir = removeLocaleSuffixIfExist(dir); for (Iterator<String> itSkinDir = skinRootDirectories.iterator(); itSkinDir.hasNext();) { String skinDir = PathNormalizer.asDirPath(itSkinDir.next()); if (!skinDir.equals(...
java
private void checkRootDirectoryNotOverlap(String dir, Set<String> skinRootDirectories) { String rootDir = removeLocaleSuffixIfExist(dir); for (Iterator<String> itSkinDir = skinRootDirectories.iterator(); itSkinDir.hasNext();) { String skinDir = PathNormalizer.asDirPath(itSkinDir.next()); if (!skinDir.equals(...
[ "private", "void", "checkRootDirectoryNotOverlap", "(", "String", "dir", ",", "Set", "<", "String", ">", "skinRootDirectories", ")", "{", "String", "rootDir", "=", "removeLocaleSuffixIfExist", "(", "dir", ")", ";", "for", "(", "Iterator", "<", "String", ">", "...
Check if there are no directory which is contained in another root directory, @param dir the root directory to check @param skinRootDirectories the root directories
[ "Check", "if", "there", "are", "no", "directory", "which", "is", "contained", "in", "another", "root", "directory" ]
train
https://github.com/j-a-w-r/jawr-main-repo/blob/5381f6acf461cd2502593c67a77bd6ef9eab848d/jawr/jawr-core/src/main/java/net/jawr/web/resource/bundle/generator/variant/css/CssSkinGenerator.java#L618-L631
carewebframework/carewebframework-vista
org.carewebframework.vista.api-parent/org.carewebframework.vista.api.esig/src/main/java/org/carewebframework/vista/esig/ESigList.java
ESigList.indexOf
public int indexOf(IESigType eSigType, String id) { return items.indexOf(new ESigItem(eSigType, id)); }
java
public int indexOf(IESigType eSigType, String id) { return items.indexOf(new ESigItem(eSigType, id)); }
[ "public", "int", "indexOf", "(", "IESigType", "eSigType", ",", "String", "id", ")", "{", "return", "items", ".", "indexOf", "(", "new", "ESigItem", "(", "eSigType", ",", "id", ")", ")", ";", "}" ]
Returns the index of a sig item identified by type and id. @param eSigType The esignature type. @param id The item id. @return Index of item.
[ "Returns", "the", "index", "of", "a", "sig", "item", "identified", "by", "type", "and", "id", "." ]
train
https://github.com/carewebframework/carewebframework-vista/blob/883b2cbe395d9e8a21cd19db820f0876bda6b1c6/org.carewebframework.vista.api-parent/org.carewebframework.vista.api.esig/src/main/java/org/carewebframework/vista/esig/ESigList.java#L94-L96
lordcodes/SnackbarBuilder
snackbarbuilder/src/main/java/com/github/andrewlord1990/snackbarbuilder/SnackbarBuilder.java
SnackbarBuilder.dismissCallback
@SuppressWarnings("WeakerAccess") public SnackbarBuilder dismissCallback(final SnackbarDismissCallback callback) { callbacks.add(new SnackbarCallback() { public void onSnackbarDismissed(Snackbar snackbar, int dismissEvent) { callback.onSnackbarDismissed(snackbar, dismissEvent); } }); r...
java
@SuppressWarnings("WeakerAccess") public SnackbarBuilder dismissCallback(final SnackbarDismissCallback callback) { callbacks.add(new SnackbarCallback() { public void onSnackbarDismissed(Snackbar snackbar, int dismissEvent) { callback.onSnackbarDismissed(snackbar, dismissEvent); } }); r...
[ "@", "SuppressWarnings", "(", "\"WeakerAccess\"", ")", "public", "SnackbarBuilder", "dismissCallback", "(", "final", "SnackbarDismissCallback", "callback", ")", "{", "callbacks", ".", "add", "(", "new", "SnackbarCallback", "(", ")", "{", "public", "void", "onSnackba...
Set the callback to be informed of the Snackbar being dismissed through some means. @param callback The callback. @return This instance.
[ "Set", "the", "callback", "to", "be", "informed", "of", "the", "Snackbar", "being", "dismissed", "through", "some", "means", "." ]
train
https://github.com/lordcodes/SnackbarBuilder/blob/a104a753c78ed66940c19d295e141a521cf81d73/snackbarbuilder/src/main/java/com/github/andrewlord1990/snackbarbuilder/SnackbarBuilder.java#L357-L365
jpush/jmessage-api-java-client
src/main/java/cn/jmessage/api/JMessageClient.java
JMessageClient.addOrRemoveCrossGroupMember
public ResponseWrapper addOrRemoveCrossGroupMember(long gid, CrossGroup[] groups) throws APIConnectionException, APIRequestException { return _crossAppClient.addOrRemoveCrossGroupMembers(gid, groups); }
java
public ResponseWrapper addOrRemoveCrossGroupMember(long gid, CrossGroup[] groups) throws APIConnectionException, APIRequestException { return _crossAppClient.addOrRemoveCrossGroupMembers(gid, groups); }
[ "public", "ResponseWrapper", "addOrRemoveCrossGroupMember", "(", "long", "gid", ",", "CrossGroup", "[", "]", "groups", ")", "throws", "APIConnectionException", ",", "APIRequestException", "{", "return", "_crossAppClient", ".", "addOrRemoveCrossGroupMembers", "(", "gid", ...
Add or remove group members from a given group id. @param gid Necessary, target group id. @param groups Necessary @return No content @throws APIConnectionException connect exception @throws APIRequestException request exception
[ "Add", "or", "remove", "group", "members", "from", "a", "given", "group", "id", "." ]
train
https://github.com/jpush/jmessage-api-java-client/blob/767f5fb15e9fe5a546c00f6e68b64f6dd53c617c/src/main/java/cn/jmessage/api/JMessageClient.java#L594-L597
drewnoakes/metadata-extractor
Source/com/drew/lang/Rational.java
Rational.getSimplifiedInstance
@NotNull public Rational getSimplifiedInstance() { long gcd = GCD(_numerator, _denominator); return new Rational(_numerator / gcd, _denominator / gcd); }
java
@NotNull public Rational getSimplifiedInstance() { long gcd = GCD(_numerator, _denominator); return new Rational(_numerator / gcd, _denominator / gcd); }
[ "@", "NotNull", "public", "Rational", "getSimplifiedInstance", "(", ")", "{", "long", "gcd", "=", "GCD", "(", "_numerator", ",", "_denominator", ")", ";", "return", "new", "Rational", "(", "_numerator", "/", "gcd", ",", "_denominator", "/", "gcd", ")", ";"...
<p> Simplifies the representation of this {@link Rational} number.</p> <p> For example, 5/10 simplifies to 1/2 because both Numerator and Denominator share a common factor of 5.</p> <p> Uses the Euclidean Algorithm to find the greatest common divisor.</p> @return A simplified instance if one exists, otherwise a copy o...
[ "<p", ">", "Simplifies", "the", "representation", "of", "this", "{", "@link", "Rational", "}", "number", ".", "<", "/", "p", ">", "<p", ">", "For", "example", "5", "/", "10", "simplifies", "to", "1", "/", "2", "because", "both", "Numerator", "and", "...
train
https://github.com/drewnoakes/metadata-extractor/blob/a958e0b61b50e590731b3be1dca8df8e21ebd43c/Source/com/drew/lang/Rational.java#L298-L304
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/field/event/ReComputeTimeOffsetHandler.java
ReComputeTimeOffsetHandler.init
public void init(BaseField field, String targetFieldName, DateTimeField fldOtherDate) { m_fldOtherDate = fldOtherDate; super.init(field, targetFieldName, null); }
java
public void init(BaseField field, String targetFieldName, DateTimeField fldOtherDate) { m_fldOtherDate = fldOtherDate; super.init(field, targetFieldName, null); }
[ "public", "void", "init", "(", "BaseField", "field", ",", "String", "targetFieldName", ",", "DateTimeField", "fldOtherDate", ")", "{", "m_fldOtherDate", "=", "fldOtherDate", ";", "super", ".", "init", "(", "field", ",", "targetFieldName", ",", "null", ")", ";"...
Constructor. @param field The basefield owner of this listener (usually null and set on setOwner()). @param iTargetFieldSeq The date field sequence in this owner to use to calc the difference. @param fldOtherDate The other date field to use in calculating the date difference. If null, uses the current time.
[ "Constructor", "." ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/field/event/ReComputeTimeOffsetHandler.java#L65-L69
liferay/com-liferay-commerce
commerce-product-service/src/main/java/com/liferay/commerce/product/service/persistence/impl/CProductPersistenceImpl.java
CProductPersistenceImpl.findByGroupId
@Override public List<CProduct> findByGroupId(long groupId) { return findByGroupId(groupId, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null); }
java
@Override public List<CProduct> findByGroupId(long groupId) { return findByGroupId(groupId, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null); }
[ "@", "Override", "public", "List", "<", "CProduct", ">", "findByGroupId", "(", "long", "groupId", ")", "{", "return", "findByGroupId", "(", "groupId", ",", "QueryUtil", ".", "ALL_POS", ",", "QueryUtil", ".", "ALL_POS", ",", "null", ")", ";", "}" ]
Returns all the c products where groupId = &#63;. @param groupId the group ID @return the matching c products
[ "Returns", "all", "the", "c", "products", "where", "groupId", "=", "&#63", ";", "." ]
train
https://github.com/liferay/com-liferay-commerce/blob/9e54362d7f59531fc684016ba49ee7cdc3a2f22b/commerce-product-service/src/main/java/com/liferay/commerce/product/service/persistence/impl/CProductPersistenceImpl.java#L1499-L1502
xmlet/XsdAsmFaster
src/main/java/org/xmlet/xsdasmfaster/classes/XsdAsmInterfaces.java
XsdAsmInterfaces.generateInnerSequenceClass
private ClassWriter generateInnerSequenceClass(String typeName, String className, String apiName) { ClassWriter classWriter = generateClass(typeName, JAVA_OBJECT, new String[] {CUSTOM_ATTRIBUTE_GROUP}, getClassSignature(new String[]{CUSTOM_ATTRIBUTE_GROUP}, typeName, apiName), ACC_PUBLIC + ACC_SUPER, apiName); ...
java
private ClassWriter generateInnerSequenceClass(String typeName, String className, String apiName) { ClassWriter classWriter = generateClass(typeName, JAVA_OBJECT, new String[] {CUSTOM_ATTRIBUTE_GROUP}, getClassSignature(new String[]{CUSTOM_ATTRIBUTE_GROUP}, typeName, apiName), ACC_PUBLIC + ACC_SUPER, apiName); ...
[ "private", "ClassWriter", "generateInnerSequenceClass", "(", "String", "typeName", ",", "String", "className", ",", "String", "apiName", ")", "{", "ClassWriter", "classWriter", "=", "generateClass", "(", "typeName", ",", "JAVA_OBJECT", ",", "new", "String", "[", "...
Creates the inner classes that are used to support the sequence behaviour. @param typeName The name of the next type to return. @param className The name of the class which contains the sequence. @param apiName The name of the generated fluent interface. @return The {@link ClassWriter} object which represents the inner...
[ "Creates", "the", "inner", "classes", "that", "are", "used", "to", "support", "the", "sequence", "behaviour", "." ]
train
https://github.com/xmlet/XsdAsmFaster/blob/ccb78f9dd4b957ad5ac1ca349eaf24338c421e94/src/main/java/org/xmlet/xsdasmfaster/classes/XsdAsmInterfaces.java#L501-L507
carewebframework/carewebframework-core
org.carewebframework.shell/src/main/java/org/carewebframework/shell/CareWebUtil.java
CareWebUtil.associateCSH
public static void associateCSH(BaseUIComponent component, String module, String topic, String label) { HelpContext context = new HelpContext(module, topic, label); HelpUtil.associateCSH(component, context, getShell()); }
java
public static void associateCSH(BaseUIComponent component, String module, String topic, String label) { HelpContext context = new HelpContext(module, topic, label); HelpUtil.associateCSH(component, context, getShell()); }
[ "public", "static", "void", "associateCSH", "(", "BaseUIComponent", "component", ",", "String", "module", ",", "String", "topic", ",", "String", "label", ")", "{", "HelpContext", "context", "=", "new", "HelpContext", "(", "module", ",", "topic", ",", "label", ...
Associates help context with a component. @param component The component. @param module The help module identifier. @param topic The topic id. @param label The topic label.
[ "Associates", "help", "context", "with", "a", "component", "." ]
train
https://github.com/carewebframework/carewebframework-core/blob/fa3252d4f7541dbe151b92c3d4f6f91433cd1673/org.carewebframework.shell/src/main/java/org/carewebframework/shell/CareWebUtil.java#L124-L127
albfernandez/itext2
src/main/java/com/lowagie/text/Utilities.java
Utilities.convertToUtf32
public static int convertToUtf32(String text, int idx) { return (((text.charAt(idx) - 0xd800) * 0x400) + (text.charAt(idx + 1) - 0xdc00)) + 0x10000; }
java
public static int convertToUtf32(String text, int idx) { return (((text.charAt(idx) - 0xd800) * 0x400) + (text.charAt(idx + 1) - 0xdc00)) + 0x10000; }
[ "public", "static", "int", "convertToUtf32", "(", "String", "text", ",", "int", "idx", ")", "{", "return", "(", "(", "(", "text", ".", "charAt", "(", "idx", ")", "-", "0xd800", ")", "*", "0x400", ")", "+", "(", "text", ".", "charAt", "(", "idx", ...
Converts a unicode character in a String to a UTF32 code point value @param text a String that has the unicode character(s) @param idx the index of the 'high' character @return the codepoint value @since 2.1.2
[ "Converts", "a", "unicode", "character", "in", "a", "String", "to", "a", "UTF32", "code", "point", "value" ]
train
https://github.com/albfernandez/itext2/blob/438fc1899367fd13dfdfa8dfdca9a3c1a7783b84/src/main/java/com/lowagie/text/Utilities.java#L326-L328
mikepenz/MaterialDrawer
library/src/main/java/com/mikepenz/materialdrawer/DrawerUtils.java
DrawerUtils.addStickyFooterDivider
private static void addStickyFooterDivider(Context ctx, ViewGroup footerView) { LinearLayout divider = new LinearLayout(ctx); LinearLayout.LayoutParams dividerParams = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT); divider.setMinimumHeigh...
java
private static void addStickyFooterDivider(Context ctx, ViewGroup footerView) { LinearLayout divider = new LinearLayout(ctx); LinearLayout.LayoutParams dividerParams = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT); divider.setMinimumHeigh...
[ "private", "static", "void", "addStickyFooterDivider", "(", "Context", "ctx", ",", "ViewGroup", "footerView", ")", "{", "LinearLayout", "divider", "=", "new", "LinearLayout", "(", "ctx", ")", ";", "LinearLayout", ".", "LayoutParams", "dividerParams", "=", "new", ...
adds the shadow to the stickyFooter @param ctx @param footerView
[ "adds", "the", "shadow", "to", "the", "stickyFooter" ]
train
https://github.com/mikepenz/MaterialDrawer/blob/f4fb31635767edead0a01cee7b7588942b89d8d9/library/src/main/java/com/mikepenz/materialdrawer/DrawerUtils.java#L381-L388
ngageoint/geopackage-core-java
src/main/java/mil/nga/geopackage/tiles/TileBoundingBoxUtils.java
TileBoundingBoxUtils.getYAsOppositeTileFormat
public static int getYAsOppositeTileFormat(int zoom, int y) { int tilesPerSide = tilesPerSide(zoom); int oppositeY = tilesPerSide - y - 1; return oppositeY; }
java
public static int getYAsOppositeTileFormat(int zoom, int y) { int tilesPerSide = tilesPerSide(zoom); int oppositeY = tilesPerSide - y - 1; return oppositeY; }
[ "public", "static", "int", "getYAsOppositeTileFormat", "(", "int", "zoom", ",", "int", "y", ")", "{", "int", "tilesPerSide", "=", "tilesPerSide", "(", "zoom", ")", ";", "int", "oppositeY", "=", "tilesPerSide", "-", "y", "-", "1", ";", "return", "oppositeY"...
Get the standard y tile location as TMS or a TMS y location as standard @param zoom zoom level @param y y coordinate @return opposite tile format y
[ "Get", "the", "standard", "y", "tile", "location", "as", "TMS", "or", "a", "TMS", "y", "location", "as", "standard" ]
train
https://github.com/ngageoint/geopackage-core-java/blob/6431c3b041a45b7f3802904ea4156b4082a72daa/src/main/java/mil/nga/geopackage/tiles/TileBoundingBoxUtils.java#L768-L772
netty/netty
codec-haproxy/src/main/java/io/netty/handler/codec/haproxy/HAProxyMessage.java
HAProxyMessage.portStringToInt
private static int portStringToInt(String value) { int port; try { port = Integer.parseInt(value); } catch (NumberFormatException e) { throw new HAProxyProtocolException("invalid port: " + value, e); } if (port <= 0 || port > 65535) { throw ne...
java
private static int portStringToInt(String value) { int port; try { port = Integer.parseInt(value); } catch (NumberFormatException e) { throw new HAProxyProtocolException("invalid port: " + value, e); } if (port <= 0 || port > 65535) { throw ne...
[ "private", "static", "int", "portStringToInt", "(", "String", "value", ")", "{", "int", "port", ";", "try", "{", "port", "=", "Integer", ".", "parseInt", "(", "value", ")", ";", "}", "catch", "(", "NumberFormatException", "e", ")", "{", "throw", "new", ...
Convert port to integer @param value the port @return port as an integer @throws HAProxyProtocolException if port is not a valid integer
[ "Convert", "port", "to", "integer" ]
train
https://github.com/netty/netty/blob/ba06eafa1c1824bd154f1a380019e7ea2edf3c4c/codec-haproxy/src/main/java/io/netty/handler/codec/haproxy/HAProxyMessage.java#L396-L409
classgraph/classgraph
src/main/java/nonapi/io/github/classgraph/classpath/ClassLoaderOrder.java
ClassLoaderOrder.delegateTo
public void delegateTo(final ClassLoader classLoader, final boolean isParent) { if (classLoader == null) { return; } // Check if this is a parent before checking if the classloader is already in the delegatedTo set, // so that if the classloader is a context classloader but a...
java
public void delegateTo(final ClassLoader classLoader, final boolean isParent) { if (classLoader == null) { return; } // Check if this is a parent before checking if the classloader is already in the delegatedTo set, // so that if the classloader is a context classloader but a...
[ "public", "void", "delegateTo", "(", "final", "ClassLoader", "classLoader", ",", "final", "boolean", "isParent", ")", "{", "if", "(", "classLoader", "==", "null", ")", "{", "return", ";", "}", "// Check if this is a parent before checking if the classloader is already i...
Recursively delegate to another {@link ClassLoader}. @param classLoader the class loader
[ "Recursively", "delegate", "to", "another", "{", "@link", "ClassLoader", "}", "." ]
train
https://github.com/classgraph/classgraph/blob/c8c8b2ca1eb76339f69193fdac33d735c864215c/src/main/java/nonapi/io/github/classgraph/classpath/ClassLoaderOrder.java#L142-L158
snowflakedb/snowflake-jdbc
src/main/java/net/snowflake/client/core/bind/BindUploader.java
BindUploader.arrayBindValueCount
public static int arrayBindValueCount(Map<String, ParameterBindingDTO> bindValues) { if (!isArrayBind(bindValues)) { return 0; } else { ParameterBindingDTO bindSample = bindValues.values().iterator().next(); List<String> bindSampleValues = (List<String>) bindSample.getValue(); ...
java
public static int arrayBindValueCount(Map<String, ParameterBindingDTO> bindValues) { if (!isArrayBind(bindValues)) { return 0; } else { ParameterBindingDTO bindSample = bindValues.values().iterator().next(); List<String> bindSampleValues = (List<String>) bindSample.getValue(); ...
[ "public", "static", "int", "arrayBindValueCount", "(", "Map", "<", "String", ",", "ParameterBindingDTO", ">", "bindValues", ")", "{", "if", "(", "!", "isArrayBind", "(", "bindValues", ")", ")", "{", "return", "0", ";", "}", "else", "{", "ParameterBindingDTO"...
Compute the number of array bind values in the given bind map @param bindValues the bind map @return 0 if bindValues is null, has no binds, or is not an array bind n otherwise, where n is the number of binds in the array bind
[ "Compute", "the", "number", "of", "array", "bind", "values", "in", "the", "given", "bind", "map" ]
train
https://github.com/snowflakedb/snowflake-jdbc/blob/98567b5a57753f29d51446809640b969a099658f/src/main/java/net/snowflake/client/core/bind/BindUploader.java#L568-L580
googlegenomics/utils-java
src/main/java/com/google/cloud/genomics/utils/OfflineAuth.java
OfflineAuth.getCredential
public Credential getCredential() { if (hasStoredCredential()) { HttpTransport httpTransport; try { httpTransport = GoogleNetHttpTransport.newTrustedTransport(); } catch (IOException | GeneralSecurityException e) { throw new RuntimeException("Could not create HTTPS transport for us...
java
public Credential getCredential() { if (hasStoredCredential()) { HttpTransport httpTransport; try { httpTransport = GoogleNetHttpTransport.newTrustedTransport(); } catch (IOException | GeneralSecurityException e) { throw new RuntimeException("Could not create HTTPS transport for us...
[ "public", "Credential", "getCredential", "(", ")", "{", "if", "(", "hasStoredCredential", "(", ")", ")", "{", "HttpTransport", "httpTransport", ";", "try", "{", "httpTransport", "=", "GoogleNetHttpTransport", ".", "newTrustedTransport", "(", ")", ";", "}", "catc...
Return the stored user credential, if applicable, or fall back to the Application Default Credential. @return The com.google.api.client.auth.oauth2.Credential object.
[ "Return", "the", "stored", "user", "credential", "if", "applicable", "or", "fall", "back", "to", "the", "Application", "Default", "Credential", "." ]
train
https://github.com/googlegenomics/utils-java/blob/7205d5b4e4f61fc6b93acb4bdd76b93df5b5f612/src/main/java/com/google/cloud/genomics/utils/OfflineAuth.java#L141-L158
facebookarchive/hadoop-20
src/contrib/corona/src/java/org/apache/hadoop/util/WebUtils.java
WebUtils.getPoolInfoHtml
public static PoolInfoHtml getPoolInfoHtml( Map<PoolInfo, PoolInfo> redirects, PoolInfo poolInfo) { String redirectAttributes = null; if (redirects != null) { PoolInfo destination = redirects.get(poolInfo); if (destination != null) { redirectAttributes = "Redirected to " + ...
java
public static PoolInfoHtml getPoolInfoHtml( Map<PoolInfo, PoolInfo> redirects, PoolInfo poolInfo) { String redirectAttributes = null; if (redirects != null) { PoolInfo destination = redirects.get(poolInfo); if (destination != null) { redirectAttributes = "Redirected to " + ...
[ "public", "static", "PoolInfoHtml", "getPoolInfoHtml", "(", "Map", "<", "PoolInfo", ",", "PoolInfo", ">", "redirects", ",", "PoolInfo", "poolInfo", ")", "{", "String", "redirectAttributes", "=", "null", ";", "if", "(", "redirects", "!=", "null", ")", "{", "P...
Generate the appropriate HTML for pool name (redirected info if necessary) @param redirects @param poolInfo @return Pair of group and pool html
[ "Generate", "the", "appropriate", "HTML", "for", "pool", "name", "(", "redirected", "info", "if", "necessary", ")" ]
train
https://github.com/facebookarchive/hadoop-20/blob/2a29bc6ecf30edb1ad8dbde32aa49a317b4d44f4/src/contrib/corona/src/java/org/apache/hadoop/util/WebUtils.java#L234-L255
otto-de/edison-microservice
edison-jobs/src/main/java/de/otto/edison/jobs/status/JobStatusCalculator.java
JobStatusCalculator.jobTooOld
protected boolean jobTooOld(final JobInfo jobInfo, final JobDefinition jobDefinition) { final Optional<OffsetDateTime> stopped = jobInfo.getStopped(); if (stopped.isPresent() && jobDefinition.maxAge().isPresent()) { final OffsetDateTime deadlineToRerun = stopped.get().plus(jobDefinition.maxA...
java
protected boolean jobTooOld(final JobInfo jobInfo, final JobDefinition jobDefinition) { final Optional<OffsetDateTime> stopped = jobInfo.getStopped(); if (stopped.isPresent() && jobDefinition.maxAge().isPresent()) { final OffsetDateTime deadlineToRerun = stopped.get().plus(jobDefinition.maxA...
[ "protected", "boolean", "jobTooOld", "(", "final", "JobInfo", "jobInfo", ",", "final", "JobDefinition", "jobDefinition", ")", "{", "final", "Optional", "<", "OffsetDateTime", ">", "stopped", "=", "jobInfo", ".", "getStopped", "(", ")", ";", "if", "(", "stopped...
Calculates whether or not the last job execution is too old. @param jobInfo job info of the last job execution @param jobDefinition job definition, specifying the max age of jobs @return boolean
[ "Calculates", "whether", "or", "not", "the", "last", "job", "execution", "is", "too", "old", "." ]
train
https://github.com/otto-de/edison-microservice/blob/89ecf0a0dee40977f004370b0b474a36c699e8a2/edison-jobs/src/main/java/de/otto/edison/jobs/status/JobStatusCalculator.java#L314-L322
xcesco/kripton
kripton-processor/src/main/java/com/abubusoft/kripton/processor/bind/transform/EnumBindTransform.java
EnumBindTransform.generateSerializeOnXml
@Override public void generateSerializeOnXml(BindTypeContext context, MethodSpec.Builder methodBuilder, String serializerName, TypeName beanClass, String beanName, BindProperty property) { XmlType xmlType = property.xmlInfo.xmlType; if (property.isNullable() && !property.isInCollection()) { methodBuilder.beginC...
java
@Override public void generateSerializeOnXml(BindTypeContext context, MethodSpec.Builder methodBuilder, String serializerName, TypeName beanClass, String beanName, BindProperty property) { XmlType xmlType = property.xmlInfo.xmlType; if (property.isNullable() && !property.isInCollection()) { methodBuilder.beginC...
[ "@", "Override", "public", "void", "generateSerializeOnXml", "(", "BindTypeContext", "context", ",", "MethodSpec", ".", "Builder", "methodBuilder", ",", "String", "serializerName", ",", "TypeName", "beanClass", ",", "String", "beanName", ",", "BindProperty", "property...
/* (non-Javadoc) @see com.abubusoft.kripton.processor.bind.transform.BindTransform#generateSerializeOnXml(com.abubusoft.kripton.processor.bind.BindTypeContext, com.squareup.javapoet.MethodSpec.Builder, java.lang.String, com.squareup.javapoet.TypeName, java.lang.String, com.abubusoft.kripton.processor.bind.model.BindPro...
[ "/", "*", "(", "non", "-", "Javadoc", ")" ]
train
https://github.com/xcesco/kripton/blob/90de2c0523d39b99e81b8d38aa996898762f594a/kripton-processor/src/main/java/com/abubusoft/kripton/processor/bind/transform/EnumBindTransform.java#L66-L95
enasequence/sequencetools
src/main/java/uk/ac/ebi/embl/template/TemplateFactory.java
TemplateFactory.getTemplateInfo
public TemplateInfo getTemplateInfo(String templateId, Integer templateVersion) throws TemplateException { if (templateSet.containsTemplateId(templateId)) { TemplateVersions versionMap = templateSet.getTemplateVersions(templateId); if (versionMap.containsVersion(templateVersion)) ...
java
public TemplateInfo getTemplateInfo(String templateId, Integer templateVersion) throws TemplateException { if (templateSet.containsTemplateId(templateId)) { TemplateVersions versionMap = templateSet.getTemplateVersions(templateId); if (versionMap.containsVersion(templateVersion)) ...
[ "public", "TemplateInfo", "getTemplateInfo", "(", "String", "templateId", ",", "Integer", "templateVersion", ")", "throws", "TemplateException", "{", "if", "(", "templateSet", ".", "containsTemplateId", "(", "templateId", ")", ")", "{", "TemplateVersions", "versionMap...
/* public List<TemplateInfo> getRNALatestIncludedTemplates() { List<TemplateInfo> rnaTemplates = getLatestIncludedTemplatesById(TemplateIDs.RNA_TEMPLATE_IDs); Collections.sort(rnaTemplates, new TemplateOrderComparator<TemplateInfo>(templateOrders)); return rnaTemplates; }
[ "/", "*", "public", "List<TemplateInfo", ">", "getRNALatestIncludedTemplates", "()", "{", "List<TemplateInfo", ">", "rnaTemplates", "=", "getLatestIncludedTemplatesById", "(", "TemplateIDs", ".", "RNA_TEMPLATE_IDs", ")", ";", "Collections", ".", "sort", "(", "rnaTemplat...
train
https://github.com/enasequence/sequencetools/blob/4127f5e1a17540239f5810136153fbd6737fa262/src/main/java/uk/ac/ebi/embl/template/TemplateFactory.java#L134-L142
vkostyukov/la4j
src/main/java/org/la4j/Matrices.java
Matrices.asDivFunction
public static MatrixFunction asDivFunction(final double arg) { return new MatrixFunction() { @Override public double evaluate(int i, int j, double value) { return value / arg; } }; }
java
public static MatrixFunction asDivFunction(final double arg) { return new MatrixFunction() { @Override public double evaluate(int i, int j, double value) { return value / arg; } }; }
[ "public", "static", "MatrixFunction", "asDivFunction", "(", "final", "double", "arg", ")", "{", "return", "new", "MatrixFunction", "(", ")", "{", "@", "Override", "public", "double", "evaluate", "(", "int", "i", ",", "int", "j", ",", "double", "value", ")"...
Creates a div function that divides it's argument by given {@code value}. @param arg a divisor value @return a closure that does {@code _ / _}
[ "Creates", "a", "div", "function", "that", "divides", "it", "s", "argument", "by", "given", "{", "@code", "value", "}", "." ]
train
https://github.com/vkostyukov/la4j/blob/dd1b917caf9606399a49afa6b0d738934cd3a7b3/src/main/java/org/la4j/Matrices.java#L487-L494
orhanobut/dialogplus
dialogplus/src/main/java/com/orhanobut/dialogplus/DialogPlusBuilder.java
DialogPlusBuilder.setHeader
public DialogPlusBuilder setHeader(@NonNull View view, boolean fixed) { this.headerView = view; this.fixedHeader = fixed; return this; }
java
public DialogPlusBuilder setHeader(@NonNull View view, boolean fixed) { this.headerView = view; this.fixedHeader = fixed; return this; }
[ "public", "DialogPlusBuilder", "setHeader", "(", "@", "NonNull", "View", "view", ",", "boolean", "fixed", ")", "{", "this", ".", "headerView", "=", "view", ";", "this", ".", "fixedHeader", "=", "fixed", ";", "return", "this", ";", "}" ]
Set the header view using a view @param fixed is used to determine whether header should be fixed or not. Fixed if true, scrollable otherwise
[ "Set", "the", "header", "view", "using", "a", "view" ]
train
https://github.com/orhanobut/dialogplus/blob/291bf4daaa3c81bf5537125f547913beb8ee2c17/dialogplus/src/main/java/com/orhanobut/dialogplus/DialogPlusBuilder.java#L137-L141
JOML-CI/JOML
src/org/joml/GeometryUtils.java
GeometryUtils.tangentBitangent
public static void tangentBitangent(Vector3fc v1, Vector2fc uv1, Vector3fc v2, Vector2fc uv2, Vector3fc v3, Vector2fc uv3, Vector3f destTangent, Vector3f destBitangent) { float DeltaV1 = uv2.y() - uv1.y(); float DeltaV2 = uv3.y() - uv1.y(); float DeltaU1 = uv2.x() - uv1.x(); float DeltaU...
java
public static void tangentBitangent(Vector3fc v1, Vector2fc uv1, Vector3fc v2, Vector2fc uv2, Vector3fc v3, Vector2fc uv3, Vector3f destTangent, Vector3f destBitangent) { float DeltaV1 = uv2.y() - uv1.y(); float DeltaV2 = uv3.y() - uv1.y(); float DeltaU1 = uv2.x() - uv1.x(); float DeltaU...
[ "public", "static", "void", "tangentBitangent", "(", "Vector3fc", "v1", ",", "Vector2fc", "uv1", ",", "Vector3fc", "v2", ",", "Vector2fc", "uv2", ",", "Vector3fc", "v3", ",", "Vector2fc", "uv3", ",", "Vector3f", "destTangent", ",", "Vector3f", "destBitangent", ...
Calculate the surface tangent and bitangent for the three supplied vertices and UV coordinates and store the result in <code>dest</code>. @param v1 XYZ of first vertex @param uv1 UV of first vertex @param v2 XYZ of second vertex @param uv2 UV of second vertex @param v3 XYZ of third vertex @param uv3 UV of third vertex...
[ "Calculate", "the", "surface", "tangent", "and", "bitangent", "for", "the", "three", "supplied", "vertices", "and", "UV", "coordinates", "and", "store", "the", "result", "in", "<code", ">", "dest<", "/", "code", ">", "." ]
train
https://github.com/JOML-CI/JOML/blob/ce2652fc236b42bda3875c591f8e6645048a678f/src/org/joml/GeometryUtils.java#L228-L245
VoltDB/voltdb
src/frontend/org/voltdb/importer/ChannelDistributer.java
ChannelDistributer.acquireAndRelease
static void acquireAndRelease(Semaphore lock) { try { lock.acquire(); lock.release(); } catch (InterruptedException ex) { throw loggedDistributerException(ex, "interruped while waiting for a semaphare"); } }
java
static void acquireAndRelease(Semaphore lock) { try { lock.acquire(); lock.release(); } catch (InterruptedException ex) { throw loggedDistributerException(ex, "interruped while waiting for a semaphare"); } }
[ "static", "void", "acquireAndRelease", "(", "Semaphore", "lock", ")", "{", "try", "{", "lock", ".", "acquire", "(", ")", ";", "lock", ".", "release", "(", ")", ";", "}", "catch", "(", "InterruptedException", "ex", ")", "{", "throw", "loggedDistributerExcep...
Boiler plate method that acquires, and releases a {@link Semaphore} @param lock a {@link Semaphore}
[ "Boiler", "plate", "method", "that", "acquires", "and", "releases", "a", "{" ]
train
https://github.com/VoltDB/voltdb/blob/8afc1031e475835344b5497ea9e7203bc95475ac/src/frontend/org/voltdb/importer/ChannelDistributer.java#L166-L173
JCTools/JCTools
jctools-build/src/main/java/org/jctools/queues/atomic/JavaParsingAtomicLinkedQueueGenerator.java
JavaParsingAtomicLinkedQueueGenerator.fieldUpdaterGetAndSet
private BlockStmt fieldUpdaterGetAndSet(String fieldUpdaterFieldName, String newValueName) { BlockStmt body = new BlockStmt(); body.addStatement(new ReturnStmt( methodCallExpr(fieldUpdaterFieldName, "getAndSet", new ThisExpr(), new NameExpr(newValueName)))); return body; }
java
private BlockStmt fieldUpdaterGetAndSet(String fieldUpdaterFieldName, String newValueName) { BlockStmt body = new BlockStmt(); body.addStatement(new ReturnStmt( methodCallExpr(fieldUpdaterFieldName, "getAndSet", new ThisExpr(), new NameExpr(newValueName)))); return body; }
[ "private", "BlockStmt", "fieldUpdaterGetAndSet", "(", "String", "fieldUpdaterFieldName", ",", "String", "newValueName", ")", "{", "BlockStmt", "body", "=", "new", "BlockStmt", "(", ")", ";", "body", ".", "addStatement", "(", "new", "ReturnStmt", "(", "methodCallEx...
Generates something like <code>return P_INDEX_UPDATER.getAndSet(this, newValue)</code> @param fieldUpdaterFieldName @param newValueName @return
[ "Generates", "something", "like", "<code", ">", "return", "P_INDEX_UPDATER", ".", "getAndSet", "(", "this", "newValue", ")", "<", "/", "code", ">" ]
train
https://github.com/JCTools/JCTools/blob/9250fe316ec84209cbba0a41682f341256df781e/jctools-build/src/main/java/org/jctools/queues/atomic/JavaParsingAtomicLinkedQueueGenerator.java#L319-L324
Azure/azure-sdk-for-java
eventhubs/data-plane/azure-eventhubs/src/main/java/com/microsoft/azure/eventhubs/RetryPolicy.java
RetryPolicy.getNextRetryInterval
public Duration getNextRetryInterval(String clientId, Exception lastException, Duration remainingTime) { int baseWaitTime = 0; synchronized (this.serverBusySync) { if (lastException != null && (lastException instanceof ServerBusyException || (lastException.getCause() != n...
java
public Duration getNextRetryInterval(String clientId, Exception lastException, Duration remainingTime) { int baseWaitTime = 0; synchronized (this.serverBusySync) { if (lastException != null && (lastException instanceof ServerBusyException || (lastException.getCause() != n...
[ "public", "Duration", "getNextRetryInterval", "(", "String", "clientId", ",", "Exception", "lastException", ",", "Duration", "remainingTime", ")", "{", "int", "baseWaitTime", "=", "0", ";", "synchronized", "(", "this", ".", "serverBusySync", ")", "{", "if", "(",...
Gets the Interval after which nextRetry should be done. @param clientId clientId @param lastException lastException @param remainingTime remainingTime to retry @return returns 'null' Duration when not Allowed
[ "Gets", "the", "Interval", "after", "which", "nextRetry", "should", "be", "done", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/eventhubs/data-plane/azure-eventhubs/src/main/java/com/microsoft/azure/eventhubs/RetryPolicy.java#L76-L86
JadiraOrg/jadira
bindings/src/main/java/org/jadira/bindings/core/binder/BasicBinder.java
BasicBinder.findBinding
public <S, T> Binding<S, T> findBinding(Class<S> source, Class<T> target, Class<? extends Annotation> qualifier) { return findBinding(new ConverterKey<S,T>(source, target, qualifier == null ? DefaultBinding.class : qualifier)); }
java
public <S, T> Binding<S, T> findBinding(Class<S> source, Class<T> target, Class<? extends Annotation> qualifier) { return findBinding(new ConverterKey<S,T>(source, target, qualifier == null ? DefaultBinding.class : qualifier)); }
[ "public", "<", "S", ",", "T", ">", "Binding", "<", "S", ",", "T", ">", "findBinding", "(", "Class", "<", "S", ">", "source", ",", "Class", "<", "T", ">", "target", ",", "Class", "<", "?", "extends", "Annotation", ">", "qualifier", ")", "{", "retu...
Resolve a Binding with the given source and target class. A binding unifies a marshaller and an unmarshaller and both must be available to resolve a binding. The source class is considered the owning class of the binding. The source can be marshalled into the target class. Similarly, the target can be unmarshalled to ...
[ "Resolve", "a", "Binding", "with", "the", "given", "source", "and", "target", "class", ".", "A", "binding", "unifies", "a", "marshaller", "and", "an", "unmarshaller", "and", "both", "must", "be", "available", "to", "resolve", "a", "binding", "." ]
train
https://github.com/JadiraOrg/jadira/blob/d55d0238395f0cb900531f1f08b4b2d87fa9a4f6/bindings/src/main/java/org/jadira/bindings/core/binder/BasicBinder.java#L891-L893
jeremylong/DependencyCheck
core/src/main/java/org/owasp/dependencycheck/analyzer/FalsePositiveAnalyzer.java
FalsePositiveAnalyzer.analyzeDependency
@Override protected void analyzeDependency(Dependency dependency, Engine engine) throws AnalysisException { removeJreEntries(dependency); removeBadMatches(dependency); removeBadSpringMatches(dependency); removeWrongVersionMatches(dependency); removeSpuriousCPE(dependency); ...
java
@Override protected void analyzeDependency(Dependency dependency, Engine engine) throws AnalysisException { removeJreEntries(dependency); removeBadMatches(dependency); removeBadSpringMatches(dependency); removeWrongVersionMatches(dependency); removeSpuriousCPE(dependency); ...
[ "@", "Override", "protected", "void", "analyzeDependency", "(", "Dependency", "dependency", ",", "Engine", "engine", ")", "throws", "AnalysisException", "{", "removeJreEntries", "(", "dependency", ")", ";", "removeBadMatches", "(", "dependency", ")", ";", "removeBad...
Analyzes the dependencies and removes bad/incorrect CPE associations based on various heuristics. @param dependency the dependency to analyze. @param engine the engine that is scanning the dependencies @throws AnalysisException is thrown if there is an error reading the JAR file.
[ "Analyzes", "the", "dependencies", "and", "removes", "bad", "/", "incorrect", "CPE", "associations", "based", "on", "various", "heuristics", "." ]
train
https://github.com/jeremylong/DependencyCheck/blob/6cc7690ea12e4ca1454210ceaa2e9a5523f0926c/core/src/main/java/org/owasp/dependencycheck/analyzer/FalsePositiveAnalyzer.java#L136-L145
wildfly/wildfly-core
patching/src/main/java/org/jboss/as/patching/runner/PatchModuleInvalidationUtils.java
PatchModuleInvalidationUtils.processFile
static void processFile(final IdentityPatchContext context, final File file, final PatchingTaskContext.Mode mode) throws IOException { if (mode == PatchingTaskContext.Mode.APPLY) { if (ENABLE_INVALIDATION) { updateJar(file, GOOD_ENDSIG_PATTERN, BAD_BYTE_SKIP, CRIPPLED_ENDSIG, GOOD_EN...
java
static void processFile(final IdentityPatchContext context, final File file, final PatchingTaskContext.Mode mode) throws IOException { if (mode == PatchingTaskContext.Mode.APPLY) { if (ENABLE_INVALIDATION) { updateJar(file, GOOD_ENDSIG_PATTERN, BAD_BYTE_SKIP, CRIPPLED_ENDSIG, GOOD_EN...
[ "static", "void", "processFile", "(", "final", "IdentityPatchContext", "context", ",", "final", "File", "file", ",", "final", "PatchingTaskContext", ".", "Mode", "mode", ")", "throws", "IOException", "{", "if", "(", "mode", "==", "PatchingTaskContext", ".", "Mod...
Process a file. @param file the file to be processed @param mode the patching mode @throws IOException
[ "Process", "a", "file", "." ]
train
https://github.com/wildfly/wildfly-core/blob/cfaf0479dcbb2d320a44c5374b93b944ec39fade/patching/src/main/java/org/jboss/as/patching/runner/PatchModuleInvalidationUtils.java#L150-L162
google/closure-templates
java/src/com/google/template/soy/jbcsrc/api/Continuations.java
Continuations.strictContinuation
static Continuation<SanitizedContent> strictContinuation( WriteContinuation delegate, final StringBuilder buffer, final ContentKind kind) { if (delegate.result().isDone()) { return new ResultContinuation<>( UnsafeSanitizedContentOrdainer.ordainAsSafe(buffer.toString(), kind)); ...
java
static Continuation<SanitizedContent> strictContinuation( WriteContinuation delegate, final StringBuilder buffer, final ContentKind kind) { if (delegate.result().isDone()) { return new ResultContinuation<>( UnsafeSanitizedContentOrdainer.ordainAsSafe(buffer.toString(), kind)); ...
[ "static", "Continuation", "<", "SanitizedContent", ">", "strictContinuation", "(", "WriteContinuation", "delegate", ",", "final", "StringBuilder", "buffer", ",", "final", "ContentKind", "kind", ")", "{", "if", "(", "delegate", ".", "result", "(", ")", ".", "isDo...
Return a {@link SanitizedContent} valued continuation. Rendering logic is delegated to the {@link WriteContinuation}, but it is assumed that the builder is the render target.
[ "Return", "a", "{" ]
train
https://github.com/google/closure-templates/blob/cc61e1dff70ae97f24f417a57410081bc498bd56/java/src/com/google/template/soy/jbcsrc/api/Continuations.java#L67-L81
mikepenz/MaterialDrawer
library/src/main/java/com/mikepenz/materialdrawer/Drawer.java
Drawer.updateIcon
public void updateIcon(long identifier, ImageHolder image) { IDrawerItem drawerItem = getDrawerItem(identifier); if (drawerItem instanceof Iconable) { Iconable pdi = (Iconable) drawerItem; pdi.withIcon(image); updateItem((IDrawerItem) pdi); } }
java
public void updateIcon(long identifier, ImageHolder image) { IDrawerItem drawerItem = getDrawerItem(identifier); if (drawerItem instanceof Iconable) { Iconable pdi = (Iconable) drawerItem; pdi.withIcon(image); updateItem((IDrawerItem) pdi); } }
[ "public", "void", "updateIcon", "(", "long", "identifier", ",", "ImageHolder", "image", ")", "{", "IDrawerItem", "drawerItem", "=", "getDrawerItem", "(", "identifier", ")", ";", "if", "(", "drawerItem", "instanceof", "Iconable", ")", "{", "Iconable", "pdi", "=...
update the name for a specific drawerItem identified by its id @param identifier @param image
[ "update", "the", "name", "for", "a", "specific", "drawerItem", "identified", "by", "its", "id" ]
train
https://github.com/mikepenz/MaterialDrawer/blob/f4fb31635767edead0a01cee7b7588942b89d8d9/library/src/main/java/com/mikepenz/materialdrawer/Drawer.java#L697-L704
samskivert/samskivert
src/main/java/com/samskivert/util/StringUtil.java
StringUtil.fieldsToString
public static String fieldsToString (Object object, String sep) { StringBuilder buf = new StringBuilder("["); fieldsToString(buf, object, sep); return buf.append("]").toString(); }
java
public static String fieldsToString (Object object, String sep) { StringBuilder buf = new StringBuilder("["); fieldsToString(buf, object, sep); return buf.append("]").toString(); }
[ "public", "static", "String", "fieldsToString", "(", "Object", "object", ",", "String", "sep", ")", "{", "StringBuilder", "buf", "=", "new", "StringBuilder", "(", "\"[\"", ")", ";", "fieldsToString", "(", "buf", ",", "object", ",", "sep", ")", ";", "return...
Like {@link #fieldsToString(Object)} except that the supplied separator string will be used between fields.
[ "Like", "{" ]
train
https://github.com/samskivert/samskivert/blob/a64d9ef42b69819bdb2c66bddac6a64caef928b6/src/main/java/com/samskivert/util/StringUtil.java#L525-L530
lucee/Lucee
core/src/main/java/lucee/runtime/op/Caster.java
Caster.toLong
public static Long toLong(Object o, Long defaultValue) { if (o instanceof Long) return (Long) o; if (defaultValue != null) return Long.valueOf(toLongValue(o, defaultValue.longValue())); long res = toLongValue(o, Long.MIN_VALUE); if (res == Long.MIN_VALUE) return defaultValue; return Long.valueOf(res); }
java
public static Long toLong(Object o, Long defaultValue) { if (o instanceof Long) return (Long) o; if (defaultValue != null) return Long.valueOf(toLongValue(o, defaultValue.longValue())); long res = toLongValue(o, Long.MIN_VALUE); if (res == Long.MIN_VALUE) return defaultValue; return Long.valueOf(res); }
[ "public", "static", "Long", "toLong", "(", "Object", "o", ",", "Long", "defaultValue", ")", "{", "if", "(", "o", "instanceof", "Long", ")", "return", "(", "Long", ")", "o", ";", "if", "(", "defaultValue", "!=", "null", ")", "return", "Long", ".", "va...
cast a Object to a Long Object(reference type) @param o Object to cast @param defaultValue @return casted Long Object
[ "cast", "a", "Object", "to", "a", "Long", "Object", "(", "reference", "type", ")" ]
train
https://github.com/lucee/Lucee/blob/29b153fc4e126e5edb97da937f2ee2e231b87593/core/src/main/java/lucee/runtime/op/Caster.java#L1546-L1553
spotbugs/spotbugs
spotbugs/src/main/java/edu/umd/cs/findbugs/TextUICommandLine.java
TextUICommandLine.addAuxClassPathEntries
private void addAuxClassPathEntries(String argument) { StringTokenizer tok = new StringTokenizer(argument, File.pathSeparator); while (tok.hasMoreTokens()) { project.addAuxClasspathEntry(tok.nextToken()); } }
java
private void addAuxClassPathEntries(String argument) { StringTokenizer tok = new StringTokenizer(argument, File.pathSeparator); while (tok.hasMoreTokens()) { project.addAuxClasspathEntry(tok.nextToken()); } }
[ "private", "void", "addAuxClassPathEntries", "(", "String", "argument", ")", "{", "StringTokenizer", "tok", "=", "new", "StringTokenizer", "(", "argument", ",", "File", ".", "pathSeparator", ")", ";", "while", "(", "tok", ".", "hasMoreTokens", "(", ")", ")", ...
Parse the argument as auxclasspath entries and add them @param argument
[ "Parse", "the", "argument", "as", "auxclasspath", "entries", "and", "add", "them" ]
train
https://github.com/spotbugs/spotbugs/blob/f6365c6eea6515035bded38efa4a7c8b46ccf28c/spotbugs/src/main/java/edu/umd/cs/findbugs/TextUICommandLine.java#L569-L574
cdk/cdk
display/renderbasic/src/main/java/org/openscience/cdk/renderer/AbstractRenderer.java
AbstractRenderer.setZoomToFit
public void setZoomToFit(double drawWidth, double drawHeight, double diagramWidth, double diagramHeight) { double margin = rendererModel.getParameter(Margin.class).getValue(); // determine the zoom needed to fit the diagram to the screen double widthRatio = drawWidth / (diagramWidth + (2 * mar...
java
public void setZoomToFit(double drawWidth, double drawHeight, double diagramWidth, double diagramHeight) { double margin = rendererModel.getParameter(Margin.class).getValue(); // determine the zoom needed to fit the diagram to the screen double widthRatio = drawWidth / (diagramWidth + (2 * mar...
[ "public", "void", "setZoomToFit", "(", "double", "drawWidth", ",", "double", "drawHeight", ",", "double", "diagramWidth", ",", "double", "diagramHeight", ")", "{", "double", "margin", "=", "rendererModel", ".", "getParameter", "(", "Margin", ".", "class", ")", ...
Calculate and set the zoom factor needed to completely fit the diagram onto the screen bounds. @param drawWidth the width of the area to draw onto @param drawHeight the height of the area to draw onto @param diagramWidth the width of the diagram @param diagramHeight the height of the diagram
[ "Calculate", "and", "set", "the", "zoom", "factor", "needed", "to", "completely", "fit", "the", "diagram", "onto", "the", "screen", "bounds", "." ]
train
https://github.com/cdk/cdk/blob/c3d0f16502bf08df50365fee392e11d7c9856657/display/renderbasic/src/main/java/org/openscience/cdk/renderer/AbstractRenderer.java#L292-L307
apache/groovy
src/main/java/org/codehaus/groovy/runtime/DefaultGroovyMethods.java
DefaultGroovyMethods.asType
@SuppressWarnings("unchecked") public static <T> T asType(Iterable iterable, Class<T> clazz) { if (Collection.class.isAssignableFrom(clazz)) { return asType((Collection) toList(iterable), clazz); } return asType((Object) iterable, clazz); }
java
@SuppressWarnings("unchecked") public static <T> T asType(Iterable iterable, Class<T> clazz) { if (Collection.class.isAssignableFrom(clazz)) { return asType((Collection) toList(iterable), clazz); } return asType((Object) iterable, clazz); }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "public", "static", "<", "T", ">", "T", "asType", "(", "Iterable", "iterable", ",", "Class", "<", "T", ">", "clazz", ")", "{", "if", "(", "Collection", ".", "class", ".", "isAssignableFrom", "(", "clazz...
Converts the given iterable to another type. @param iterable a Iterable @param clazz the desired class @return the object resulting from this type conversion @see #asType(Collection, Class) @since 2.4.12
[ "Converts", "the", "given", "iterable", "to", "another", "type", "." ]
train
https://github.com/apache/groovy/blob/71cf20addb611bb8d097a59e395fd20bc7f31772/src/main/java/org/codehaus/groovy/runtime/DefaultGroovyMethods.java#L11659-L11666
lucee/Lucee
core/src/main/java/lucee/commons/lang/StringUtil.java
StringUtil.repeatString
public static String repeatString(String str, int count) { if (count <= 0) return ""; char[] chars = str.toCharArray(); char[] rtn = new char[chars.length * count]; int pos = 0; for (int i = 0; i < count; i++) { for (int y = 0; y < chars.length; y++) rtn[pos++] = chars[y]; // rtn.append(str); } retur...
java
public static String repeatString(String str, int count) { if (count <= 0) return ""; char[] chars = str.toCharArray(); char[] rtn = new char[chars.length * count]; int pos = 0; for (int i = 0; i < count; i++) { for (int y = 0; y < chars.length; y++) rtn[pos++] = chars[y]; // rtn.append(str); } retur...
[ "public", "static", "String", "repeatString", "(", "String", "str", ",", "int", "count", ")", "{", "if", "(", "count", "<=", "0", ")", "return", "\"\"", ";", "char", "[", "]", "chars", "=", "str", ".", "toCharArray", "(", ")", ";", "char", "[", "]"...
reapeats a string @param str string to repeat @param count how many time string will be repeated @return reapted string
[ "reapeats", "a", "string" ]
train
https://github.com/lucee/Lucee/blob/29b153fc4e126e5edb97da937f2ee2e231b87593/core/src/main/java/lucee/commons/lang/StringUtil.java#L237-L248
xmlet/XsdAsmFaster
src/main/java/org/xmlet/xsdasmfaster/classes/XsdAsmUtils.java
XsdAsmUtils.createAttribute
private static void createAttribute(Map<String, List<XsdAttribute>> createdAttributes, XsdAttribute elementAttribute) { if (!createdAttributes.containsKey(elementAttribute.getName())){ List<XsdAttribute> attributes = new ArrayList<>(); attributes.add(elementAttribute); crea...
java
private static void createAttribute(Map<String, List<XsdAttribute>> createdAttributes, XsdAttribute elementAttribute) { if (!createdAttributes.containsKey(elementAttribute.getName())){ List<XsdAttribute> attributes = new ArrayList<>(); attributes.add(elementAttribute); crea...
[ "private", "static", "void", "createAttribute", "(", "Map", "<", "String", ",", "List", "<", "XsdAttribute", ">", ">", "createdAttributes", ",", "XsdAttribute", "elementAttribute", ")", "{", "if", "(", "!", "createdAttributes", ".", "containsKey", "(", "elementA...
Adds an attribute to createAttributes {@link Map} object. @param createdAttributes The received {@link Map}. Contains the already created attributes. @param elementAttribute The new attribute to add to the {@link Map} object.
[ "Adds", "an", "attribute", "to", "createAttributes", "{" ]
train
https://github.com/xmlet/XsdAsmFaster/blob/ccb78f9dd4b957ad5ac1ca349eaf24338c421e94/src/main/java/org/xmlet/xsdasmfaster/classes/XsdAsmUtils.java#L320-L334
jbundle/jbundle
base/screen/view/xml/src/main/java/org/jbundle/base/screen/view/xml/XBasePanel.java
XBasePanel.printXMLHeaderInfo
public void printXMLHeaderInfo(PrintWriter out, ResourceBundle reg) { String strTitle = this.getProperty("title"); // Menu page if ((strTitle == null) || (strTitle.length() == 0)) strTitle = ((BasePanel)this.getScreenField()).getTitle(); out.println(Utility.startTa...
java
public void printXMLHeaderInfo(PrintWriter out, ResourceBundle reg) { String strTitle = this.getProperty("title"); // Menu page if ((strTitle == null) || (strTitle.length() == 0)) strTitle = ((BasePanel)this.getScreenField()).getTitle(); out.println(Utility.startTa...
[ "public", "void", "printXMLHeaderInfo", "(", "PrintWriter", "out", ",", "ResourceBundle", "reg", ")", "{", "String", "strTitle", "=", "this", ".", "getProperty", "(", "\"title\"", ")", ";", "// Menu page", "if", "(", "(", "strTitle", "==", "null", ")", "||",...
Print the header info, such as title, keywords and meta-desc. @param out The http output stream. @param reg Local resource bundle.
[ "Print", "the", "header", "info", "such", "as", "title", "keywords", "and", "meta", "-", "desc", "." ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/screen/view/xml/src/main/java/org/jbundle/base/screen/view/xml/XBasePanel.java#L225-L239
sarl/sarl
main/coreplugins/io.sarl.lang/src/io/sarl/lang/jvmmodel/SARLJvmModelInferrer.java
SARLJvmModelInferrer.setBody
@Override protected void setBody(JvmExecutable executable, XExpression expression) { final GenerationContext context = getContext( EcoreUtil2.getContainerOfType(executable, JvmType.class)); this.typeBuilder.removeExistingBody(executable); this.associator.associateLogicalContainer(expression, executable); i...
java
@Override protected void setBody(JvmExecutable executable, XExpression expression) { final GenerationContext context = getContext( EcoreUtil2.getContainerOfType(executable, JvmType.class)); this.typeBuilder.removeExistingBody(executable); this.associator.associateLogicalContainer(expression, executable); i...
[ "@", "Override", "protected", "void", "setBody", "(", "JvmExecutable", "executable", ",", "XExpression", "expression", ")", "{", "final", "GenerationContext", "context", "=", "getContext", "(", "EcoreUtil2", ".", "getContainerOfType", "(", "executable", ",", "JvmTyp...
{@inheritDoc}. <p>Overridden for: removing the existing associated body, and delaying the local type inference.
[ "{", "@inheritDoc", "}", "." ]
train
https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/jvmmodel/SARLJvmModelInferrer.java#L477-L494
hawkular/hawkular-inventory
hawkular-inventory-security-parent/hawkular-inventory-security-accounts/src/main/java/org/hawkular/inventory/rest/security/accounts/SecurityIntegration.java
SecurityIntegration.establishOwner
private Persona establishOwner(org.hawkular.accounts.api.model.Resource resource, Persona current) { while (resource != null && resource.getPersona() == null) { resource = resource.getParent(); } if (resource != null && resource.getPersona().equals(current)) { current = ...
java
private Persona establishOwner(org.hawkular.accounts.api.model.Resource resource, Persona current) { while (resource != null && resource.getPersona() == null) { resource = resource.getParent(); } if (resource != null && resource.getPersona().equals(current)) { current = ...
[ "private", "Persona", "establishOwner", "(", "org", ".", "hawkular", ".", "accounts", ".", "api", ".", "model", ".", "Resource", "resource", ",", "Persona", "current", ")", "{", "while", "(", "resource", "!=", "null", "&&", "resource", ".", "getPersona", "...
Establishes the owner. If the owner of the parent is the same as the current user, then create the resource as being owner-less, inheriting the owner from the parent.
[ "Establishes", "the", "owner", ".", "If", "the", "owner", "of", "the", "parent", "is", "the", "same", "as", "the", "current", "user", "then", "create", "the", "resource", "as", "being", "owner", "-", "less", "inheriting", "the", "owner", "from", "the", "...
train
https://github.com/hawkular/hawkular-inventory/blob/f56dc10323dca21777feb5b609a9e9cc70ffaf62/hawkular-inventory-security-parent/hawkular-inventory-security-accounts/src/main/java/org/hawkular/inventory/rest/security/accounts/SecurityIntegration.java#L131-L141
liferay/com-liferay-commerce
commerce-api/src/main/java/com/liferay/commerce/service/persistence/CPDefinitionInventoryUtil.java
CPDefinitionInventoryUtil.removeByUUID_G
public static CPDefinitionInventory removeByUUID_G(String uuid, long groupId) throws com.liferay.commerce.exception.NoSuchCPDefinitionInventoryException { return getPersistence().removeByUUID_G(uuid, groupId); }
java
public static CPDefinitionInventory removeByUUID_G(String uuid, long groupId) throws com.liferay.commerce.exception.NoSuchCPDefinitionInventoryException { return getPersistence().removeByUUID_G(uuid, groupId); }
[ "public", "static", "CPDefinitionInventory", "removeByUUID_G", "(", "String", "uuid", ",", "long", "groupId", ")", "throws", "com", ".", "liferay", ".", "commerce", ".", "exception", ".", "NoSuchCPDefinitionInventoryException", "{", "return", "getPersistence", "(", ...
Removes the cp definition inventory where uuid = &#63; and groupId = &#63; from the database. @param uuid the uuid @param groupId the group ID @return the cp definition inventory that was removed
[ "Removes", "the", "cp", "definition", "inventory", "where", "uuid", "=", "&#63", ";", "and", "groupId", "=", "&#63", ";", "from", "the", "database", "." ]
train
https://github.com/liferay/com-liferay-commerce/blob/9e54362d7f59531fc684016ba49ee7cdc3a2f22b/commerce-api/src/main/java/com/liferay/commerce/service/persistence/CPDefinitionInventoryUtil.java#L319-L322
nobuoka/android-lib-ZXingCaptureActivity
src/main/java/info/vividcode/android/zxing/CaptureActivity.java
CaptureActivity.handleDecode
public void handleDecode(Result rawResult, Bitmap barcode, float scaleFactor) { boolean fromLiveScan = barcode != null; if (fromLiveScan) { // Then not from history, so we have an image to draw on drawResultPoints(barcode, scaleFactor, rawResult); } handleDecodeExternally(rawResult, barcode...
java
public void handleDecode(Result rawResult, Bitmap barcode, float scaleFactor) { boolean fromLiveScan = barcode != null; if (fromLiveScan) { // Then not from history, so we have an image to draw on drawResultPoints(barcode, scaleFactor, rawResult); } handleDecodeExternally(rawResult, barcode...
[ "public", "void", "handleDecode", "(", "Result", "rawResult", ",", "Bitmap", "barcode", ",", "float", "scaleFactor", ")", "{", "boolean", "fromLiveScan", "=", "barcode", "!=", "null", ";", "if", "(", "fromLiveScan", ")", "{", "// Then not from history, so we have ...
A valid barcode has been found, so give an indication of success and show the results. @param rawResult The contents of the barcode. @param scaleFactor amount by which thumbnail was scaled @param barcode A greyscale bitmap of the camera data which was decoded.
[ "A", "valid", "barcode", "has", "been", "found", "so", "give", "an", "indication", "of", "success", "and", "show", "the", "results", "." ]
train
https://github.com/nobuoka/android-lib-ZXingCaptureActivity/blob/17aaa7cf75520d3f2e03db9796b7e8c1d1f1b1e6/src/main/java/info/vividcode/android/zxing/CaptureActivity.java#L228-L236
google/j2objc
xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xalan/templates/AVTPartXPath.java
AVTPartXPath.fixupVariables
public void fixupVariables(java.util.Vector vars, int globalsSize) { m_xpath.fixupVariables(vars, globalsSize); }
java
public void fixupVariables(java.util.Vector vars, int globalsSize) { m_xpath.fixupVariables(vars, globalsSize); }
[ "public", "void", "fixupVariables", "(", "java", ".", "util", ".", "Vector", "vars", ",", "int", "globalsSize", ")", "{", "m_xpath", ".", "fixupVariables", "(", "vars", ",", "globalsSize", ")", ";", "}" ]
This function is used to fixup variables from QNames to stack frame indexes at stylesheet build time. @param vars List of QNames that correspond to variables. This list should be searched backwards for the first qualified name that corresponds to the variable reference qname. The position of the QName in the vector f...
[ "This", "function", "is", "used", "to", "fixup", "variables", "from", "QNames", "to", "stack", "frame", "indexes", "at", "stylesheet", "build", "time", "." ]
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xalan/templates/AVTPartXPath.java#L54-L57
elki-project/elki
elki-clustering/src/main/java/de/lmu/ifi/dbs/elki/algorithm/clustering/subspace/clique/CLIQUEUnit.java
CLIQUEUnit.addFeatureVector
public boolean addFeatureVector(DBIDRef id, NumberVector vector) { if(contains(vector)) { ids.add(id); return true; } return false; }
java
public boolean addFeatureVector(DBIDRef id, NumberVector vector) { if(contains(vector)) { ids.add(id); return true; } return false; }
[ "public", "boolean", "addFeatureVector", "(", "DBIDRef", "id", ",", "NumberVector", "vector", ")", "{", "if", "(", "contains", "(", "vector", ")", ")", "{", "ids", ".", "add", "(", "id", ")", ";", "return", "true", ";", "}", "return", "false", ";", "...
Adds the id of the specified feature vector to this unit, if this unit contains the feature vector. @param id Vector id @param vector the feature vector to be added @return true, if this unit contains the specified feature vector, false otherwise
[ "Adds", "the", "id", "of", "the", "specified", "feature", "vector", "to", "this", "unit", "if", "this", "unit", "contains", "the", "feature", "vector", "." ]
train
https://github.com/elki-project/elki/blob/b54673327e76198ecd4c8a2a901021f1a9174498/elki-clustering/src/main/java/de/lmu/ifi/dbs/elki/algorithm/clustering/subspace/clique/CLIQUEUnit.java#L139-L145
lodborg/interval-tree
src/main/java/com/lodborg/intervaltree/Interval.java
Interval.isRightOf
public boolean isRightOf(Interval<T> other){ if (other == null || other.isEmpty()) return false; return isRightOf(other.end, other.isEndInclusive()); }
java
public boolean isRightOf(Interval<T> other){ if (other == null || other.isEmpty()) return false; return isRightOf(other.end, other.isEndInclusive()); }
[ "public", "boolean", "isRightOf", "(", "Interval", "<", "T", ">", "other", ")", "{", "if", "(", "other", "==", "null", "||", "other", ".", "isEmpty", "(", ")", ")", "return", "false", ";", "return", "isRightOf", "(", "other", ".", "end", ",", "other"...
This method checks, if this current interval is entirely to the right of another interval with no common points. More formally, the method will return true, if for every point {@code x} from the current interval and for every point {@code y} from the {@code other} interval the inequality {@code x} &gt; {@code y} holds....
[ "This", "method", "checks", "if", "this", "current", "interval", "is", "entirely", "to", "the", "right", "of", "another", "interval", "with", "no", "common", "points", ".", "More", "formally", "the", "method", "will", "return", "true", "if", "for", "every", ...
train
https://github.com/lodborg/interval-tree/blob/716b18fb0a5a53c9add9926176bc263f14c9bf90/src/main/java/com/lodborg/intervaltree/Interval.java#L415-L419
GenesysPureEngage/authentication-client-java
src/main/java/com/genesys/internal/authentication/api/AuthenticationApi.java
AuthenticationApi.retrieveTokenAsync
public com.squareup.okhttp.Call retrieveTokenAsync(String grantType, String accept, String authorization, String clientId, String password, String refreshToken, String scope, String username, final ApiCallback<DefaultOAuth2AccessToken> callback) throws ApiException { ProgressResponseBody.ProgressListener progr...
java
public com.squareup.okhttp.Call retrieveTokenAsync(String grantType, String accept, String authorization, String clientId, String password, String refreshToken, String scope, String username, final ApiCallback<DefaultOAuth2AccessToken> callback) throws ApiException { ProgressResponseBody.ProgressListener progr...
[ "public", "com", ".", "squareup", ".", "okhttp", ".", "Call", "retrieveTokenAsync", "(", "String", "grantType", ",", "String", "accept", ",", "String", "authorization", ",", "String", "clientId", ",", "String", "password", ",", "String", "refreshToken", ",", "...
Retrieve access token (asynchronously) Retrieve an access token based on the grant type &amp;mdash; Authorization Code Grant, Resource Owner Password Credentials Grant or Client Credentials Grant. For more information, see [Token Endpoint](https://tools.ietf.org/html/rfc6749). **Note:** For the optional **scope** param...
[ "Retrieve", "access", "token", "(", "asynchronously", ")", "Retrieve", "an", "access", "token", "based", "on", "the", "grant", "type", "&amp", ";", "mdash", ";", "Authorization", "Code", "Grant", "Resource", "Owner", "Password", "Credentials", "Grant", "or", "...
train
https://github.com/GenesysPureEngage/authentication-client-java/blob/eb0d58343ee42ebd3c037163c1137f611dfcbb3a/src/main/java/com/genesys/internal/authentication/api/AuthenticationApi.java#L1089-L1114
ineunetOS/knife-commons
knife-commons-utils/src/main/java/com/ineunet/knife/util/DecimalUtils.java
DecimalUtils.isValueEquals
public static boolean isValueEquals(BigDecimal decimal1, BigDecimal decimal2) { if (decimal1 == null && decimal2 == null) return true; if (decimal1 == null && decimal2 != null) return false; if (decimal1 != null && decimal2 == null) return false; return cutInvalidSacle(decimal1).equals(cutInvalidSacle(decimal2)...
java
public static boolean isValueEquals(BigDecimal decimal1, BigDecimal decimal2) { if (decimal1 == null && decimal2 == null) return true; if (decimal1 == null && decimal2 != null) return false; if (decimal1 != null && decimal2 == null) return false; return cutInvalidSacle(decimal1).equals(cutInvalidSacle(decimal2)...
[ "public", "static", "boolean", "isValueEquals", "(", "BigDecimal", "decimal1", ",", "BigDecimal", "decimal2", ")", "{", "if", "(", "decimal1", "==", "null", "&&", "decimal2", "==", "null", ")", "return", "true", ";", "if", "(", "decimal1", "==", "null", "&...
e.g. 0.30 equals 0.3 && 0.30 equals 0.30 && 0.30 equals 0.300.
[ "e", ".", "g", ".", "0", ".", "30", "equals", "0", ".", "3", "&&", "0", ".", "30", "equals", "0", ".", "30", "&&", "0", ".", "30", "equals", "0", ".", "300", "." ]
train
https://github.com/ineunetOS/knife-commons/blob/eae9e59afa020a00ae8977c10d43ac8ae46ae236/knife-commons-utils/src/main/java/com/ineunet/knife/util/DecimalUtils.java#L49-L54
UrielCh/ovh-java-sdk
ovh-java-sdk-order/src/main/java/net/minidev/ovh/api/ApiOvhOrder.java
ApiOvhOrder.telephony_billingAccount_line_GET
public OvhOrder telephony_billingAccount_line_GET(String billingAccount, String brand, Boolean[] displayUniversalDirectories, Long[] extraSimultaneousLines, String mondialRelayId, String[] offers, Long[] ownerContactIds, Long quantity, Boolean retractation, Long shippingContactId, OvhLineTypeEnum[] types, String[] zone...
java
public OvhOrder telephony_billingAccount_line_GET(String billingAccount, String brand, Boolean[] displayUniversalDirectories, Long[] extraSimultaneousLines, String mondialRelayId, String[] offers, Long[] ownerContactIds, Long quantity, Boolean retractation, Long shippingContactId, OvhLineTypeEnum[] types, String[] zone...
[ "public", "OvhOrder", "telephony_billingAccount_line_GET", "(", "String", "billingAccount", ",", "String", "brand", ",", "Boolean", "[", "]", "displayUniversalDirectories", ",", "Long", "[", "]", "extraSimultaneousLines", ",", "String", "mondialRelayId", ",", "String", ...
Get prices and contracts information REST: GET /order/telephony/{billingAccount}/line @param extraSimultaneousLines [required] Additional simultaneous numbers. Set several simultaneous lines for each line per phone @param quantity [required] Quantity of request repetition in this configuration @param retractation [req...
[ "Get", "prices", "and", "contracts", "information" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-order/src/main/java/net/minidev/ovh/api/ApiOvhOrder.java#L6335-L6351
jhalterman/failsafe
src/main/java/net/jodah/failsafe/PolicyExecutor.java
PolicyExecutor.postExecuteAsync
protected CompletableFuture<ExecutionResult> postExecuteAsync(ExecutionResult result, Scheduler scheduler, FailsafeFuture<Object> future) { if (isFailure(result)) { result = result.with(false, false); return onFailureAsync(result, scheduler, future).whenComplete((postResult, error) -> { ca...
java
protected CompletableFuture<ExecutionResult> postExecuteAsync(ExecutionResult result, Scheduler scheduler, FailsafeFuture<Object> future) { if (isFailure(result)) { result = result.with(false, false); return onFailureAsync(result, scheduler, future).whenComplete((postResult, error) -> { ca...
[ "protected", "CompletableFuture", "<", "ExecutionResult", ">", "postExecuteAsync", "(", "ExecutionResult", "result", ",", "Scheduler", "scheduler", ",", "FailsafeFuture", "<", "Object", ">", "future", ")", "{", "if", "(", "isFailure", "(", "result", ")", ")", "{...
Performs potentially asynchronous post-execution handling for a {@code result}.
[ "Performs", "potentially", "asynchronous", "post", "-", "execution", "handling", "for", "a", "{" ]
train
https://github.com/jhalterman/failsafe/blob/65fcd3a82f7b232d2ff59bc525a59d693dd8e223/src/main/java/net/jodah/failsafe/PolicyExecutor.java#L95-L108
Jasig/uPortal
uPortal-groups/uPortal-groups-core/src/main/java/org/apereo/portal/groups/ReferenceIndividualGroupService.java
ReferenceIndividualGroupService.updateGroup
@Override public void updateGroup(ILockableEntityGroup group, boolean renewLock) throws GroupsException { throwExceptionIfNotInternallyManaged(); try { if (!group.getLock().isValid()) { throw new GroupsException( "Could not update group " + group....
java
@Override public void updateGroup(ILockableEntityGroup group, boolean renewLock) throws GroupsException { throwExceptionIfNotInternallyManaged(); try { if (!group.getLock().isValid()) { throw new GroupsException( "Could not update group " + group....
[ "@", "Override", "public", "void", "updateGroup", "(", "ILockableEntityGroup", "group", ",", "boolean", "renewLock", ")", "throws", "GroupsException", "{", "throwExceptionIfNotInternallyManaged", "(", ")", ";", "try", "{", "if", "(", "!", "group", ".", "getLock", ...
Updates the <code>ILockableEntityGroup</code> in the store and removes it from the cache. @param group ILockableEntityGroup
[ "Updates", "the", "<code", ">", "ILockableEntityGroup<", "/", "code", ">", "in", "the", "store", "and", "removes", "it", "from", "the", "cache", "." ]
train
https://github.com/Jasig/uPortal/blob/c1986542abb9acd214268f2df21c6305ad2f262b/uPortal-groups/uPortal-groups-core/src/main/java/org/apereo/portal/groups/ReferenceIndividualGroupService.java#L613-L639
apache/reef
lang/java/reef-applications/reef-vortex/src/main/java/org/apache/reef/vortex/driver/RunningWorkers.java
RunningWorkers.cancelTasklet
void cancelTasklet(final boolean mayInterruptIfRunning, final int taskletId) { lock.lock(); try { // This is not ideal since we are using a linear time search on all the workers. final String workerId = getWhereTaskletWasScheduledTo(taskletId); if (workerId == null) { // launchTasklet ...
java
void cancelTasklet(final boolean mayInterruptIfRunning, final int taskletId) { lock.lock(); try { // This is not ideal since we are using a linear time search on all the workers. final String workerId = getWhereTaskletWasScheduledTo(taskletId); if (workerId == null) { // launchTasklet ...
[ "void", "cancelTasklet", "(", "final", "boolean", "mayInterruptIfRunning", ",", "final", "int", "taskletId", ")", "{", "lock", ".", "lock", "(", ")", ";", "try", "{", "// This is not ideal since we are using a linear time search on all the workers.", "final", "String", ...
Concurrency: Called by multiple threads. Parameter: Same taskletId can come in multiple times.
[ "Concurrency", ":", "Called", "by", "multiple", "threads", ".", "Parameter", ":", "Same", "taskletId", "can", "come", "in", "multiple", "times", "." ]
train
https://github.com/apache/reef/blob/e2c47121cde21108a602c560cf76565a40d0e916/lang/java/reef-applications/reef-vortex/src/main/java/org/apache/reef/vortex/driver/RunningWorkers.java#L186-L204
m-m-m/util
nls/src/main/java/net/sf/mmm/util/nls/base/AbstractNlsBundleFactory.java
AbstractNlsBundleFactory.createHandler
protected InvocationHandler createHandler(Class<? extends NlsBundle> bundleInterface) { String bundleName = NlsBundleHelper.getInstance().getQualifiedLocation(bundleInterface); NlsBundleOptions options = getBundleOptions(bundleInterface); return new NlsBundleInvocationHandler(bundleInterface, bundleName, o...
java
protected InvocationHandler createHandler(Class<? extends NlsBundle> bundleInterface) { String bundleName = NlsBundleHelper.getInstance().getQualifiedLocation(bundleInterface); NlsBundleOptions options = getBundleOptions(bundleInterface); return new NlsBundleInvocationHandler(bundleInterface, bundleName, o...
[ "protected", "InvocationHandler", "createHandler", "(", "Class", "<", "?", "extends", "NlsBundle", ">", "bundleInterface", ")", "{", "String", "bundleName", "=", "NlsBundleHelper", ".", "getInstance", "(", ")", ".", "getQualifiedLocation", "(", "bundleInterface", ")...
This method creates a new {@link InvocationHandler} for the given {@code bundleInterface}. @param bundleInterface is the {@link Class} reflecting the {@link NlsBundle} interface. @return the {@link InvocationHandler} for the given {@code bundleInterface}.
[ "This", "method", "creates", "a", "new", "{", "@link", "InvocationHandler", "}", "for", "the", "given", "{", "@code", "bundleInterface", "}", "." ]
train
https://github.com/m-m-m/util/blob/f0e4e084448f8dfc83ca682a9e1618034a094ce6/nls/src/main/java/net/sf/mmm/util/nls/base/AbstractNlsBundleFactory.java#L186-L191
i-net-software/jlessc
src/com/inet/lib/less/UrlUtils.java
UrlUtils.dataUri
static void dataUri( CssFormatter formatter, String relativeUrlStr, final String urlString, String type ) throws IOException { String urlStr = removeQuote( urlString ); InputStream input; try { input = formatter.getReaderFactory().openStream( formatter.getBaseURL(), urlStr, relativeU...
java
static void dataUri( CssFormatter formatter, String relativeUrlStr, final String urlString, String type ) throws IOException { String urlStr = removeQuote( urlString ); InputStream input; try { input = formatter.getReaderFactory().openStream( formatter.getBaseURL(), urlStr, relativeU...
[ "static", "void", "dataUri", "(", "CssFormatter", "formatter", ",", "String", "relativeUrlStr", ",", "final", "String", "urlString", ",", "String", "type", ")", "throws", "IOException", "{", "String", "urlStr", "=", "removeQuote", "(", "urlString", ")", ";", "...
Implementation of the function data-uri. @param formatter current formatter @param relativeUrlStr relative URL of the less script. Is used as base URL @param urlString the url parameter of the function @param type the mime type @throws IOException If any I/O errors occur on reading the content
[ "Implementation", "of", "the", "function", "data", "-", "uri", "." ]
train
https://github.com/i-net-software/jlessc/blob/15b13e1637f6cc2e4d72df021e23ee0ca8d5e629/src/com/inet/lib/less/UrlUtils.java#L171-L207
mikepenz/FastAdapter
app/src/main/java/com/mikepenz/fastadapter/app/items/ImageItem.java
ImageItem.animateHeart
public void animateHeart(View imageLovedOn, View imageLovedOff, boolean on) { imageLovedOn.setVisibility(View.VISIBLE); imageLovedOff.setVisibility(View.VISIBLE); if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB_MR1) { viewPropertyStartCompat(imageLovedOff.animate().scaleX...
java
public void animateHeart(View imageLovedOn, View imageLovedOff, boolean on) { imageLovedOn.setVisibility(View.VISIBLE); imageLovedOff.setVisibility(View.VISIBLE); if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB_MR1) { viewPropertyStartCompat(imageLovedOff.animate().scaleX...
[ "public", "void", "animateHeart", "(", "View", "imageLovedOn", ",", "View", "imageLovedOff", ",", "boolean", "on", ")", "{", "imageLovedOn", ".", "setVisibility", "(", "View", ".", "VISIBLE", ")", ";", "imageLovedOff", ".", "setVisibility", "(", "View", ".", ...
helper method to animate the heart view @param imageLovedOn @param imageLovedOff @param on
[ "helper", "method", "to", "animate", "the", "heart", "view" ]
train
https://github.com/mikepenz/FastAdapter/blob/3b2412abe001ba58422e0125846b704d4dba4ae9/app/src/main/java/com/mikepenz/fastadapter/app/items/ImageItem.java#L136-L144
alkacon/opencms-core
src/org/opencms/util/CmsHtmlStripper.java
CmsHtmlStripper.addPreserveTags
public void addPreserveTags(final String tagList, final char separator) { List<String> tags = CmsStringUtil.splitAsList(tagList, separator, true); addPreserveTagList(tags); }
java
public void addPreserveTags(final String tagList, final char separator) { List<String> tags = CmsStringUtil.splitAsList(tagList, separator, true); addPreserveTagList(tags); }
[ "public", "void", "addPreserveTags", "(", "final", "String", "tagList", ",", "final", "char", "separator", ")", "{", "List", "<", "String", ">", "tags", "=", "CmsStringUtil", ".", "splitAsList", "(", "tagList", ",", "separator", ",", "true", ")", ";", "add...
Convenience method for adding several tags to preserve in form of a delimiter-separated String.<p> The String will be <code>{@link CmsStringUtil#splitAsList(String, char, boolean)}</code> with <code>tagList</code> as the first argument, <code>separator</code> as the second argument and the third argument set to true (...
[ "Convenience", "method", "for", "adding", "several", "tags", "to", "preserve", "in", "form", "of", "a", "delimiter", "-", "separated", "String", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/util/CmsHtmlStripper.java#L140-L144
konmik/nucleus
nucleus/src/main/java/nucleus/view/NucleusLayout.java
NucleusLayout.getActivity
public Activity getActivity() { Context context = getContext(); while (!(context instanceof Activity) && context instanceof ContextWrapper) context = ((ContextWrapper) context).getBaseContext(); if (!(context instanceof Activity)) throw new IllegalStateException("Expected...
java
public Activity getActivity() { Context context = getContext(); while (!(context instanceof Activity) && context instanceof ContextWrapper) context = ((ContextWrapper) context).getBaseContext(); if (!(context instanceof Activity)) throw new IllegalStateException("Expected...
[ "public", "Activity", "getActivity", "(", ")", "{", "Context", "context", "=", "getContext", "(", ")", ";", "while", "(", "!", "(", "context", "instanceof", "Activity", ")", "&&", "context", "instanceof", "ContextWrapper", ")", "context", "=", "(", "(", "C...
Returns the unwrapped activity of the view or throws an exception. @return an unwrapped activity
[ "Returns", "the", "unwrapped", "activity", "of", "the", "view", "or", "throws", "an", "exception", "." ]
train
https://github.com/konmik/nucleus/blob/b161484a2bbf66a7896a8c1f61fa7187856ca5f7/nucleus/src/main/java/nucleus/view/NucleusLayout.java#L76-L83
micronaut-projects/micronaut-core
inject/src/main/java/io/micronaut/inject/annotation/AnnotationMetadataSupport.java
AnnotationMetadataSupport.registerDefaultValues
static void registerDefaultValues(String annotation, Map<String, Object> defaultValues) { if (StringUtils.isNotEmpty(annotation)) { ANNOTATION_DEFAULTS.put(annotation.intern(), defaultValues); } }
java
static void registerDefaultValues(String annotation, Map<String, Object> defaultValues) { if (StringUtils.isNotEmpty(annotation)) { ANNOTATION_DEFAULTS.put(annotation.intern(), defaultValues); } }
[ "static", "void", "registerDefaultValues", "(", "String", "annotation", ",", "Map", "<", "String", ",", "Object", ">", "defaultValues", ")", "{", "if", "(", "StringUtils", ".", "isNotEmpty", "(", "annotation", ")", ")", "{", "ANNOTATION_DEFAULTS", ".", "put", ...
Registers default values for the given annotation and values. @param annotation The annotation @param defaultValues The default values
[ "Registers", "default", "values", "for", "the", "given", "annotation", "and", "values", "." ]
train
https://github.com/micronaut-projects/micronaut-core/blob/c31f5b03ce0eb88c2f6470710987db03b8967d5c/inject/src/main/java/io/micronaut/inject/annotation/AnnotationMetadataSupport.java#L166-L170
Azure/azure-sdk-for-java
batch/data-plane/src/main/java/com/microsoft/azure/batch/PoolOperations.java
PoolOperations.enableAutoScale
public void enableAutoScale(String poolId, String autoScaleFormula) throws BatchErrorException, IOException { enableAutoScale(poolId, autoScaleFormula, null, null); }
java
public void enableAutoScale(String poolId, String autoScaleFormula) throws BatchErrorException, IOException { enableAutoScale(poolId, autoScaleFormula, null, null); }
[ "public", "void", "enableAutoScale", "(", "String", "poolId", ",", "String", "autoScaleFormula", ")", "throws", "BatchErrorException", ",", "IOException", "{", "enableAutoScale", "(", "poolId", ",", "autoScaleFormula", ",", "null", ",", "null", ")", ";", "}" ]
Enables automatic scaling on the specified pool. @param poolId The ID of the pool. @param autoScaleFormula The formula for the desired number of compute nodes in the pool. @throws BatchErrorException Exception thrown when an error response is received from the Batch service. @throws IOException Exception thrown when t...
[ "Enables", "automatic", "scaling", "on", "the", "specified", "pool", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/batch/data-plane/src/main/java/com/microsoft/azure/batch/PoolOperations.java#L690-L692
looly/hutool
hutool-core/src/main/java/cn/hutool/core/io/FileUtil.java
FileUtil.writeUtf8String
public static File writeUtf8String(String content, File file) throws IORuntimeException { return writeString(content, file, CharsetUtil.CHARSET_UTF_8); }
java
public static File writeUtf8String(String content, File file) throws IORuntimeException { return writeString(content, file, CharsetUtil.CHARSET_UTF_8); }
[ "public", "static", "File", "writeUtf8String", "(", "String", "content", ",", "File", "file", ")", "throws", "IORuntimeException", "{", "return", "writeString", "(", "content", ",", "file", ",", "CharsetUtil", ".", "CHARSET_UTF_8", ")", ";", "}" ]
将String写入文件,覆盖模式,字符集为UTF-8 @param content 写入的内容 @param file 文件 @return 写入的文件 @throws IORuntimeException IO异常
[ "将String写入文件,覆盖模式,字符集为UTF", "-", "8" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/io/FileUtil.java#L2707-L2709
FudanNLP/fnlp
fnlp-core/src/main/java/org/fnlp/nlp/cn/tag/AbstractTagger.java
AbstractTagger.tagFile
public void tagFile(String input,String output,String sep){ String s = tagFile(input,"\n"); try { OutputStreamWriter writer = new OutputStreamWriter(new FileOutputStream( output), "utf-8"); BufferedWriter bw = new BufferedWriter(writer); bw.write(s); bw.close(); } catch (Exception e) { ...
java
public void tagFile(String input,String output,String sep){ String s = tagFile(input,"\n"); try { OutputStreamWriter writer = new OutputStreamWriter(new FileOutputStream( output), "utf-8"); BufferedWriter bw = new BufferedWriter(writer); bw.write(s); bw.close(); } catch (Exception e) { ...
[ "public", "void", "tagFile", "(", "String", "input", ",", "String", "output", ",", "String", "sep", ")", "{", "String", "s", "=", "tagFile", "(", "input", ",", "\"\\n\"", ")", ";", "try", "{", "OutputStreamWriter", "writer", "=", "new", "OutputStreamWriter...
序列标注方法,输入输出为文件 @param input 输入文件 UTF8编码 @param output 输出文件 UTF8编码
[ "序列标注方法,输入输出为文件" ]
train
https://github.com/FudanNLP/fnlp/blob/ce258f3e4a5add2ba0b5e4cbac7cab2190af6659/fnlp-core/src/main/java/org/fnlp/nlp/cn/tag/AbstractTagger.java#L126-L138