repository_name
stringlengths
7
58
func_path_in_repository
stringlengths
18
192
func_name
stringlengths
5
108
whole_func_string
stringlengths
75
3.91k
language
stringclasses
1 value
func_code_string
stringlengths
75
3.91k
func_code_tokens
listlengths
21
629
func_documentation_string
stringlengths
61
1.98k
func_documentation_tokens
listlengths
1
647
split_name
stringclasses
1 value
func_code_url
stringlengths
111
306
j-a-w-r/jawr-main-repo
jawr/jawr-core/src/main/java/net/jawr/web/resource/bundle/postprocess/BundleProcessingStatus.java
BundleProcessingStatus.addPostProcessVariant
public void addPostProcessVariant(String variantType, VariantSet variantSet) { Map<String, VariantSet> variantMap = new HashMap<>(); variantMap.put(variantType, variantSet); addPostProcessVariant(variantMap); }
java
public void addPostProcessVariant(String variantType, VariantSet variantSet) { Map<String, VariantSet> variantMap = new HashMap<>(); variantMap.put(variantType, variantSet); addPostProcessVariant(variantMap); }
[ "public", "void", "addPostProcessVariant", "(", "String", "variantType", ",", "VariantSet", "variantSet", ")", "{", "Map", "<", "String", ",", "VariantSet", ">", "variantMap", "=", "new", "HashMap", "<>", "(", ")", ";", "variantMap", ".", "put", "(", "varian...
Add a post process variant @param variantType the variant type @param variantSet the variant set
[ "Add", "a", "post", "process", "variant" ]
train
https://github.com/j-a-w-r/jawr-main-repo/blob/5381f6acf461cd2502593c67a77bd6ef9eab848d/jawr/jawr-core/src/main/java/net/jawr/web/resource/bundle/postprocess/BundleProcessingStatus.java#L245-L250
Azure/azure-sdk-for-java
sql/resource-manager/v2014_04_01/src/main/java/com/microsoft/azure/management/sql/v2014_04_01/implementation/ElasticPoolsInner.java
ElasticPoolsInner.getAsync
public Observable<ElasticPoolInner> getAsync(String resourceGroupName, String serverName, String elasticPoolName) { return getWithServiceResponseAsync(resourceGroupName, serverName, elasticPoolName).map(new Func1<ServiceResponse<ElasticPoolInner>, ElasticPoolInner>() { @Override public E...
java
public Observable<ElasticPoolInner> getAsync(String resourceGroupName, String serverName, String elasticPoolName) { return getWithServiceResponseAsync(resourceGroupName, serverName, elasticPoolName).map(new Func1<ServiceResponse<ElasticPoolInner>, ElasticPoolInner>() { @Override public E...
[ "public", "Observable", "<", "ElasticPoolInner", ">", "getAsync", "(", "String", "resourceGroupName", ",", "String", "serverName", ",", "String", "elasticPoolName", ")", "{", "return", "getWithServiceResponseAsync", "(", "resourceGroupName", ",", "serverName", ",", "e...
Gets an elastic pool. @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. @param serverName The name of the server. @param elasticPoolName The name of the elastic pool to be retrieved. @throws IllegalArgumentEx...
[ "Gets", "an", "elastic", "pool", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/sql/resource-manager/v2014_04_01/src/main/java/com/microsoft/azure/management/sql/v2014_04_01/implementation/ElasticPoolsInner.java#L603-L610
lukas-krecan/completion-stage
src/main/java/net/javacrumbs/completionstage/CompletionStageFactory.java
CompletionStageFactory.supplyAsync
public final <U> CompletionStage<U> supplyAsync(Supplier<U> supplier) { return supplyAsync(supplier, defaultAsyncExecutor); }
java
public final <U> CompletionStage<U> supplyAsync(Supplier<U> supplier) { return supplyAsync(supplier, defaultAsyncExecutor); }
[ "public", "final", "<", "U", ">", "CompletionStage", "<", "U", ">", "supplyAsync", "(", "Supplier", "<", "U", ">", "supplier", ")", "{", "return", "supplyAsync", "(", "supplier", ",", "defaultAsyncExecutor", ")", ";", "}" ]
Returns a new CompletionStage that is asynchronously completed by a task running in the defaultAsyncExecutor with the value obtained by calling the given Supplier. @param supplier a function returning the value to be used to complete the returned CompletionStage @param <U> the function's return type @return the new Co...
[ "Returns", "a", "new", "CompletionStage", "that", "is", "asynchronously", "completed", "by", "a", "task", "running", "in", "the", "defaultAsyncExecutor", "with", "the", "value", "obtained", "by", "calling", "the", "given", "Supplier", "." ]
train
https://github.com/lukas-krecan/completion-stage/blob/9c270d779b5fc98dc958a5fb335f6e2ad9d06962/src/main/java/net/javacrumbs/completionstage/CompletionStageFactory.java#L72-L74
gwtbootstrap3/gwtbootstrap3-extras
src/main/java/org/gwtbootstrap3/extras/typeahead/client/ui/Typeahead.java
Typeahead.onCursorChanged
private void onCursorChanged(final Event event, final Suggestion<T> suggestion) { TypeaheadCursorChangedEvent.fire(this, suggestion, event); }
java
private void onCursorChanged(final Event event, final Suggestion<T> suggestion) { TypeaheadCursorChangedEvent.fire(this, suggestion, event); }
[ "private", "void", "onCursorChanged", "(", "final", "Event", "event", ",", "final", "Suggestion", "<", "T", ">", "suggestion", ")", "{", "TypeaheadCursorChangedEvent", ".", "fire", "(", "this", ",", "suggestion", ",", "event", ")", ";", "}" ]
Triggered when the dropdown menu cursor is moved to a different suggestion. @param event the event @param suggestion the suggestion object
[ "Triggered", "when", "the", "dropdown", "menu", "cursor", "is", "moved", "to", "a", "different", "suggestion", "." ]
train
https://github.com/gwtbootstrap3/gwtbootstrap3-extras/blob/8e42aaffd2a082e9cb23a14c37a3c87b7cbdfa94/src/main/java/org/gwtbootstrap3/extras/typeahead/client/ui/Typeahead.java#L180-L182
Samsung/GearVRf
GVRf/Framework/framework/src/main/java/org/gearvrf/GVRJassimpAdapter.java
GVRJassimpAdapter.fixKeys
private void fixKeys(GVRAnimationChannel channel, Vector3f scaleFactor) { float[] temp = new float[3]; for (int i = 0; i < channel.getNumPosKeys(); ++i) { float time = (float) channel.getPosKeyTime(i); channel.getPosKeyVector(i, temp); temp[0] *= scaleFact...
java
private void fixKeys(GVRAnimationChannel channel, Vector3f scaleFactor) { float[] temp = new float[3]; for (int i = 0; i < channel.getNumPosKeys(); ++i) { float time = (float) channel.getPosKeyTime(i); channel.getPosKeyVector(i, temp); temp[0] *= scaleFact...
[ "private", "void", "fixKeys", "(", "GVRAnimationChannel", "channel", ",", "Vector3f", "scaleFactor", ")", "{", "float", "[", "]", "temp", "=", "new", "float", "[", "3", "]", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", "channel", ".", "getNu...
/* Some FBX files are exported as centimeters. Assimp does not correctly compute the scale keys. They should include the scaling from the bind pose since the animations are NOT relative to the bind pose.
[ "/", "*", "Some", "FBX", "files", "are", "exported", "as", "centimeters", ".", "Assimp", "does", "not", "correctly", "compute", "the", "scale", "keys", ".", "They", "should", "include", "the", "scaling", "from", "the", "bind", "pose", "since", "the", "anim...
train
https://github.com/Samsung/GearVRf/blob/05034d465a7b0a494fabb9e9f2971ac19392f32d/GVRf/Framework/framework/src/main/java/org/gearvrf/GVRJassimpAdapter.java#L647-L668
pgjdbc/pgjdbc
pgjdbc/src/main/java/org/postgresql/core/v3/QueryExecutorImpl.java
QueryExecutorImpl.startCopy
public synchronized CopyOperation startCopy(String sql, boolean suppressBegin) throws SQLException { waitOnLock(); if (!suppressBegin) { doSubprotocolBegin(); } byte[] buf = Utils.encodeUTF8(sql); try { LOGGER.log(Level.FINEST, " FE=> Query(CopyStart)"); pgStream.sendChar('...
java
public synchronized CopyOperation startCopy(String sql, boolean suppressBegin) throws SQLException { waitOnLock(); if (!suppressBegin) { doSubprotocolBegin(); } byte[] buf = Utils.encodeUTF8(sql); try { LOGGER.log(Level.FINEST, " FE=> Query(CopyStart)"); pgStream.sendChar('...
[ "public", "synchronized", "CopyOperation", "startCopy", "(", "String", "sql", ",", "boolean", "suppressBegin", ")", "throws", "SQLException", "{", "waitOnLock", "(", ")", ";", "if", "(", "!", "suppressBegin", ")", "{", "doSubprotocolBegin", "(", ")", ";", "}",...
Sends given query to BE to start, initialize and lock connection for a CopyOperation. @param sql COPY FROM STDIN / COPY TO STDOUT statement @return CopyIn or CopyOut operation object @throws SQLException on failure
[ "Sends", "given", "query", "to", "BE", "to", "start", "initialize", "and", "lock", "connection", "for", "a", "CopyOperation", "." ]
train
https://github.com/pgjdbc/pgjdbc/blob/95ba7b261e39754674c5817695ae5ebf9a341fae/pgjdbc/src/main/java/org/postgresql/core/v3/QueryExecutorImpl.java#L853-L876
alkacon/opencms-core
src-setup/org/opencms/setup/CmsSetupBean.java
CmsSetupBean.setStartView
public void setStartView(String userName, String view) throws CmsException { try { CmsUser user = m_cms.readUser(userName); user.getAdditionalInfo().put( CmsUserSettings.PREFERENCES + CmsWorkplaceConfiguration.N_WORKPLACESTARTUPSETTINGS ...
java
public void setStartView(String userName, String view) throws CmsException { try { CmsUser user = m_cms.readUser(userName); user.getAdditionalInfo().put( CmsUserSettings.PREFERENCES + CmsWorkplaceConfiguration.N_WORKPLACESTARTUPSETTINGS ...
[ "public", "void", "setStartView", "(", "String", "userName", ",", "String", "view", ")", "throws", "CmsException", "{", "try", "{", "CmsUser", "user", "=", "m_cms", ".", "readUser", "(", "userName", ")", ";", "user", ".", "getAdditionalInfo", "(", ")", "."...
Sets the start view for the given user.<p> @param userName the name of the user @param view the start view path @throws CmsException if something goes wrong
[ "Sets", "the", "start", "view", "for", "the", "given", "user", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src-setup/org/opencms/setup/CmsSetupBean.java#L2235-L2250
fuinorg/utils4j
src/main/java/org/fuin/utils4j/JandexUtils.java
JandexUtils.indexClasspath
public static void indexClasspath(final URLClassLoader classLoader, final Indexer indexer, final List<File> knownFiles) { // Variant that works with Maven "exec:java" final List<File> classPathFiles = Utils4J.localFilesFromUrlClassLoader(classLoader); for (final File file : classPathFiles) { ...
java
public static void indexClasspath(final URLClassLoader classLoader, final Indexer indexer, final List<File> knownFiles) { // Variant that works with Maven "exec:java" final List<File> classPathFiles = Utils4J.localFilesFromUrlClassLoader(classLoader); for (final File file : classPathFiles) { ...
[ "public", "static", "void", "indexClasspath", "(", "final", "URLClassLoader", "classLoader", ",", "final", "Indexer", "indexer", ",", "final", "List", "<", "File", ">", "knownFiles", ")", "{", "// Variant that works with Maven \"exec:java\"", "final", "List", "<", "...
Indexes all classes in the classpath (*.jar or *.class). @param classLoader Class loader to use. @param indexer Indexer to use. @param knownFiles List of files already analyzed. New files will be added within this method.
[ "Indexes", "all", "classes", "in", "the", "classpath", "(", "*", ".", "jar", "or", "*", ".", "class", ")", "." ]
train
https://github.com/fuinorg/utils4j/blob/71cf88e0a8d8ed67bbac513bf3cab165cd7e3280/src/main/java/org/fuin/utils4j/JandexUtils.java#L137-L157
esigate/esigate
esigate-core/src/main/java/org/esigate/http/HttpResponseUtils.java
HttpResponseUtils.writeTo
public static void writeTo(final HttpEntity httpEntity, final OutputStream outstream) throws IOException { Args.notNull(outstream, "Output stream"); try (InputStream instream = httpEntity.getContent()) { final byte[] buffer = new byte[OUTPUT_BUFFER_SIZE]; int l; if (h...
java
public static void writeTo(final HttpEntity httpEntity, final OutputStream outstream) throws IOException { Args.notNull(outstream, "Output stream"); try (InputStream instream = httpEntity.getContent()) { final byte[] buffer = new byte[OUTPUT_BUFFER_SIZE]; int l; if (h...
[ "public", "static", "void", "writeTo", "(", "final", "HttpEntity", "httpEntity", ",", "final", "OutputStream", "outstream", ")", "throws", "IOException", "{", "Args", ".", "notNull", "(", "outstream", ",", "\"Output stream\"", ")", ";", "try", "(", "InputStream"...
Copied from org.apache.http.entity.InputStreamEntity.writeTo(OutputStream) method but flushes the buffer after each read in order to allow streaming and web sockets. @param httpEntity The entity to copy to the OutputStream @param outstream The OutputStream @throws IOException If a problem occurs
[ "Copied", "from", "org", ".", "apache", ".", "http", ".", "entity", ".", "InputStreamEntity", ".", "writeTo", "(", "OutputStream", ")", "method", "but", "flushes", "the", "buffer", "after", "each", "read", "in", "order", "to", "allow", "streaming", "and", ...
train
https://github.com/esigate/esigate/blob/50421fb224f16e1ec42715425109a72b3b55527b/esigate-core/src/main/java/org/esigate/http/HttpResponseUtils.java#L237-L264
carewebframework/carewebframework-core
org.carewebframework.shell/src/main/java/org/carewebframework/shell/elements/ElementPlugin.java
ElementPlugin.tryRegisterListener
public boolean tryRegisterListener(Object object, boolean register) { boolean success = false; if (object instanceof IPluginEvent) { if (register) { registerListener((IPluginEvent) object); } else { unregisterListener((IPluginEvent) object); ...
java
public boolean tryRegisterListener(Object object, boolean register) { boolean success = false; if (object instanceof IPluginEvent) { if (register) { registerListener((IPluginEvent) object); } else { unregisterListener((IPluginEvent) object); ...
[ "public", "boolean", "tryRegisterListener", "(", "Object", "object", ",", "boolean", "register", ")", "{", "boolean", "success", "=", "false", ";", "if", "(", "object", "instanceof", "IPluginEvent", ")", "{", "if", "(", "register", ")", "{", "registerListener"...
Attempts to register or unregister an object as an event listener. @param object Object to register/unregister. @param register If true, we are attempting to register. If false, unregister. @return True if operation was successful. False if the object supports none of the recognized event listeners.
[ "Attempts", "to", "register", "or", "unregister", "an", "object", "as", "an", "event", "listener", "." ]
train
https://github.com/carewebframework/carewebframework-core/blob/fa3252d4f7541dbe151b92c3d4f6f91433cd1673/org.carewebframework.shell/src/main/java/org/carewebframework/shell/elements/ElementPlugin.java#L705-L727
intive-FDV/DynamicJasper
src/main/java/ar/com/fdvs/dj/util/HyperLinkUtil.java
HyperLinkUtil.applyHyperLinkToElement
public static void applyHyperLinkToElement(DynamicJasperDesign design, DJHyperLink djlink, JRDesignChart chart, String name) { JRDesignExpression hlpe = ExpressionUtils.createAndRegisterExpression(design, name, djlink.getExpression()); chart.setHyperlinkReferenceExpression(hlpe); chart.setHyperlinkType( Hyperlink...
java
public static void applyHyperLinkToElement(DynamicJasperDesign design, DJHyperLink djlink, JRDesignChart chart, String name) { JRDesignExpression hlpe = ExpressionUtils.createAndRegisterExpression(design, name, djlink.getExpression()); chart.setHyperlinkReferenceExpression(hlpe); chart.setHyperlinkType( Hyperlink...
[ "public", "static", "void", "applyHyperLinkToElement", "(", "DynamicJasperDesign", "design", ",", "DJHyperLink", "djlink", ",", "JRDesignChart", "chart", ",", "String", "name", ")", "{", "JRDesignExpression", "hlpe", "=", "ExpressionUtils", ".", "createAndRegisterExpres...
Creates necessary objects to make a chart an hyperlink @param design @param djlink @param chart @param name
[ "Creates", "necessary", "objects", "to", "make", "a", "chart", "an", "hyperlink" ]
train
https://github.com/intive-FDV/DynamicJasper/blob/63919574cc401ae40574d13129f628e66d1682a3/src/main/java/ar/com/fdvs/dj/util/HyperLinkUtil.java#L95-L104
google/j2objc
xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/objects/XStringForFSB.java
XStringForFSB.indexOf
public int indexOf(int ch, int fromIndex) { int max = m_start + m_length; FastStringBuffer fsb = fsb(); if (fromIndex < 0) { fromIndex = 0; } else if (fromIndex >= m_length) { // Note: fromIndex might be near -1>>>1. return -1; } for (int i = m_start + fromInd...
java
public int indexOf(int ch, int fromIndex) { int max = m_start + m_length; FastStringBuffer fsb = fsb(); if (fromIndex < 0) { fromIndex = 0; } else if (fromIndex >= m_length) { // Note: fromIndex might be near -1>>>1. return -1; } for (int i = m_start + fromInd...
[ "public", "int", "indexOf", "(", "int", "ch", ",", "int", "fromIndex", ")", "{", "int", "max", "=", "m_start", "+", "m_length", ";", "FastStringBuffer", "fsb", "=", "fsb", "(", ")", ";", "if", "(", "fromIndex", "<", "0", ")", "{", "fromIndex", "=", ...
Returns the index within this string of the first occurrence of the specified character, starting the search at the specified index. <p> If a character with value <code>ch</code> occurs in the character sequence represented by this <code>String</code> object at an index no smaller than <code>fromIndex</code>, then the ...
[ "Returns", "the", "index", "within", "this", "string", "of", "the", "first", "occurrence", "of", "the", "specified", "character", "starting", "the", "search", "at", "the", "specified", "index", ".", "<p", ">", "If", "a", "character", "with", "value", "<code"...
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/objects/XStringForFSB.java#L707-L733
BBN-E/bue-common-open
common-core-open/src/main/java/com/bbn/bue/common/files/FileUtils.java
FileUtils.loadFileListRelativeTo
public static ImmutableList<File> loadFileListRelativeTo(File fileList, File basePath) throws IOException { checkNotNull(basePath); final ImmutableList.Builder<File> ret = ImmutableList.builder(); for (final String filename : Files.readLines(fileList, Charsets.UTF_8)) { if (!filename.isEmpty() ...
java
public static ImmutableList<File> loadFileListRelativeTo(File fileList, File basePath) throws IOException { checkNotNull(basePath); final ImmutableList.Builder<File> ret = ImmutableList.builder(); for (final String filename : Files.readLines(fileList, Charsets.UTF_8)) { if (!filename.isEmpty() ...
[ "public", "static", "ImmutableList", "<", "File", ">", "loadFileListRelativeTo", "(", "File", "fileList", ",", "File", "basePath", ")", "throws", "IOException", "{", "checkNotNull", "(", "basePath", ")", ";", "final", "ImmutableList", ".", "Builder", "<", "File"...
Takes a file with relative pathnames listed one per line and returns a list of the corresponding {@link java.io.File} objects, resolved against the provided base path using the {@link java.io.File#File(java.io.File, String)} constructor. Ignores blank lines and lines beginning with "#".
[ "Takes", "a", "file", "with", "relative", "pathnames", "listed", "one", "per", "line", "and", "returns", "a", "list", "of", "the", "corresponding", "{" ]
train
https://github.com/BBN-E/bue-common-open/blob/d618652674d647867306e2e4b987a21b7c29c015/common-core-open/src/main/java/com/bbn/bue/common/files/FileUtils.java#L170-L182
lessthanoptimal/BoofCV
main/boofcv-geo/src/main/java/boofcv/alg/geo/pose/Relinearlize.java
Relinearlize.process
public void process( DMatrixRMaj L_full , DMatrixRMaj y , double betas[] ) { svd.decompose(L_full); // extract null space V = svd.getV(null,true); // compute one possible solution pseudo.setA(L_full); pseudo.solve(y,x0); // add additional constraints to reduce the number of possible solutions DMatri...
java
public void process( DMatrixRMaj L_full , DMatrixRMaj y , double betas[] ) { svd.decompose(L_full); // extract null space V = svd.getV(null,true); // compute one possible solution pseudo.setA(L_full); pseudo.solve(y,x0); // add additional constraints to reduce the number of possible solutions DMatri...
[ "public", "void", "process", "(", "DMatrixRMaj", "L_full", ",", "DMatrixRMaj", "y", ",", "double", "betas", "[", "]", ")", "{", "svd", ".", "decompose", "(", "L_full", ")", ";", "// extract null space", "V", "=", "svd", ".", "getV", "(", "null", ",", "...
Estimates betas using relinearization. @param L_full Linear constraint matrix @param y distances between world control points @param betas Estimated betas. Output.
[ "Estimates", "betas", "using", "relinearization", "." ]
train
https://github.com/lessthanoptimal/BoofCV/blob/f01c0243da0ec086285ee722183804d5923bc3ac/main/boofcv-geo/src/main/java/boofcv/alg/geo/pose/Relinearlize.java#L110-L141
classgraph/classgraph
src/main/java/io/github/classgraph/Classfile.java
Classfile.readAnnotation
private AnnotationInfo readAnnotation() throws IOException { // Lcom/xyz/Annotation; -> Lcom.xyz.Annotation; final String annotationClassName = getConstantPoolClassDescriptor( inputStreamOrByteBuffer.readUnsignedShort()); final int numElementValuePairs = inputStreamOrByteBuffer.r...
java
private AnnotationInfo readAnnotation() throws IOException { // Lcom/xyz/Annotation; -> Lcom.xyz.Annotation; final String annotationClassName = getConstantPoolClassDescriptor( inputStreamOrByteBuffer.readUnsignedShort()); final int numElementValuePairs = inputStreamOrByteBuffer.r...
[ "private", "AnnotationInfo", "readAnnotation", "(", ")", "throws", "IOException", "{", "// Lcom/xyz/Annotation; -> Lcom.xyz.Annotation;", "final", "String", "annotationClassName", "=", "getConstantPoolClassDescriptor", "(", "inputStreamOrByteBuffer", ".", "readUnsignedShort", "("...
Read annotation entry from classfile. @return the annotation, as an {@link AnnotationInfo} object. @throws IOException If an IO exception occurs.
[ "Read", "annotation", "entry", "from", "classfile", "." ]
train
https://github.com/classgraph/classgraph/blob/c8c8b2ca1eb76339f69193fdac33d735c864215c/src/main/java/io/github/classgraph/Classfile.java#L807-L822
h2oai/h2o-2
src/main/java/water/Model.java
Model.toJavaPredict
private SB toJavaPredict(SB ccsb, SB fileCtxSb) { // ccsb = classContext ccsb.nl(); ccsb.p(" // Pass in data in a double[], pre-aligned to the Model's requirements.").nl(); ccsb.p(" // Jam predictions into the preds[] array; preds[0] is reserved for the").nl(); ccsb.p(" // main prediction (class for ...
java
private SB toJavaPredict(SB ccsb, SB fileCtxSb) { // ccsb = classContext ccsb.nl(); ccsb.p(" // Pass in data in a double[], pre-aligned to the Model's requirements.").nl(); ccsb.p(" // Jam predictions into the preds[] array; preds[0] is reserved for the").nl(); ccsb.p(" // main prediction (class for ...
[ "private", "SB", "toJavaPredict", "(", "SB", "ccsb", ",", "SB", "fileCtxSb", ")", "{", "// ccsb = classContext", "ccsb", ".", "nl", "(", ")", ";", "ccsb", ".", "p", "(", "\" // Pass in data in a double[], pre-aligned to the Model's requirements.\"", ")", ".", "nl",...
Wrapper around the main predict call, including the signature and return value
[ "Wrapper", "around", "the", "main", "predict", "call", "including", "the", "signature", "and", "return", "value" ]
train
https://github.com/h2oai/h2o-2/blob/be350f3f2c2fb6f135cc07c41f83fd0e4f521ac1/src/main/java/water/Model.java#L696-L711
spotbugs/spotbugs
spotbugs/src/main/java/edu/umd/cs/findbugs/ba/SignatureConverter.java
SignatureConverter.convertMethodSignature
public static String convertMethodSignature(JavaClass javaClass, Method method) { return convertMethodSignature(javaClass.getClassName(), method.getName(), method.getSignature()); }
java
public static String convertMethodSignature(JavaClass javaClass, Method method) { return convertMethodSignature(javaClass.getClassName(), method.getName(), method.getSignature()); }
[ "public", "static", "String", "convertMethodSignature", "(", "JavaClass", "javaClass", ",", "Method", "method", ")", "{", "return", "convertMethodSignature", "(", "javaClass", ".", "getClassName", "(", ")", ",", "method", ".", "getName", "(", ")", ",", "method",...
Convenience method for generating a method signature in human readable form. @param javaClass the class @param method the method
[ "Convenience", "method", "for", "generating", "a", "method", "signature", "in", "human", "readable", "form", "." ]
train
https://github.com/spotbugs/spotbugs/blob/f6365c6eea6515035bded38efa4a7c8b46ccf28c/spotbugs/src/main/java/edu/umd/cs/findbugs/ba/SignatureConverter.java#L146-L148
haraldk/TwelveMonkeys
sandbox/sandbox-common/src/main/java/com/twelvemonkeys/net/NetUtil.java
NetUtil.getInputStreamHttp
public static InputStream getInputStreamHttp(URL pURL, Properties pProperties, boolean pFollowRedirects, int pTimeout) throws IOException { // Open the connection, and get the stream HttpURLConnection conn = createHttpURLConnection(pURL, pProperties, pFollowRedirects, pTimeout); //...
java
public static InputStream getInputStreamHttp(URL pURL, Properties pProperties, boolean pFollowRedirects, int pTimeout) throws IOException { // Open the connection, and get the stream HttpURLConnection conn = createHttpURLConnection(pURL, pProperties, pFollowRedirects, pTimeout); //...
[ "public", "static", "InputStream", "getInputStreamHttp", "(", "URL", "pURL", ",", "Properties", "pProperties", ",", "boolean", "pFollowRedirects", ",", "int", "pTimeout", ")", "throws", "IOException", "{", "// Open the connection, and get the stream", "HttpURLConnection", ...
Gets the InputStream from a given URL, with the given timeout. The timeout must be > 0. A timeout of zero is interpreted as an infinite timeout. Supports basic HTTP authentication, using a URL string similar to most browsers. <P/> <SMALL>Implementation note: If the timeout parameter is greater than 0, this method uses ...
[ "Gets", "the", "InputStream", "from", "a", "given", "URL", "with", "the", "given", "timeout", ".", "The", "timeout", "must", "be", ">", "0", ".", "A", "timeout", "of", "zero", "is", "interpreted", "as", "an", "infinite", "timeout", ".", "Supports", "basi...
train
https://github.com/haraldk/TwelveMonkeys/blob/7fad4d5cd8cb3a6728c7fd3f28a7b84d8ce0101d/sandbox/sandbox-common/src/main/java/com/twelvemonkeys/net/NetUtil.java#L705-L722
OpenLiberty/open-liberty
dev/com.ibm.ws.microprofile.openapi/src/com/ibm/ws/microprofile/openapi/impl/core/util/ReflectionUtils.java
ReflectionUtils.getAnnotation
public static <A extends Annotation> A getAnnotation(Method method, Class<A> annotationClass) { A annotation = method.getAnnotation(annotationClass); if (annotation == null) { for (Annotation metaAnnotation : method.getAnnotations()) { annotation = metaAnnotation.annotationTy...
java
public static <A extends Annotation> A getAnnotation(Method method, Class<A> annotationClass) { A annotation = method.getAnnotation(annotationClass); if (annotation == null) { for (Annotation metaAnnotation : method.getAnnotations()) { annotation = metaAnnotation.annotationTy...
[ "public", "static", "<", "A", "extends", "Annotation", ">", "A", "getAnnotation", "(", "Method", "method", ",", "Class", "<", "A", ">", "annotationClass", ")", "{", "A", "annotation", "=", "method", ".", "getAnnotation", "(", "annotationClass", ")", ";", "...
Returns an annotation by type from a method. @param method is the method to find @param annotationClass is the type of annotation @param <A> is the type of annotation @return annotation if it is found
[ "Returns", "an", "annotation", "by", "type", "from", "a", "method", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.microprofile.openapi/src/com/ibm/ws/microprofile/openapi/impl/core/util/ReflectionUtils.java#L215-L230
apache/incubator-heron
heron/scheduler-core/src/java/org/apache/heron/scheduler/UpdateTopologyManager.java
UpdateTopologyManager.getTopology
@VisibleForTesting TopologyAPI.Topology getTopology(SchedulerStateManagerAdaptor stateManager, String topologyName) { return stateManager.getPhysicalPlan(topologyName).getTopology(); }
java
@VisibleForTesting TopologyAPI.Topology getTopology(SchedulerStateManagerAdaptor stateManager, String topologyName) { return stateManager.getPhysicalPlan(topologyName).getTopology(); }
[ "@", "VisibleForTesting", "TopologyAPI", ".", "Topology", "getTopology", "(", "SchedulerStateManagerAdaptor", "stateManager", ",", "String", "topologyName", ")", "{", "return", "stateManager", ".", "getPhysicalPlan", "(", "topologyName", ")", ".", "getTopology", "(", ...
Returns the topology. It's key that we get the topology from the physical plan to reflect any state changes since launch. The stateManager.getTopology(name) method returns the topology from the time of submission. See additional commentary in topology.proto and physical_plan.proto.
[ "Returns", "the", "topology", ".", "It", "s", "key", "that", "we", "get", "the", "topology", "from", "the", "physical", "plan", "to", "reflect", "any", "state", "changes", "since", "launch", ".", "The", "stateManager", ".", "getTopology", "(", "name", ")",...
train
https://github.com/apache/incubator-heron/blob/776abe2b5a45b93a0eb957fd65cbc149d901a92a/heron/scheduler-core/src/java/org/apache/heron/scheduler/UpdateTopologyManager.java#L346-L349
hazelcast/hazelcast
hazelcast/src/main/java/com/hazelcast/util/JsonUtil.java
JsonUtil.getInt
public static int getInt(JsonObject object, String field) { final JsonValue value = object.get(field); throwExceptionIfNull(value, field); return value.asInt(); }
java
public static int getInt(JsonObject object, String field) { final JsonValue value = object.get(field); throwExceptionIfNull(value, field); return value.asInt(); }
[ "public", "static", "int", "getInt", "(", "JsonObject", "object", ",", "String", "field", ")", "{", "final", "JsonValue", "value", "=", "object", ".", "get", "(", "field", ")", ";", "throwExceptionIfNull", "(", "value", ",", "field", ")", ";", "return", ...
Returns a field in a Json object as an int. Throws IllegalArgumentException if the field value is null. @param object the Json Object @param field the field in the Json object to return @return the Json field value as an int
[ "Returns", "a", "field", "in", "a", "Json", "object", "as", "an", "int", ".", "Throws", "IllegalArgumentException", "if", "the", "field", "value", "is", "null", "." ]
train
https://github.com/hazelcast/hazelcast/blob/8c4bc10515dbbfb41a33e0302c0caedf3cda1baf/hazelcast/src/main/java/com/hazelcast/util/JsonUtil.java#L45-L49
intendia-oss/rxjava-gwt
src/main/modified/io/reactivex/super/io/reactivex/Completable.java
Completable.unsubscribeOn
@CheckReturnValue @SchedulerSupport(SchedulerSupport.CUSTOM) public final Completable unsubscribeOn(final Scheduler scheduler) { ObjectHelper.requireNonNull(scheduler, "scheduler is null"); return RxJavaPlugins.onAssembly(new CompletableDisposeOn(this, scheduler)); }
java
@CheckReturnValue @SchedulerSupport(SchedulerSupport.CUSTOM) public final Completable unsubscribeOn(final Scheduler scheduler) { ObjectHelper.requireNonNull(scheduler, "scheduler is null"); return RxJavaPlugins.onAssembly(new CompletableDisposeOn(this, scheduler)); }
[ "@", "CheckReturnValue", "@", "SchedulerSupport", "(", "SchedulerSupport", ".", "CUSTOM", ")", "public", "final", "Completable", "unsubscribeOn", "(", "final", "Scheduler", "scheduler", ")", "{", "ObjectHelper", ".", "requireNonNull", "(", "scheduler", ",", "\"sched...
Returns a Completable which makes sure when a subscriber disposes the subscription, the dispose is called on the specified scheduler. <p> <img width="640" height="716" src="https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/Completable.unsubscribeOn.png" alt=""> <dl> <dt><b>Scheduler:</b></dt> <dd>{@code ...
[ "Returns", "a", "Completable", "which", "makes", "sure", "when", "a", "subscriber", "disposes", "the", "subscription", "the", "dispose", "is", "called", "on", "the", "specified", "scheduler", ".", "<p", ">", "<img", "width", "=", "640", "height", "=", "716",...
train
https://github.com/intendia-oss/rxjava-gwt/blob/8d5635b12ce40da99e76b59dc6bfe6fc2fffc1fa/src/main/modified/io/reactivex/super/io/reactivex/Completable.java#L2598-L2603
alkacon/opencms-core
src/org/opencms/ui/apps/A_CmsWorkplaceApp.java
A_CmsWorkplaceApp.addParamToState
public static String addParamToState(String state, String paramName, String value) { return state + PARAM_SEPARATOR + paramName + PARAM_ASSIGN + CmsEncoder.encode(value, CmsEncoder.ENCODING_UTF_8); }
java
public static String addParamToState(String state, String paramName, String value) { return state + PARAM_SEPARATOR + paramName + PARAM_ASSIGN + CmsEncoder.encode(value, CmsEncoder.ENCODING_UTF_8); }
[ "public", "static", "String", "addParamToState", "(", "String", "state", ",", "String", "paramName", ",", "String", "value", ")", "{", "return", "state", "+", "PARAM_SEPARATOR", "+", "paramName", "+", "PARAM_ASSIGN", "+", "CmsEncoder", ".", "encode", "(", "val...
Adds a parameter value to the given state.<p> @param state the state @param paramName the parameter name @param value the parameter value @return the state
[ "Adds", "a", "parameter", "value", "to", "the", "given", "state", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/ui/apps/A_CmsWorkplaceApp.java#L170-L173
inferred/FreeBuilder
src/main/java/org/inferred/freebuilder/processor/source/FunctionalType.java
FunctionalType.functionalTypesAcceptedByMethod
public static List<FunctionalType> functionalTypesAcceptedByMethod( DeclaredType type, String methodName, Elements elements, Types types) { TypeElement typeElement = asElement(type); return methodsOn(typeElement, elements, errorType -> { }) .stream() .filter(method -> met...
java
public static List<FunctionalType> functionalTypesAcceptedByMethod( DeclaredType type, String methodName, Elements elements, Types types) { TypeElement typeElement = asElement(type); return methodsOn(typeElement, elements, errorType -> { }) .stream() .filter(method -> met...
[ "public", "static", "List", "<", "FunctionalType", ">", "functionalTypesAcceptedByMethod", "(", "DeclaredType", "type", ",", "String", "methodName", ",", "Elements", "elements", ",", "Types", "types", ")", "{", "TypeElement", "typeElement", "=", "asElement", "(", ...
Returns the functional types accepted by {@code methodName} on {@code type}.
[ "Returns", "the", "functional", "types", "accepted", "by", "{" ]
train
https://github.com/inferred/FreeBuilder/blob/d5a222f90648aece135da4b971c55a60afe8649c/src/main/java/org/inferred/freebuilder/processor/source/FunctionalType.java#L149-L166
apache/groovy
src/main/java/org/codehaus/groovy/runtime/IOGroovyMethods.java
IOGroovyMethods.writeLine
public static void writeLine(BufferedWriter writer, String line) throws IOException { writer.write(line); writer.newLine(); }
java
public static void writeLine(BufferedWriter writer, String line) throws IOException { writer.write(line); writer.newLine(); }
[ "public", "static", "void", "writeLine", "(", "BufferedWriter", "writer", ",", "String", "line", ")", "throws", "IOException", "{", "writer", ".", "write", "(", "line", ")", ";", "writer", ".", "newLine", "(", ")", ";", "}" ]
Write the text and append a newline (using the platform's line-ending). @param writer a BufferedWriter @param line the line to write @throws IOException if an IOException occurs. @since 1.0
[ "Write", "the", "text", "and", "append", "a", "newline", "(", "using", "the", "platform", "s", "line", "-", "ending", ")", "." ]
train
https://github.com/apache/groovy/blob/71cf20addb611bb8d097a59e395fd20bc7f31772/src/main/java/org/codehaus/groovy/runtime/IOGroovyMethods.java#L925-L928
Azure/azure-sdk-for-java
datalakeanalytics/resource-manager/v2015_10_01_preview/src/main/java/com/microsoft/azure/management/datalakeanalytics/v2015_10_01_preview/implementation/AccountsInner.java
AccountsInner.listStorageAccountsAsync
public Observable<Page<StorageAccountInfoInner>> listStorageAccountsAsync(final String resourceGroupName, final String accountName) { return listStorageAccountsWithServiceResponseAsync(resourceGroupName, accountName) .map(new Func1<ServiceResponse<Page<StorageAccountInfoInner>>, Page<StorageAccountI...
java
public Observable<Page<StorageAccountInfoInner>> listStorageAccountsAsync(final String resourceGroupName, final String accountName) { return listStorageAccountsWithServiceResponseAsync(resourceGroupName, accountName) .map(new Func1<ServiceResponse<Page<StorageAccountInfoInner>>, Page<StorageAccountI...
[ "public", "Observable", "<", "Page", "<", "StorageAccountInfoInner", ">", ">", "listStorageAccountsAsync", "(", "final", "String", "resourceGroupName", ",", "final", "String", "accountName", ")", "{", "return", "listStorageAccountsWithServiceResponseAsync", "(", "resource...
Gets the first page of Azure Storage accounts, if any, linked to the specified Data Lake Analytics account. The response includes a link to the next page, if any. @param resourceGroupName The name of the Azure resource group that contains the Data Lake Analytics account. @param accountName The name of the Data Lake An...
[ "Gets", "the", "first", "page", "of", "Azure", "Storage", "accounts", "if", "any", "linked", "to", "the", "specified", "Data", "Lake", "Analytics", "account", ".", "The", "response", "includes", "a", "link", "to", "the", "next", "page", "if", "any", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/datalakeanalytics/resource-manager/v2015_10_01_preview/src/main/java/com/microsoft/azure/management/datalakeanalytics/v2015_10_01_preview/implementation/AccountsInner.java#L1270-L1278
mapsforge/mapsforge
mapsforge-map/src/main/java/org/mapsforge/map/datastore/MultiMapDataStore.java
MultiMapDataStore.addMapDataStore
public void addMapDataStore(MapDataStore mapDataStore, boolean useStartZoomLevel, boolean useStartPosition) { if (this.mapDatabases.contains(mapDataStore)) { throw new IllegalArgumentException("Duplicate map database"); } this.mapDatabases.add(mapDataStore); if (useStartZoomL...
java
public void addMapDataStore(MapDataStore mapDataStore, boolean useStartZoomLevel, boolean useStartPosition) { if (this.mapDatabases.contains(mapDataStore)) { throw new IllegalArgumentException("Duplicate map database"); } this.mapDatabases.add(mapDataStore); if (useStartZoomL...
[ "public", "void", "addMapDataStore", "(", "MapDataStore", "mapDataStore", ",", "boolean", "useStartZoomLevel", ",", "boolean", "useStartPosition", ")", "{", "if", "(", "this", ".", "mapDatabases", ".", "contains", "(", "mapDataStore", ")", ")", "{", "throw", "ne...
adds another mapDataStore @param mapDataStore the mapDataStore to add @param useStartZoomLevel if true, use the start zoom level of this mapDataStore as the start zoom level @param useStartPosition if true, use the start position of this mapDataStore as the start position
[ "adds", "another", "mapDataStore" ]
train
https://github.com/mapsforge/mapsforge/blob/c49c83f7f727552f793dff15cefa532ade030842/mapsforge-map/src/main/java/org/mapsforge/map/datastore/MultiMapDataStore.java#L65-L81
mkotsur/restito
src/main/java/com/xebialabs/restito/semantics/Condition.java
Condition.withPostBodyContainingJsonPath
public static Condition withPostBodyContainingJsonPath(final String pattern, final Object value) { return new Condition(input -> value.equals(JsonPath.parse(input.getPostBody()).read(pattern))); }
java
public static Condition withPostBodyContainingJsonPath(final String pattern, final Object value) { return new Condition(input -> value.equals(JsonPath.parse(input.getPostBody()).read(pattern))); }
[ "public", "static", "Condition", "withPostBodyContainingJsonPath", "(", "final", "String", "pattern", ",", "final", "Object", "value", ")", "{", "return", "new", "Condition", "(", "input", "->", "value", ".", "equals", "(", "JsonPath", ".", "parse", "(", "inpu...
With Valid Json Path. Check to see if incoming path has a valid string value selected via a <a href="https://github.com/jayway/JsonPath/"> JSONPath</a> expression.
[ "With", "Valid", "Json", "Path", ".", "Check", "to", "see", "if", "incoming", "path", "has", "a", "valid", "string", "value", "selected", "via", "a", "<a", "href", "=", "https", ":", "//", "github", ".", "com", "/", "jayway", "/", "JsonPath", "/", ">...
train
https://github.com/mkotsur/restito/blob/b999293616ca84fdea1ffe929e92a5db29c7e415/src/main/java/com/xebialabs/restito/semantics/Condition.java#L168-L170
marklogic/java-client-api
marklogic-client-api/src/main/java/com/marklogic/client/util/EditableNamespaceContext.java
EditableNamespaceContext.setNamespaceURI
public void setNamespaceURI(String prefix, String namespaceURI) { if (prefix == null) throw new IllegalArgumentException("Cannot bind null prefix"); if (namespaceURI == null) throw new IllegalArgumentException("Cannot set prefix to null namespace URI"); // no need to store if (XMLConstants....
java
public void setNamespaceURI(String prefix, String namespaceURI) { if (prefix == null) throw new IllegalArgumentException("Cannot bind null prefix"); if (namespaceURI == null) throw new IllegalArgumentException("Cannot set prefix to null namespace URI"); // no need to store if (XMLConstants....
[ "public", "void", "setNamespaceURI", "(", "String", "prefix", ",", "String", "namespaceURI", ")", "{", "if", "(", "prefix", "==", "null", ")", "throw", "new", "IllegalArgumentException", "(", "\"Cannot bind null prefix\"", ")", ";", "if", "(", "namespaceURI", "=...
Specifies a binding between a prefix and a namespace URI. @param prefix the prefix for the binding @param namespaceURI the URI for the namespace
[ "Specifies", "a", "binding", "between", "a", "prefix", "and", "a", "namespace", "URI", "." ]
train
https://github.com/marklogic/java-client-api/blob/acf60229a928abd4a8cc4b21b641d56957467da7/marklogic-client-api/src/main/java/com/marklogic/client/util/EditableNamespaceContext.java#L87-L98
fcrepo3/fcrepo
fcrepo-server/src/main/java/org/fcrepo/server/journal/recoverylog/JournalRecoveryLog.java
JournalRecoveryLog.logHeaderInfo
public void logHeaderInfo(Map<String, String> parameters) { StringBuffer buffer = new StringBuffer("Recovery parameters:"); for (Iterator<String> keys = parameters.keySet().iterator(); keys .hasNext();) { Object key = keys.next(); Object value = parameters.get(key...
java
public void logHeaderInfo(Map<String, String> parameters) { StringBuffer buffer = new StringBuffer("Recovery parameters:"); for (Iterator<String> keys = parameters.keySet().iterator(); keys .hasNext();) { Object key = keys.next(); Object value = parameters.get(key...
[ "public", "void", "logHeaderInfo", "(", "Map", "<", "String", ",", "String", ">", "parameters", ")", "{", "StringBuffer", "buffer", "=", "new", "StringBuffer", "(", "\"Recovery parameters:\"", ")", ";", "for", "(", "Iterator", "<", "String", ">", "keys", "="...
Concrete sub-classes should call this method from their constructor, or as soon as the log is ready for writing.
[ "Concrete", "sub", "-", "classes", "should", "call", "this", "method", "from", "their", "constructor", "or", "as", "soon", "as", "the", "log", "is", "ready", "for", "writing", "." ]
train
https://github.com/fcrepo3/fcrepo/blob/37df51b9b857fd12c6ab8269820d406c3c4ad774/fcrepo-server/src/main/java/org/fcrepo/server/journal/recoverylog/JournalRecoveryLog.java#L129-L138
alkacon/opencms-core
src/org/opencms/workplace/tools/CmsToolManager.java
CmsToolManager.jspForwardTool
public void jspForwardTool(CmsWorkplace wp, String toolPath, Map<String, String[]> params) throws IOException, ServletException { Map<String, String[]> newParams; if (params == null) { newParams = new HashMap<String, String[]>(); } else { newParams = new HashMap<Stri...
java
public void jspForwardTool(CmsWorkplace wp, String toolPath, Map<String, String[]> params) throws IOException, ServletException { Map<String, String[]> newParams; if (params == null) { newParams = new HashMap<String, String[]>(); } else { newParams = new HashMap<Stri...
[ "public", "void", "jspForwardTool", "(", "CmsWorkplace", "wp", ",", "String", "toolPath", ",", "Map", "<", "String", ",", "String", "[", "]", ">", "params", ")", "throws", "IOException", ",", "ServletException", "{", "Map", "<", "String", ",", "String", "[...
Redirects to the given tool with the given parameters.<p> @param wp the workplace object @param toolPath the path to the tool to redirect to @param params the parameters to send @throws IOException in case of errors during forwarding @throws ServletException in case of errors during forwarding
[ "Redirects", "to", "the", "given", "tool", "with", "the", "given", "parameters", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/workplace/tools/CmsToolManager.java#L502-L514
eFaps/eFaps-Kernel
src/main/java/org/efaps/admin/runlevel/RunLevel.java
RunLevel.isInitialisable
public static boolean isInitialisable() throws EFapsException { try { final Connection con = Context.getConnection(); final boolean ret = Context.getDbType().existsTable(Context.getConnection(), RunLevel.TABLE_TESTS); con.close(); return ret; }...
java
public static boolean isInitialisable() throws EFapsException { try { final Connection con = Context.getConnection(); final boolean ret = Context.getDbType().existsTable(Context.getConnection(), RunLevel.TABLE_TESTS); con.close(); return ret; }...
[ "public", "static", "boolean", "isInitialisable", "(", ")", "throws", "EFapsException", "{", "try", "{", "final", "Connection", "con", "=", "Context", ".", "getConnection", "(", ")", ";", "final", "boolean", "ret", "=", "Context", ".", "getDbType", "(", ")",...
Tests, if the SQL table {@link #TABLE_TESTS} exists (= <i>true</i>). This means the run level could be initialized. @return <i>true</i> if a run level could be initialized (and the SQL table exists in the database); otherwise <i>false</i> @throws EFapsException if the test for the table fails @see #TABLE_TESTS
[ "Tests", "if", "the", "SQL", "table", "{", "@link", "#TABLE_TESTS", "}", "exists", "(", "=", "<i", ">", "true<", "/", "i", ">", ")", ".", "This", "means", "the", "run", "level", "could", "be", "initialized", "." ]
train
https://github.com/eFaps/eFaps-Kernel/blob/04b96548f518c2386a93f5ec2b9349f9b9063859/src/main/java/org/efaps/admin/runlevel/RunLevel.java#L188-L199
Erudika/para
para-client/src/main/java/com/erudika/para/client/ParaClient.java
ParaClient.addAppSetting
public void addAppSetting(String key, Object value) { if (!StringUtils.isBlank(key) && value != null) { invokePut(Utils.formatMessage("_settings/{0}", key), Entity.json(Collections.singletonMap("value", value))); } }
java
public void addAppSetting(String key, Object value) { if (!StringUtils.isBlank(key) && value != null) { invokePut(Utils.formatMessage("_settings/{0}", key), Entity.json(Collections.singletonMap("value", value))); } }
[ "public", "void", "addAppSetting", "(", "String", "key", ",", "Object", "value", ")", "{", "if", "(", "!", "StringUtils", ".", "isBlank", "(", "key", ")", "&&", "value", "!=", "null", ")", "{", "invokePut", "(", "Utils", ".", "formatMessage", "(", "\"_...
Adds or overwrites an app-specific setting. @param key a key @param value a value
[ "Adds", "or", "overwrites", "an", "app", "-", "specific", "setting", "." ]
train
https://github.com/Erudika/para/blob/5ba096c477042ea7b18e9a0e8b5b1ee0f5bd6ce9/para-client/src/main/java/com/erudika/para/client/ParaClient.java#L1530-L1534
actframework/actframework
src/main/java/act/apidoc/javadoc/Javadoc.java
Javadoc.addBlockTag
public Javadoc addBlockTag(String tagName, String content) { return addBlockTag(new JavadocBlockTag(tagName, content)); }
java
public Javadoc addBlockTag(String tagName, String content) { return addBlockTag(new JavadocBlockTag(tagName, content)); }
[ "public", "Javadoc", "addBlockTag", "(", "String", "tagName", ",", "String", "content", ")", "{", "return", "addBlockTag", "(", "new", "JavadocBlockTag", "(", "tagName", ",", "content", ")", ")", ";", "}" ]
For tags like "@return good things" where tagName is "return", and the rest is content.
[ "For", "tags", "like" ]
train
https://github.com/actframework/actframework/blob/55a8f8b45e71159a79ec6e157c02f71700f8cd54/src/main/java/act/apidoc/javadoc/Javadoc.java#L60-L62
BorderTech/wcomponents
wcomponents-examples/src/main/java/com/github/bordertech/wcomponents/examples/layout/FlowLayoutExample.java
FlowLayoutExample.addBoxes
private static void addBoxes(final WPanel panel, final int amount) { for (int i = 1; i <= amount; i++) { WPanel box = new WPanel(WPanel.Type.BOX); box.add(new WText(Integer.toString(i))); panel.add(box); } }
java
private static void addBoxes(final WPanel panel, final int amount) { for (int i = 1; i <= amount; i++) { WPanel box = new WPanel(WPanel.Type.BOX); box.add(new WText(Integer.toString(i))); panel.add(box); } }
[ "private", "static", "void", "addBoxes", "(", "final", "WPanel", "panel", ",", "final", "int", "amount", ")", "{", "for", "(", "int", "i", "=", "1", ";", "i", "<=", "amount", ";", "i", "++", ")", "{", "WPanel", "box", "=", "new", "WPanel", "(", "...
Adds a set of boxes to the given panel. @param panel the panel to add the boxes to. @param amount the number of boxes to add.
[ "Adds", "a", "set", "of", "boxes", "to", "the", "given", "panel", "." ]
train
https://github.com/BorderTech/wcomponents/blob/d1a2b2243270067db030feb36ca74255aaa94436/wcomponents-examples/src/main/java/com/github/bordertech/wcomponents/examples/layout/FlowLayoutExample.java#L177-L183
OpenLiberty/open-liberty
dev/com.ibm.ws.kernel.service.location/src/com/ibm/ws/kernel/service/location/internal/FileLocator.java
FileLocator.getMatchingFiles
public static List<File> getMatchingFiles(String root, String filterExpr) { if (root == null) return Collections.emptyList(); File file = new File(root); return getMatchingFiles(file, filterExpr); }
java
public static List<File> getMatchingFiles(String root, String filterExpr) { if (root == null) return Collections.emptyList(); File file = new File(root); return getMatchingFiles(file, filterExpr); }
[ "public", "static", "List", "<", "File", ">", "getMatchingFiles", "(", "String", "root", ",", "String", "filterExpr", ")", "{", "if", "(", "root", "==", "null", ")", "return", "Collections", ".", "emptyList", "(", ")", ";", "File", "file", "=", "new", ...
Get a list of Files from the given path that match the provided filter; not recursive. @param root base directory to look for files @param filterExpr the regular expression to match, may be null @return List of File objects; List will be empty if root is null
[ "Get", "a", "list", "of", "Files", "from", "the", "given", "path", "that", "match", "the", "provided", "filter", ";", "not", "recursive", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.kernel.service.location/src/com/ibm/ws/kernel/service/location/internal/FileLocator.java#L223-L229
google/j2objc
jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/util/DerInputStream.java
DerInputStream.getUnalignedBitString
public BitArray getUnalignedBitString() throws IOException { if (buffer.read() != DerValue.tag_BitString) throw new IOException("DER input not a bit string"); int length = getLength(buffer) - 1; /* * First byte = number of excess bits in the last octet of the * re...
java
public BitArray getUnalignedBitString() throws IOException { if (buffer.read() != DerValue.tag_BitString) throw new IOException("DER input not a bit string"); int length = getLength(buffer) - 1; /* * First byte = number of excess bits in the last octet of the * re...
[ "public", "BitArray", "getUnalignedBitString", "(", ")", "throws", "IOException", "{", "if", "(", "buffer", ".", "read", "(", ")", "!=", "DerValue", ".", "tag_BitString", ")", "throw", "new", "IOException", "(", "\"DER input not a bit string\"", ")", ";", "int",...
Get a bit string from the input stream. The bit string need not be byte-aligned.
[ "Get", "a", "bit", "string", "from", "the", "input", "stream", ".", "The", "bit", "string", "need", "not", "be", "byte", "-", "aligned", "." ]
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/util/DerInputStream.java#L226-L243
google/closure-compiler
src/com/google/javascript/rhino/JSDocInfo.java
JSDocInfo.documentParam
boolean documentParam(String parameter, String description) { if (!lazyInitDocumentation()) { return true; } if (documentation.parameters == null) { documentation.parameters = new LinkedHashMap<>(); } if (!documentation.parameters.containsKey(parameter)) { documentation.parameter...
java
boolean documentParam(String parameter, String description) { if (!lazyInitDocumentation()) { return true; } if (documentation.parameters == null) { documentation.parameters = new LinkedHashMap<>(); } if (!documentation.parameters.containsKey(parameter)) { documentation.parameter...
[ "boolean", "documentParam", "(", "String", "parameter", ",", "String", "description", ")", "{", "if", "(", "!", "lazyInitDocumentation", "(", ")", ")", "{", "return", "true", ";", "}", "if", "(", "documentation", ".", "parameters", "==", "null", ")", "{", ...
Documents a parameter. Parameters are described using the {@code @param} annotation. @param parameter the parameter's name @param description the parameter's description
[ "Documents", "a", "parameter", ".", "Parameters", "are", "described", "using", "the", "{", "@code", "@param", "}", "annotation", "." ]
train
https://github.com/google/closure-compiler/blob/d81e36740f6a9e8ac31a825ee8758182e1dc5aae/src/com/google/javascript/rhino/JSDocInfo.java#L1302-L1317
BorderTech/wcomponents
wcomponents-core/src/main/java/com/github/bordertech/wcomponents/render/webxml/WCollapsibleRenderer.java
WCollapsibleRenderer.doRender
@Override public void doRender(final WComponent component, final WebXmlRenderContext renderContext) { WCollapsible collapsible = (WCollapsible) component; XmlStringBuilder xml = renderContext.getWriter(); WComponent content = collapsible.getContent(); boolean collapsed = collapsible.isCollapsed(); xml.appen...
java
@Override public void doRender(final WComponent component, final WebXmlRenderContext renderContext) { WCollapsible collapsible = (WCollapsible) component; XmlStringBuilder xml = renderContext.getWriter(); WComponent content = collapsible.getContent(); boolean collapsed = collapsible.isCollapsed(); xml.appen...
[ "@", "Override", "public", "void", "doRender", "(", "final", "WComponent", "component", ",", "final", "WebXmlRenderContext", "renderContext", ")", "{", "WCollapsible", "collapsible", "=", "(", "WCollapsible", ")", "component", ";", "XmlStringBuilder", "xml", "=", ...
Paints the given WCollapsible. @param component the WCollapsible to paint. @param renderContext the RenderContext to paint to.
[ "Paints", "the", "given", "WCollapsible", "." ]
train
https://github.com/BorderTech/wcomponents/blob/d1a2b2243270067db030feb36ca74255aaa94436/wcomponents-core/src/main/java/com/github/bordertech/wcomponents/render/webxml/WCollapsibleRenderer.java#L26-L89
UrielCh/ovh-java-sdk
ovh-java-sdk-order/src/main/java/net/minidev/ovh/api/ApiOvhOrder.java
ApiOvhOrder.overTheBox_serviceName_migrate_POST
public OvhOrder overTheBox_serviceName_migrate_POST(String serviceName, Boolean hardware, String offer, String shippingContactID, OvhShippingMethodEnum shippingMethod, Long shippingRelayID) throws IOException { String qPath = "/order/overTheBox/{serviceName}/migrate"; StringBuilder sb = path(qPath, serviceName); ...
java
public OvhOrder overTheBox_serviceName_migrate_POST(String serviceName, Boolean hardware, String offer, String shippingContactID, OvhShippingMethodEnum shippingMethod, Long shippingRelayID) throws IOException { String qPath = "/order/overTheBox/{serviceName}/migrate"; StringBuilder sb = path(qPath, serviceName); ...
[ "public", "OvhOrder", "overTheBox_serviceName_migrate_POST", "(", "String", "serviceName", ",", "Boolean", "hardware", ",", "String", "offer", ",", "String", "shippingContactID", ",", "OvhShippingMethodEnum", "shippingMethod", ",", "Long", "shippingRelayID", ")", "throws"...
Create order REST: POST /order/overTheBox/{serviceName}/migrate @param offer [required] Offer name to migrate to @param shippingContactID [required] Contact ID to deliver to @param shippingRelayID [required] Relay ID to deliver to. Needed if shipping is mondialRelay @param shippingMethod [required] How do you want you...
[ "Create", "order" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-order/src/main/java/net/minidev/ovh/api/ApiOvhOrder.java#L3177-L3188
JDBDT/jdbdt
src/main/java/org/jdbdt/DataSource.java
DataSource.proceedWithQuery
private void proceedWithQuery (PreparedStatement queryStmt, DataSet ds) throws SQLException { if (queryArgs != null && queryArgs.length > 0) { for (int i=0; i < queryArgs.length; i++) { queryStmt.setObject(i + 1, queryArgs[i]); } } try(ResultSet rs = queryStmt.executeQuery()) { i...
java
private void proceedWithQuery (PreparedStatement queryStmt, DataSet ds) throws SQLException { if (queryArgs != null && queryArgs.length > 0) { for (int i=0; i < queryArgs.length; i++) { queryStmt.setObject(i + 1, queryArgs[i]); } } try(ResultSet rs = queryStmt.executeQuery()) { i...
[ "private", "void", "proceedWithQuery", "(", "PreparedStatement", "queryStmt", ",", "DataSet", "ds", ")", "throws", "SQLException", "{", "if", "(", "queryArgs", "!=", "null", "&&", "queryArgs", ".", "length", ">", "0", ")", "{", "for", "(", "int", "i", "=",...
Execute query. @param queryStmt Query statement. @param ds Target data set. @throws SQLException if a database error occurs.
[ "Execute", "query", "." ]
train
https://github.com/JDBDT/jdbdt/blob/7e32845ad41dfbc5d6fd0fd561e3613697186df4/src/main/java/org/jdbdt/DataSource.java#L268-L285
Indoqa/logspace
logspace-agent-api/src/main/java/io/logspace/agent/api/AgentControllerProvider.java
AgentControllerProvider.setDescription
public static synchronized void setDescription(InputStream inputStream) { try { setDescription(AgentControllerDescriptionFactory.read(inputStream)); } catch (IOException ioex) { throw new AgentControllerInitializationException("Could not load logspace configuration.", ioex); ...
java
public static synchronized void setDescription(InputStream inputStream) { try { setDescription(AgentControllerDescriptionFactory.read(inputStream)); } catch (IOException ioex) { throw new AgentControllerInitializationException("Could not load logspace configuration.", ioex); ...
[ "public", "static", "synchronized", "void", "setDescription", "(", "InputStream", "inputStream", ")", "{", "try", "{", "setDescription", "(", "AgentControllerDescriptionFactory", ".", "read", "(", "inputStream", ")", ")", ";", "}", "catch", "(", "IOException", "io...
Set the {@link AgentControllerDescription} by reading it from the given {@link InputStream} and close the InputStream afterwards.<br> <br> This method expects the InputStream to provide a description in a format, that can be read by the {@link AgentControllerDescriptionFactory}.<br> This method will fail with an {@link...
[ "Set", "the", "{", "@link", "AgentControllerDescription", "}", "by", "reading", "it", "from", "the", "given", "{", "@link", "InputStream", "}", "and", "close", "the", "InputStream", "afterwards", ".", "<br", ">", "<br", ">", "This", "method", "expects", "the...
train
https://github.com/Indoqa/logspace/blob/781a3f1da0580542d7dd726cac8eafecb090663d/logspace-agent-api/src/main/java/io/logspace/agent/api/AgentControllerProvider.java#L115-L123
wmdietl/jsr308-langtools
src/share/classes/com/sun/tools/jdeps/JdepsTask.java
JdepsTask.toTag
private String toTag(String name, Archive source, Analyzer.Type type) { if (!isJDKArchive(source)) { return source.getName(); } JDKArchive jdk = (JDKArchive)source; boolean isExported = false; if (type == CLASS || type == VERBOSE) { isExported = jdk.isExp...
java
private String toTag(String name, Archive source, Analyzer.Type type) { if (!isJDKArchive(source)) { return source.getName(); } JDKArchive jdk = (JDKArchive)source; boolean isExported = false; if (type == CLASS || type == VERBOSE) { isExported = jdk.isExp...
[ "private", "String", "toTag", "(", "String", "name", ",", "Archive", "source", ",", "Analyzer", ".", "Type", "type", ")", "{", "if", "(", "!", "isJDKArchive", "(", "source", ")", ")", "{", "return", "source", ".", "getName", "(", ")", ";", "}", "JDKA...
If the given archive is JDK archive, this method returns the profile name only if -profile option is specified; it accesses a private JDK API and the returned value will have "JDK internal API" prefix For non-JDK archives, this method returns the file name of the archive.
[ "If", "the", "given", "archive", "is", "JDK", "archive", "this", "method", "returns", "the", "profile", "name", "only", "if", "-", "profile", "option", "is", "specified", ";", "it", "accesses", "a", "private", "JDK", "API", "and", "the", "returned", "value...
train
https://github.com/wmdietl/jsr308-langtools/blob/8812d28c20f4de070a0dd6de1b45602431379834/src/share/classes/com/sun/tools/jdeps/JdepsTask.java#L954-L973
lettuce-io/lettuce-core
src/main/java/io/lettuce/core/dynamic/support/ReflectionUtils.java
ReflectionUtils.invokeMethod
public static Object invokeMethod(Method method, Object target) { return invokeMethod(method, target, new Object[0]); }
java
public static Object invokeMethod(Method method, Object target) { return invokeMethod(method, target, new Object[0]); }
[ "public", "static", "Object", "invokeMethod", "(", "Method", "method", ",", "Object", "target", ")", "{", "return", "invokeMethod", "(", "method", ",", "target", ",", "new", "Object", "[", "0", "]", ")", ";", "}" ]
Invoke the specified {@link Method} against the supplied target object with no arguments. The target object can be {@code null} when invoking a static {@link Method}. <p> Thrown exceptions are handled via a call to {@link #handleReflectionException}. @param method the method to invoke @param target the target object t...
[ "Invoke", "the", "specified", "{", "@link", "Method", "}", "against", "the", "supplied", "target", "object", "with", "no", "arguments", ".", "The", "target", "object", "can", "be", "{", "@code", "null", "}", "when", "invoking", "a", "static", "{", "@link",...
train
https://github.com/lettuce-io/lettuce-core/blob/b6de74e384dea112e3656684ca3f50cdfd6c8e0d/src/main/java/io/lettuce/core/dynamic/support/ReflectionUtils.java#L107-L109
OpenLiberty/open-liberty
dev/com.ibm.ws.dynacache/src/com/ibm/ws/cache/HTODDynacache.java
HTODDynacache.readCacheIdsByRange
public Result readCacheIdsByRange(int index, int length) { Result result = readByRange(CACHE_ID_DATA, index, length, CHECK_EXPIRED, FILTER); return result; }
java
public Result readCacheIdsByRange(int index, int length) { Result result = readByRange(CACHE_ID_DATA, index, length, CHECK_EXPIRED, FILTER); return result; }
[ "public", "Result", "readCacheIdsByRange", "(", "int", "index", ",", "int", "length", ")", "{", "Result", "result", "=", "readByRange", "(", "CACHE_ID_DATA", ",", "index", ",", "length", ",", "CHECK_EXPIRED", ",", "FILTER", ")", ";", "return", "result", ";",...
*********************************************************************** readCacheIdsByRange() This method is used by CacheMonitor to retrive the cache ids from the disk. If index = 0, it starts the beginning. If index = 1, it means "next". If Index = -1, it means "previous". The length of the max number of templates to...
[ "***********************************************************************", "readCacheIdsByRange", "()", "This", "method", "is", "used", "by", "CacheMonitor", "to", "retrive", "the", "cache", "ids", "from", "the", "disk", ".", "If", "index", "=", "0", "it", "starts", "...
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.dynacache/src/com/ibm/ws/cache/HTODDynacache.java#L1374-L1377
apereo/cas
support/cas-server-support-actions/src/main/java/org/apereo/cas/web/flow/GenerateServiceTicketAction.java
GenerateServiceTicketAction.newEvent
private Event newEvent(final String id, final Exception error) { return new EventFactorySupport().event(this, id, new LocalAttributeMap<>("error", error)); }
java
private Event newEvent(final String id, final Exception error) { return new EventFactorySupport().event(this, id, new LocalAttributeMap<>("error", error)); }
[ "private", "Event", "newEvent", "(", "final", "String", "id", ",", "final", "Exception", "error", ")", "{", "return", "new", "EventFactorySupport", "(", ")", ".", "event", "(", "this", ",", "id", ",", "new", "LocalAttributeMap", "<>", "(", "\"error\"", ","...
New event based on the id, which contains an error attribute referring to the exception occurred. @param id the id @param error the error @return the event
[ "New", "event", "based", "on", "the", "id", "which", "contains", "an", "error", "attribute", "referring", "to", "the", "exception", "occurred", "." ]
train
https://github.com/apereo/cas/blob/b4b306433a8782cef803a39bea5b1f96740e0e9b/support/cas-server-support-actions/src/main/java/org/apereo/cas/web/flow/GenerateServiceTicketAction.java#L129-L131
looly/hutool
hutool-core/src/main/java/cn/hutool/core/net/NetUtil.java
NetUtil.getMacAddress
public static String getMacAddress(InetAddress inetAddress, String separator) { if (null == inetAddress) { return null; } byte[] mac; try { mac = NetworkInterface.getByInetAddress(inetAddress).getHardwareAddress(); } catch (SocketException e) { throw new UtilException(e); } if (null !...
java
public static String getMacAddress(InetAddress inetAddress, String separator) { if (null == inetAddress) { return null; } byte[] mac; try { mac = NetworkInterface.getByInetAddress(inetAddress).getHardwareAddress(); } catch (SocketException e) { throw new UtilException(e); } if (null !...
[ "public", "static", "String", "getMacAddress", "(", "InetAddress", "inetAddress", ",", "String", "separator", ")", "{", "if", "(", "null", "==", "inetAddress", ")", "{", "return", "null", ";", "}", "byte", "[", "]", "mac", ";", "try", "{", "mac", "=", ...
获得指定地址信息中的MAC地址 @param inetAddress {@link InetAddress} @param separator 分隔符,推荐使用“-”或者“:” @return MAC地址,用-分隔
[ "获得指定地址信息中的MAC地址" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/net/NetUtil.java#L432-L457
OpenLiberty/open-liberty
dev/com.ibm.ws.messaging.common/src/com/ibm/ws/sib/mfp/impl/JsMessageFactoryImpl.java
JsMessageFactoryImpl.ensureSchemasAvailable
private final static int ensureSchemasAvailable(byte[] buffer, int offset, Object store) throws MessageRestoreFailedException { if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(tc, "ensureSchemasAvailable", new Object[] {offset, store}); // If we have a message store we need to ensu...
java
private final static int ensureSchemasAvailable(byte[] buffer, int offset, Object store) throws MessageRestoreFailedException { if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(tc, "ensureSchemasAvailable", new Object[] {offset, store}); // If we have a message store we need to ensu...
[ "private", "final", "static", "int", "ensureSchemasAvailable", "(", "byte", "[", "]", "buffer", ",", "int", "offset", ",", "Object", "store", ")", "throws", "MessageRestoreFailedException", "{", "if", "(", "TraceComponent", ".", "isAnyTracingEnabled", "(", ")", ...
Utility method to extract the schema ids from a message buffer and, if a message store is supplied, check that all the necessary schemas are available. @param buffer The buffer containing the schema ids @param offset The offset into the buffer where the schema ids start @param store The MesasgeStore from which the...
[ "Utility", "method", "to", "extract", "the", "schema", "ids", "from", "a", "message", "buffer", "and", "if", "a", "message", "store", "is", "supplied", "check", "that", "all", "the", "necessary", "schemas", "are", "available", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.messaging.common/src/com/ibm/ws/sib/mfp/impl/JsMessageFactoryImpl.java#L563-L582
UrielCh/ovh-java-sdk
ovh-java-sdk-domain/src/main/java/net/minidev/ovh/api/ApiOvhDomain.java
ApiOvhDomain.zone_zoneName_dynHost_record_id_PUT
public void zone_zoneName_dynHost_record_id_PUT(String zoneName, Long id, OvhDynHostRecord body) throws IOException { String qPath = "/domain/zone/{zoneName}/dynHost/record/{id}"; StringBuilder sb = path(qPath, zoneName, id); exec(qPath, "PUT", sb.toString(), body); }
java
public void zone_zoneName_dynHost_record_id_PUT(String zoneName, Long id, OvhDynHostRecord body) throws IOException { String qPath = "/domain/zone/{zoneName}/dynHost/record/{id}"; StringBuilder sb = path(qPath, zoneName, id); exec(qPath, "PUT", sb.toString(), body); }
[ "public", "void", "zone_zoneName_dynHost_record_id_PUT", "(", "String", "zoneName", ",", "Long", "id", ",", "OvhDynHostRecord", "body", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/domain/zone/{zoneName}/dynHost/record/{id}\"", ";", "StringBuilder", "sb"...
Alter this object properties REST: PUT /domain/zone/{zoneName}/dynHost/record/{id} @param body [required] New object properties @param zoneName [required] The internal name of your zone @param id [required] Id of the object
[ "Alter", "this", "object", "properties" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-domain/src/main/java/net/minidev/ovh/api/ApiOvhDomain.java#L412-L416
spotbugs/spotbugs
eclipsePlugin/src/de/tobject/findbugs/classify/SeverityClassificationPulldownAction.java
SeverityClassificationPulldownAction.fillMenu
private void fillMenu() { // Create a selection listener to handle when the // user selects a warning severity. SelectionListener menuItemSelectionListener = new SelectionAdapter() { /* * (non-Javadoc) * * @see * org.eclipse.swt.eve...
java
private void fillMenu() { // Create a selection listener to handle when the // user selects a warning severity. SelectionListener menuItemSelectionListener = new SelectionAdapter() { /* * (non-Javadoc) * * @see * org.eclipse.swt.eve...
[ "private", "void", "fillMenu", "(", ")", "{", "// Create a selection listener to handle when the", "// user selects a warning severity.", "SelectionListener", "menuItemSelectionListener", "=", "new", "SelectionAdapter", "(", ")", "{", "/*\n * (non-Javadoc)\n *...
Fill the drop-down menu. We allow the user to choose a severity from 1 (least severe) to 5 (most severe). Default is 3.
[ "Fill", "the", "drop", "-", "down", "menu", ".", "We", "allow", "the", "user", "to", "choose", "a", "severity", "from", "1", "(", "least", "severe", ")", "to", "5", "(", "most", "severe", ")", ".", "Default", "is", "3", "." ]
train
https://github.com/spotbugs/spotbugs/blob/f6365c6eea6515035bded38efa4a7c8b46ccf28c/eclipsePlugin/src/de/tobject/findbugs/classify/SeverityClassificationPulldownAction.java#L73-L125
alkacon/opencms-core
src/org/opencms/ui/favorites/CmsFavoriteEntry.java
CmsFavoriteEntry.readId
public static CmsUUID readId(JSONObject obj, String key) { String strValue = obj.optString(key); if (!CmsUUID.isValidUUID(strValue)) { return null; } return new CmsUUID(strValue); }
java
public static CmsUUID readId(JSONObject obj, String key) { String strValue = obj.optString(key); if (!CmsUUID.isValidUUID(strValue)) { return null; } return new CmsUUID(strValue); }
[ "public", "static", "CmsUUID", "readId", "(", "JSONObject", "obj", ",", "String", "key", ")", "{", "String", "strValue", "=", "obj", ".", "optString", "(", "key", ")", ";", "if", "(", "!", "CmsUUID", ".", "isValidUUID", "(", "strValue", ")", ")", "{", ...
Reads a UUID from a JSON object. Returns null if the JSON value for the given key is not present or not a valid UUID @param obj the JSON object @param key the JSON key @return the UUID
[ "Reads", "a", "UUID", "from", "a", "JSON", "object", "." ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/ui/favorites/CmsFavoriteEntry.java#L157-L164
UrielCh/ovh-java-sdk
ovh-java-sdk-emaildomain/src/main/java/net/minidev/ovh/api/ApiOvhEmaildomain.java
ApiOvhEmaildomain.domain_account_accountName_changePassword_POST
public OvhTaskPop domain_account_accountName_changePassword_POST(String domain, String accountName, String password) throws IOException { String qPath = "/email/domain/{domain}/account/{accountName}/changePassword"; StringBuilder sb = path(qPath, domain, accountName); HashMap<String, Object>o = new HashMap<String...
java
public OvhTaskPop domain_account_accountName_changePassword_POST(String domain, String accountName, String password) throws IOException { String qPath = "/email/domain/{domain}/account/{accountName}/changePassword"; StringBuilder sb = path(qPath, domain, accountName); HashMap<String, Object>o = new HashMap<String...
[ "public", "OvhTaskPop", "domain_account_accountName_changePassword_POST", "(", "String", "domain", ",", "String", "accountName", ",", "String", "password", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/email/domain/{domain}/account/{accountName}/changePassword\...
Change mailbox password (length : [9;30], no space at begin and end, no accent) REST: POST /email/domain/{domain}/account/{accountName}/changePassword @param password [required] New password @param domain [required] Name of your domain name @param accountName [required] Name of account
[ "Change", "mailbox", "password", "(", "length", ":", "[", "9", ";", "30", "]", "no", "space", "at", "begin", "and", "end", "no", "accent", ")" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-emaildomain/src/main/java/net/minidev/ovh/api/ApiOvhEmaildomain.java#L558-L565
mgormley/pacaya
src/main/java/edu/jhu/pacaya/gm/model/FactorGraph.java
FactorGraph.getClamped
public FactorGraph getClamped(VarConfig clampVars) { FactorGraph clmpFg = new FactorGraph(); // Add ALL the original variables to the clamped factor graph. for (Var v : this.getVars()) { clmpFg.addVar(v); } // Add ALL the original factors to the clamped factor graph. ...
java
public FactorGraph getClamped(VarConfig clampVars) { FactorGraph clmpFg = new FactorGraph(); // Add ALL the original variables to the clamped factor graph. for (Var v : this.getVars()) { clmpFg.addVar(v); } // Add ALL the original factors to the clamped factor graph. ...
[ "public", "FactorGraph", "getClamped", "(", "VarConfig", "clampVars", ")", "{", "FactorGraph", "clmpFg", "=", "new", "FactorGraph", "(", ")", ";", "// Add ALL the original variables to the clamped factor graph.", "for", "(", "Var", "v", ":", "this", ".", "getVars", ...
Gets a new factor graph, identical to this one, except that specified variables are clamped to their values. This is accomplished by adding a unary factor on each clamped variable. The original K factors are preserved in order with IDs 1...K. @param clampVars The variables to clamp.
[ "Gets", "a", "new", "factor", "graph", "identical", "to", "this", "one", "except", "that", "specified", "variables", "are", "clamped", "to", "their", "values", ".", "This", "is", "accomplished", "by", "adding", "a", "unary", "factor", "on", "each", "clamped"...
train
https://github.com/mgormley/pacaya/blob/786294cbac7cc65dbc32210c10acc32ed0c69233/src/main/java/edu/jhu/pacaya/gm/model/FactorGraph.java#L52-L71
tango-controls/JTango
server/src/main/java/org/tango/server/build/StatusBuilder.java
StatusBuilder.build
public void build(final Class<?> clazz, final Field field, final DeviceImpl device, final Object businessObject) throws DevFailed { xlogger.entry(); BuilderUtils.checkStatic(field); Method getter; final String stateName = field.getName(); final String getterName = Bui...
java
public void build(final Class<?> clazz, final Field field, final DeviceImpl device, final Object businessObject) throws DevFailed { xlogger.entry(); BuilderUtils.checkStatic(field); Method getter; final String stateName = field.getName(); final String getterName = Bui...
[ "public", "void", "build", "(", "final", "Class", "<", "?", ">", "clazz", ",", "final", "Field", "field", ",", "final", "DeviceImpl", "device", ",", "final", "Object", "businessObject", ")", "throws", "DevFailed", "{", "xlogger", ".", "entry", "(", ")", ...
Create a status @param clazz @param field @param device @param businessObject @throws DevFailed
[ "Create", "a", "status" ]
train
https://github.com/tango-controls/JTango/blob/1ccc9dcb83e6de2359a9f1906d170571cacf1345/server/src/main/java/org/tango/server/build/StatusBuilder.java#L61-L97
jbundle/jbundle
thin/base/remote/src/main/java/org/jbundle/thin/base/message/remote/RemoteMessageQueue.java
RemoteMessageQueue.createMessageSender
public BaseMessageSender createMessageSender() { RemoteTask server = (RemoteTask)((App)this.getMessageManager().getApplication()).getRemoteTask(null); try { return new RemoteMessageSender(server, this); } catch (RemoteException ex) { ex.printStackTrace(); ...
java
public BaseMessageSender createMessageSender() { RemoteTask server = (RemoteTask)((App)this.getMessageManager().getApplication()).getRemoteTask(null); try { return new RemoteMessageSender(server, this); } catch (RemoteException ex) { ex.printStackTrace(); ...
[ "public", "BaseMessageSender", "createMessageSender", "(", ")", "{", "RemoteTask", "server", "=", "(", "RemoteTask", ")", "(", "(", "App", ")", "this", ".", "getMessageManager", "(", ")", ".", "getApplication", "(", ")", ")", ".", "getRemoteTask", "(", "null...
Create a new (Remote) message sender. @return The message sender.
[ "Create", "a", "new", "(", "Remote", ")", "message", "sender", "." ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/thin/base/remote/src/main/java/org/jbundle/thin/base/message/remote/RemoteMessageQueue.java#L64-L73
patrickfav/bcrypt
modules/bcrypt/src/main/java/at/favre/lib/crypto/bcrypt/BCryptOpenBSDProtocol.java
BCryptOpenBSDProtocol.enhancedKeySchedule
private void enhancedKeySchedule(int[] P, int[] S, byte[] data, byte[] key) { int i; int[] koffp = {0}, doffp = {0}; int[] lr = {0, 0}; int plen = P.length, slen = S.length; for (i = 0; i < plen; i++) { P[i] = P[i] ^ streamToWord(key, koffp); } //noi...
java
private void enhancedKeySchedule(int[] P, int[] S, byte[] data, byte[] key) { int i; int[] koffp = {0}, doffp = {0}; int[] lr = {0, 0}; int plen = P.length, slen = S.length; for (i = 0; i < plen; i++) { P[i] = P[i] ^ streamToWord(key, koffp); } //noi...
[ "private", "void", "enhancedKeySchedule", "(", "int", "[", "]", "P", ",", "int", "[", "]", "S", ",", "byte", "[", "]", "data", ",", "byte", "[", "]", "key", ")", "{", "int", "i", ";", "int", "[", "]", "koffp", "=", "{", "0", "}", ",", "doffp"...
Perform the "enhanced key schedule" step described by Provos and Mazieres in "A Future-Adaptable Password Scheme" http://www.openbsd.org/papers/bcrypt-paper.ps @param data salt information @param key password information
[ "Perform", "the", "enhanced", "key", "schedule", "step", "described", "by", "Provos", "and", "Mazieres", "in", "A", "Future", "-", "Adaptable", "Password", "Scheme", "http", ":", "//", "www", ".", "openbsd", ".", "org", "/", "papers", "/", "bcrypt", "-", ...
train
https://github.com/patrickfav/bcrypt/blob/40e75be395b4e1b57b9872b22d98a9fb560e0184/modules/bcrypt/src/main/java/at/favre/lib/crypto/bcrypt/BCryptOpenBSDProtocol.java#L366-L393
UrielCh/ovh-java-sdk
ovh-java-sdk-vps/src/main/java/net/minidev/ovh/api/ApiOvhVps.java
ApiOvhVps.serviceName_ips_ipAddress_PUT
public void serviceName_ips_ipAddress_PUT(String serviceName, String ipAddress, OvhIp body) throws IOException { String qPath = "/vps/{serviceName}/ips/{ipAddress}"; StringBuilder sb = path(qPath, serviceName, ipAddress); exec(qPath, "PUT", sb.toString(), body); }
java
public void serviceName_ips_ipAddress_PUT(String serviceName, String ipAddress, OvhIp body) throws IOException { String qPath = "/vps/{serviceName}/ips/{ipAddress}"; StringBuilder sb = path(qPath, serviceName, ipAddress); exec(qPath, "PUT", sb.toString(), body); }
[ "public", "void", "serviceName_ips_ipAddress_PUT", "(", "String", "serviceName", ",", "String", "ipAddress", ",", "OvhIp", "body", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/vps/{serviceName}/ips/{ipAddress}\"", ";", "StringBuilder", "sb", "=", "pa...
Alter this object properties REST: PUT /vps/{serviceName}/ips/{ipAddress} @param body [required] New object properties @param serviceName [required] The internal name of your VPS offer @param ipAddress [required] The effective ip address of the Ip object
[ "Alter", "this", "object", "properties" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-vps/src/main/java/net/minidev/ovh/api/ApiOvhVps.java#L562-L566
bekkopen/NoCommons
src/main/java/no/bekk/bekkopen/banking/Kidnummer.java
Kidnummer.mod10Kid
public static Kidnummer mod10Kid(String baseNumber, int targetLength) { if (baseNumber.length() >= targetLength) throw new IllegalArgumentException("baseNumber too long"); String padded = String.format("%0" + (targetLength-1) + "d", new BigInteger(baseNumber)); Kidnummer k = new ...
java
public static Kidnummer mod10Kid(String baseNumber, int targetLength) { if (baseNumber.length() >= targetLength) throw new IllegalArgumentException("baseNumber too long"); String padded = String.format("%0" + (targetLength-1) + "d", new BigInteger(baseNumber)); Kidnummer k = new ...
[ "public", "static", "Kidnummer", "mod10Kid", "(", "String", "baseNumber", ",", "int", "targetLength", ")", "{", "if", "(", "baseNumber", ".", "length", "(", ")", ">=", "targetLength", ")", "throw", "new", "IllegalArgumentException", "(", "\"baseNumber too long\"",...
Create a valid KID numer of the wanted length, using MOD10. Input is padded with leading zeros to reach wanted target length @param baseNumber base number to calculate checksum digit for @param targetLength wanted length, 0-padded. Between 2-25 @return Kidnummer
[ "Create", "a", "valid", "KID", "numer", "of", "the", "wanted", "length", "using", "MOD10", ".", "Input", "is", "padded", "with", "leading", "zeros", "to", "reach", "wanted", "target", "length" ]
train
https://github.com/bekkopen/NoCommons/blob/5a576696390cecaac111fa97fde581e0c1afb9b8/src/main/java/no/bekk/bekkopen/banking/Kidnummer.java#L36-L42
gallandarakhneorg/afc
advanced/dbasefile/src/main/java/org/arakhne/afc/io/dbase/DBaseFileReader.java
DBaseFileReader.readNumberRecordValue
private static int readNumberRecordValue(DBaseFileField field, int nrecord, int nfield, byte[] rawData, int rawOffset, OutputParameter<Double> value) throws IOException { final String buffer = new String(rawData, rawOffset, field.getLength()); try { final String b = buffer.trim(); if (b != null && b.length...
java
private static int readNumberRecordValue(DBaseFileField field, int nrecord, int nfield, byte[] rawData, int rawOffset, OutputParameter<Double> value) throws IOException { final String buffer = new String(rawData, rawOffset, field.getLength()); try { final String b = buffer.trim(); if (b != null && b.length...
[ "private", "static", "int", "readNumberRecordValue", "(", "DBaseFileField", "field", ",", "int", "nrecord", ",", "int", "nfield", ",", "byte", "[", "]", "rawData", ",", "int", "rawOffset", ",", "OutputParameter", "<", "Double", ">", "value", ")", "throws", "...
Read a NUMBER record value. @param field is the current parsed field. @param nrecord is the number of the record @param nfield is the number of the field @param rawData raw data @param rawOffset is the index at which the data could be obtained @param value will be set with the value extracted from the dBASE file @retu...
[ "Read", "a", "NUMBER", "record", "value", "." ]
train
https://github.com/gallandarakhneorg/afc/blob/0c7d2e1ddefd4167ef788416d970a6c1ef6f8bbb/advanced/dbasefile/src/main/java/org/arakhne/afc/io/dbase/DBaseFileReader.java#L1122-L1135
grails/grails-core
grails-bootstrap/src/main/groovy/grails/util/GrailsNameUtils.java
GrailsNameUtils.getPropertyForGetter
public static String getPropertyForGetter(String getterName, String returnType) { if (getterName == null || getterName.length() == 0) return null; if (getterName.startsWith("get")) { String prop = getterName.substring(3); return convertValidPropertyMethodSuffix(prop); } ...
java
public static String getPropertyForGetter(String getterName, String returnType) { if (getterName == null || getterName.length() == 0) return null; if (getterName.startsWith("get")) { String prop = getterName.substring(3); return convertValidPropertyMethodSuffix(prop); } ...
[ "public", "static", "String", "getPropertyForGetter", "(", "String", "getterName", ",", "String", "returnType", ")", "{", "if", "(", "getterName", "==", "null", "||", "getterName", ".", "length", "(", ")", "==", "0", ")", "return", "null", ";", "if", "(", ...
Returns a property name equivalent for the given getter name and return type or null if it is not a valid getter. If not null or empty the getter name is assumed to be a valid identifier. @param getterName The getter name @param returnType The type the method returns @return The property name equivalent
[ "Returns", "a", "property", "name", "equivalent", "for", "the", "given", "getter", "name", "and", "return", "type", "or", "null", "if", "it", "is", "not", "a", "valid", "getter", ".", "If", "not", "null", "or", "empty", "the", "getter", "name", "is", "...
train
https://github.com/grails/grails-core/blob/c0b08aa995b0297143b75d05642abba8cb7b4122/grails-bootstrap/src/main/groovy/grails/util/GrailsNameUtils.java#L576-L588
aws/aws-sdk-java
aws-java-sdk-core/src/main/java/com/amazonaws/http/apache/utils/ApacheUtils.java
ApacheUtils.createResponse
public static HttpResponse createResponse(Request<?> request, HttpRequestBase method, org.apache.http.HttpResponse apacheHttpResponse, HttpContext context) throws IOException { HttpResponse ht...
java
public static HttpResponse createResponse(Request<?> request, HttpRequestBase method, org.apache.http.HttpResponse apacheHttpResponse, HttpContext context) throws IOException { HttpResponse ht...
[ "public", "static", "HttpResponse", "createResponse", "(", "Request", "<", "?", ">", "request", ",", "HttpRequestBase", "method", ",", "org", ".", "apache", ".", "http", ".", "HttpResponse", "apacheHttpResponse", ",", "HttpContext", "context", ")", "throws", "IO...
Creates and initializes an HttpResponse object suitable to be passed to an HTTP response handler object. @param request Marshalled request object. @param method The HTTP method that was invoked to get the response. @param context The HTTP context associated with the request and response. @return The new, initialized ...
[ "Creates", "and", "initializes", "an", "HttpResponse", "object", "suitable", "to", "be", "passed", "to", "an", "HTTP", "response", "handler", "object", "." ]
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-core/src/main/java/com/amazonaws/http/apache/utils/ApacheUtils.java#L69-L86
FedericoPecora/meta-csp-framework
src/main/java/org/metacsp/multi/spatioTemporal/paths/TrajectoryEnvelopeSolver.java
TrajectoryEnvelopeSolver.createEnvelopes
public HashMap<Integer,ArrayList<TrajectoryEnvelope>> createEnvelopes(int firstRobotID, String ... pathFiles) { //Default footprint, 2.7 (w) x 6.6 (l) Coordinate frontLeft = new Coordinate(5.3, 1.35); Coordinate frontRight = new Coordinate(5.3, -1.35); Coordinate backRight = new Coordinate(-1.3, -1.35); Coord...
java
public HashMap<Integer,ArrayList<TrajectoryEnvelope>> createEnvelopes(int firstRobotID, String ... pathFiles) { //Default footprint, 2.7 (w) x 6.6 (l) Coordinate frontLeft = new Coordinate(5.3, 1.35); Coordinate frontRight = new Coordinate(5.3, -1.35); Coordinate backRight = new Coordinate(-1.3, -1.35); Coord...
[ "public", "HashMap", "<", "Integer", ",", "ArrayList", "<", "TrajectoryEnvelope", ">", ">", "createEnvelopes", "(", "int", "firstRobotID", ",", "String", "...", "pathFiles", ")", "{", "//Default footprint, 2.7 (w) x 6.6 (l)", "Coordinate", "frontLeft", "=", "new", "...
Create a trajectory envelope for each given reference to a file containing a path. Robot IDs are assigned starting from the given integer. This method creates three envelopes for each path: the main {@link TrajectoryEnvelope} covering the path; one {@link TrajectoryEnvelope} for the starting position of the robot; and ...
[ "Create", "a", "trajectory", "envelope", "for", "each", "given", "reference", "to", "a", "file", "containing", "a", "path", ".", "Robot", "IDs", "are", "assigned", "starting", "from", "the", "given", "integer", ".", "This", "method", "creates", "three", "env...
train
https://github.com/FedericoPecora/meta-csp-framework/blob/42aaef2e2b76d0f738427f0dd9653c4f62b40517/src/main/java/org/metacsp/multi/spatioTemporal/paths/TrajectoryEnvelopeSolver.java#L339-L349
chr78rm/tracelogger
src/main/java/de/christofreichardt/diagnosis/AbstractTracer.java
AbstractTracer.readConfiguration
protected void readConfiguration(XPath xpath, Node node) throws XPathExpressionException, AbstractTracer.Exception { this.autoflush = "true".equals((String) xpath.evaluate("./dns:AutoFlush/text()", node, XPathConstants.STRING)); this.bufferSize = Integer.parseInt((String) xpath.evaluate("./dns:BufSize/text()"...
java
protected void readConfiguration(XPath xpath, Node node) throws XPathExpressionException, AbstractTracer.Exception { this.autoflush = "true".equals((String) xpath.evaluate("./dns:AutoFlush/text()", node, XPathConstants.STRING)); this.bufferSize = Integer.parseInt((String) xpath.evaluate("./dns:BufSize/text()"...
[ "protected", "void", "readConfiguration", "(", "XPath", "xpath", ",", "Node", "node", ")", "throws", "XPathExpressionException", ",", "AbstractTracer", ".", "Exception", "{", "this", ".", "autoflush", "=", "\"true\"", ".", "equals", "(", "(", "String", ")", "x...
Reads the configuration for this particular tracer instance by evaluating the given node with the given xpath engine. @param xpath the xpath engine @param node the config node @throws javax.xml.xpath.XPathExpressionException indicates xpath problems @throws de.christofreichardt.diagnosis.AbstractTracer.Exception indic...
[ "Reads", "the", "configuration", "for", "this", "particular", "tracer", "instance", "by", "evaluating", "the", "given", "node", "with", "the", "given", "xpath", "engine", "." ]
train
https://github.com/chr78rm/tracelogger/blob/ad22452b20f8111ad4d367302c2b26a100a20200/src/main/java/de/christofreichardt/diagnosis/AbstractTracer.java#L310-L331
alkacon/opencms-core
src/org/opencms/loader/CmsDefaultTemplateContextProvider.java
CmsDefaultTemplateContextProvider.initMap
private Map<String, CmsTemplateContext> initMap() throws Exception { Map<String, CmsTemplateContext> result = new LinkedHashMap<String, CmsTemplateContext>(); String path = getConfigurationPropertyPath(); CmsResource resource = m_cms.readResource(path); CmsFile file = m_cms.readFil...
java
private Map<String, CmsTemplateContext> initMap() throws Exception { Map<String, CmsTemplateContext> result = new LinkedHashMap<String, CmsTemplateContext>(); String path = getConfigurationPropertyPath(); CmsResource resource = m_cms.readResource(path); CmsFile file = m_cms.readFil...
[ "private", "Map", "<", "String", ",", "CmsTemplateContext", ">", "initMap", "(", ")", "throws", "Exception", "{", "Map", "<", "String", ",", "CmsTemplateContext", ">", "result", "=", "new", "LinkedHashMap", "<", "String", ",", "CmsTemplateContext", ">", "(", ...
Loads the context map from the VFS.<p> @return the context map @throws Exception if something goes wrong
[ "Loads", "the", "context", "map", "from", "the", "VFS", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/loader/CmsDefaultTemplateContextProvider.java#L220-L268
before/quality-check
modules/quality-check/src/main/java/net/sf/qualitycheck/Check.java
Check.stateIsTrue
@Throws(IllegalStateOfArgumentException.class) public static void stateIsTrue(final boolean expression, @Nonnull final String descriptionTemplate, final Object... descriptionTemplateArgs) { if (!expression) { throw new IllegalStateOfArgumentException(descriptionTemplate, descriptionTemplateArgs); } }
java
@Throws(IllegalStateOfArgumentException.class) public static void stateIsTrue(final boolean expression, @Nonnull final String descriptionTemplate, final Object... descriptionTemplateArgs) { if (!expression) { throw new IllegalStateOfArgumentException(descriptionTemplate, descriptionTemplateArgs); } }
[ "@", "Throws", "(", "IllegalStateOfArgumentException", ".", "class", ")", "public", "static", "void", "stateIsTrue", "(", "final", "boolean", "expression", ",", "@", "Nonnull", "final", "String", "descriptionTemplate", ",", "final", "Object", "...", "descriptionTemp...
Ensures that a given state is {@code true} @param expression an expression that must be {@code true} to indicate a valid state @param descriptionTemplate format string template that explains why the state is invalid @param descriptionTemplateArgs format string template arguments to explain why the state is invalid @th...
[ "Ensures", "that", "a", "given", "state", "is", "{", "@code", "true", "}" ]
train
https://github.com/before/quality-check/blob/a75c32c39434ddb1f89bece57acae0536724c15a/modules/quality-check/src/main/java/net/sf/qualitycheck/Check.java#L3327-L3333
OpenLiberty/open-liberty
dev/com.ibm.ws.session/src/com/ibm/ws/session/StoreCallback.java
StoreCallback.sessionExpiryTimeSet
public void sessionExpiryTimeSet(ISession session, long old, long newone) { _sessionStateEventDispatcher.sessionExpiryTimeSet(session, old, newone); }
java
public void sessionExpiryTimeSet(ISession session, long old, long newone) { _sessionStateEventDispatcher.sessionExpiryTimeSet(session, old, newone); }
[ "public", "void", "sessionExpiryTimeSet", "(", "ISession", "session", ",", "long", "old", ",", "long", "newone", ")", "{", "_sessionStateEventDispatcher", ".", "sessionExpiryTimeSet", "(", "session", ",", "old", ",", "newone", ")", ";", "}" ]
Method sessionExpiryTimeSet <p> @param session @param old @param newone @see com.ibm.wsspi.session.IStoreCallback#sessionExpiryTimeSet(com.ibm.wsspi.session.ISession, long, long)
[ "Method", "sessionExpiryTimeSet", "<p", ">" ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.session/src/com/ibm/ws/session/StoreCallback.java#L252-L255
calimero-project/calimero-core
src/tuwien/auto/calimero/link/KNXNetworkLinkIP.java
KNXNetworkLinkIP.newTunnelingLink
public static KNXNetworkLinkIP newTunnelingLink(final InetSocketAddress localEP, final InetSocketAddress remoteEP, final boolean useNAT, final KNXMediumSettings settings) throws KNXException, InterruptedException { return new KNXNetworkLinkIP(TUNNELING, localEP, remoteEP, useNAT, settings); }
java
public static KNXNetworkLinkIP newTunnelingLink(final InetSocketAddress localEP, final InetSocketAddress remoteEP, final boolean useNAT, final KNXMediumSettings settings) throws KNXException, InterruptedException { return new KNXNetworkLinkIP(TUNNELING, localEP, remoteEP, useNAT, settings); }
[ "public", "static", "KNXNetworkLinkIP", "newTunnelingLink", "(", "final", "InetSocketAddress", "localEP", ",", "final", "InetSocketAddress", "remoteEP", ",", "final", "boolean", "useNAT", ",", "final", "KNXMediumSettings", "settings", ")", "throws", "KNXException", ",",...
Creates a new network link using KNXnet/IP tunneling (internally using a {@link KNXnetIPConnection}) to a remote KNXnet/IP server endpoint. @param localEP the local control endpoint of the link to use, supply the wildcard address to use a local IP on the same subnet as <code>remoteEP</code> and an ephemeral port numbe...
[ "Creates", "a", "new", "network", "link", "using", "KNXnet", "/", "IP", "tunneling", "(", "internally", "using", "a", "{", "@link", "KNXnetIPConnection", "}", ")", "to", "a", "remote", "KNXnet", "/", "IP", "server", "endpoint", "." ]
train
https://github.com/calimero-project/calimero-core/blob/7e6f547c6bd75fa985bfeb5b47ba671df2ea01e8/src/tuwien/auto/calimero/link/KNXNetworkLinkIP.java#L131-L135
Azure/azure-sdk-for-java
cosmosdb/resource-manager/v2015_04_08/src/main/java/com/microsoft/azure/management/cosmosdb/v2015_04_08/implementation/DatabaseAccountsInner.java
DatabaseAccountsInner.beginRegenerateKeyAsync
public Observable<Void> beginRegenerateKeyAsync(String resourceGroupName, String accountName, KeyKind keyKind) { return beginRegenerateKeyWithServiceResponseAsync(resourceGroupName, accountName, keyKind).map(new Func1<ServiceResponse<Void>, Void>() { @Override public Void call(ServiceRes...
java
public Observable<Void> beginRegenerateKeyAsync(String resourceGroupName, String accountName, KeyKind keyKind) { return beginRegenerateKeyWithServiceResponseAsync(resourceGroupName, accountName, keyKind).map(new Func1<ServiceResponse<Void>, Void>() { @Override public Void call(ServiceRes...
[ "public", "Observable", "<", "Void", ">", "beginRegenerateKeyAsync", "(", "String", "resourceGroupName", ",", "String", "accountName", ",", "KeyKind", "keyKind", ")", "{", "return", "beginRegenerateKeyWithServiceResponseAsync", "(", "resourceGroupName", ",", "accountName"...
Regenerates an access key for the specified Azure Cosmos DB database account. @param resourceGroupName Name of an Azure resource group. @param accountName Cosmos DB database account name. @param keyKind The access key to regenerate. Possible values include: 'primary', 'secondary', 'primaryReadonly', 'secondaryReadonly...
[ "Regenerates", "an", "access", "key", "for", "the", "specified", "Azure", "Cosmos", "DB", "database", "account", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/cosmosdb/resource-manager/v2015_04_08/src/main/java/com/microsoft/azure/management/cosmosdb/v2015_04_08/implementation/DatabaseAccountsInner.java#L1904-L1911
actframework/actframework
src/main/java/act/data/ApacheMultipartParser.java
ApacheMultipartParser.getFileName
private String getFileName(Map /* String, String */ headers) { String fileName = null; String cd = getHeader(headers, CONTENT_DISPOSITION); if (cd != null) { String cdl = cd.toLowerCase(); if (cdl.startsWith(FORM_DATA) || cdl.startsWith(ATTACHMENT)) { Para...
java
private String getFileName(Map /* String, String */ headers) { String fileName = null; String cd = getHeader(headers, CONTENT_DISPOSITION); if (cd != null) { String cdl = cd.toLowerCase(); if (cdl.startsWith(FORM_DATA) || cdl.startsWith(ATTACHMENT)) { Para...
[ "private", "String", "getFileName", "(", "Map", "/* String, String */", "headers", ")", "{", "String", "fileName", "=", "null", ";", "String", "cd", "=", "getHeader", "(", "headers", ",", "CONTENT_DISPOSITION", ")", ";", "if", "(", "cd", "!=", "null", ")", ...
Retrieves the file name from the <code>Content-disposition</code> header. @param headers A <code>Map</code> containing the HTTP request headers. @return The file name for the current <code>encapsulation</code>.
[ "Retrieves", "the", "file", "name", "from", "the", "<code", ">", "Content", "-", "disposition<", "/", "code", ">", "header", "." ]
train
https://github.com/actframework/actframework/blob/55a8f8b45e71159a79ec6e157c02f71700f8cd54/src/main/java/act/data/ApacheMultipartParser.java#L169-L198
zaproxy/zaproxy
src/org/parosproxy/paros/extension/ExtensionLoader.java
ExtensionLoader.initViewAllExtension
private void initViewAllExtension(final View view, double progressFactor) { if (view == null) { return; } final double factorPerc = progressFactor / getExtensionCount(); for (int i = 0; i < getExtensionCount(); i++) { final Extension extension = ...
java
private void initViewAllExtension(final View view, double progressFactor) { if (view == null) { return; } final double factorPerc = progressFactor / getExtensionCount(); for (int i = 0; i < getExtensionCount(); i++) { final Extension extension = ...
[ "private", "void", "initViewAllExtension", "(", "final", "View", "view", ",", "double", "progressFactor", ")", "{", "if", "(", "view", "==", "null", ")", "{", "return", ";", "}", "final", "double", "factorPerc", "=", "progressFactor", "/", "getExtensionCount",...
Init all extensions with the same View @param view the View that need to be applied
[ "Init", "all", "extensions", "with", "the", "same", "View" ]
train
https://github.com/zaproxy/zaproxy/blob/0cbe5121f2ae1ecca222513d182759210c569bec/src/org/parosproxy/paros/extension/ExtensionLoader.java#L1331-L1354
sdl/odata
odata_processor/src/main/java/com/sdl/odata/processor/write/ActionPostMethodHandler.java
ActionPostMethodHandler.handleWrite
@Override public ProcessorResult handleWrite(Object action) throws ODataException { Operation operation; if (action instanceof Operation) { operation = (Operation) action; Object data = operation.doOperation(getODataRequestContext(), getDataSourceFactory()); if (d...
java
@Override public ProcessorResult handleWrite(Object action) throws ODataException { Operation operation; if (action instanceof Operation) { operation = (Operation) action; Object data = operation.doOperation(getODataRequestContext(), getDataSourceFactory()); if (d...
[ "@", "Override", "public", "ProcessorResult", "handleWrite", "(", "Object", "action", ")", "throws", "ODataException", "{", "Operation", "operation", ";", "if", "(", "action", "instanceof", "Operation", ")", "{", "operation", "=", "(", "Operation", ")", "action"...
Handles action call and returns result in case when action returns it. @param action The instance of action. @return The result of calling action. @throws ODataException in case of any error.
[ "Handles", "action", "call", "and", "returns", "result", "in", "case", "when", "action", "returns", "it", "." ]
train
https://github.com/sdl/odata/blob/eb747d73e9af0f4e59a25b82ed656e526a7e2189/odata_processor/src/main/java/com/sdl/odata/processor/write/ActionPostMethodHandler.java#L49-L63
jhy/jsoup
src/main/java/org/jsoup/nodes/Element.java
Element.wholeText
public String wholeText() { final StringBuilder accum = StringUtil.borrowBuilder(); NodeTraversor.traverse(new NodeVisitor() { public void head(Node node, int depth) { if (node instanceof TextNode) { TextNode textNode = (TextNode) node; ...
java
public String wholeText() { final StringBuilder accum = StringUtil.borrowBuilder(); NodeTraversor.traverse(new NodeVisitor() { public void head(Node node, int depth) { if (node instanceof TextNode) { TextNode textNode = (TextNode) node; ...
[ "public", "String", "wholeText", "(", ")", "{", "final", "StringBuilder", "accum", "=", "StringUtil", ".", "borrowBuilder", "(", ")", ";", "NodeTraversor", ".", "traverse", "(", "new", "NodeVisitor", "(", ")", "{", "public", "void", "head", "(", "Node", "n...
Get the (unencoded) text of all children of this element, including any newlines and spaces present in the original. @return unencoded, un-normalized text @see #text()
[ "Get", "the", "(", "unencoded", ")", "text", "of", "all", "children", "of", "this", "element", "including", "any", "newlines", "and", "spaces", "present", "in", "the", "original", "." ]
train
https://github.com/jhy/jsoup/blob/68ff8cbe7ad847059737a09c567a501a7f1d251f/src/main/java/org/jsoup/nodes/Element.java#L1095-L1110
googleapis/google-cloud-java
google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClient.java
WebSecurityScannerClient.updateScanConfig
public final ScanConfig updateScanConfig(ScanConfig scanConfig, FieldMask updateMask) { UpdateScanConfigRequest request = UpdateScanConfigRequest.newBuilder() .setScanConfig(scanConfig) .setUpdateMask(updateMask) .build(); return updateScanConfig(request); }
java
public final ScanConfig updateScanConfig(ScanConfig scanConfig, FieldMask updateMask) { UpdateScanConfigRequest request = UpdateScanConfigRequest.newBuilder() .setScanConfig(scanConfig) .setUpdateMask(updateMask) .build(); return updateScanConfig(request); }
[ "public", "final", "ScanConfig", "updateScanConfig", "(", "ScanConfig", "scanConfig", ",", "FieldMask", "updateMask", ")", "{", "UpdateScanConfigRequest", "request", "=", "UpdateScanConfigRequest", ".", "newBuilder", "(", ")", ".", "setScanConfig", "(", "scanConfig", ...
Updates a ScanConfig. This method support partial update of a ScanConfig. <p>Sample code: <pre><code> try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) { ScanConfig scanConfig = ScanConfig.newBuilder().build(); FieldMask updateMask = FieldMask.newBuilder().build(); ScanConfig...
[ "Updates", "a", "ScanConfig", ".", "This", "method", "support", "partial", "update", "of", "a", "ScanConfig", "." ]
train
https://github.com/googleapis/google-cloud-java/blob/d2f0bc64a53049040fe9c9d338b12fab3dd1ad6a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClient.java#L605-L613
googlegenomics/utils-java
src/main/java/com/google/cloud/genomics/utils/grpc/VariantUtils.java
VariantUtils.isSameVariantSite
public static final boolean isSameVariantSite(Variant.Builder variant1, Variant variant2) { return variant1.getReferenceName().equals(variant2.getReferenceName()) && variant1.getReferenceBases().equals(variant2.getReferenceBases()) && variant1.getStart() == variant2.getStart(); }
java
public static final boolean isSameVariantSite(Variant.Builder variant1, Variant variant2) { return variant1.getReferenceName().equals(variant2.getReferenceName()) && variant1.getReferenceBases().equals(variant2.getReferenceBases()) && variant1.getStart() == variant2.getStart(); }
[ "public", "static", "final", "boolean", "isSameVariantSite", "(", "Variant", ".", "Builder", "variant1", ",", "Variant", "variant2", ")", "{", "return", "variant1", ".", "getReferenceName", "(", ")", ".", "equals", "(", "variant2", ".", "getReferenceName", "(", ...
Determine whether two variants occur at the same site in the genome, where "site" is defined by reference name, start position, and reference bases. The reference bases are taken into account particularly for indels. @param variant1 @param variant2 @return true, if they occur at the same site
[ "Determine", "whether", "two", "variants", "occur", "at", "the", "same", "site", "in", "the", "genome", "where", "site", "is", "defined", "by", "reference", "name", "start", "position", "and", "reference", "bases", "." ]
train
https://github.com/googlegenomics/utils-java/blob/7205d5b4e4f61fc6b93acb4bdd76b93df5b5f612/src/main/java/com/google/cloud/genomics/utils/grpc/VariantUtils.java#L261-L265
intendia-oss/rxjava-gwt
src/main/modified/io/reactivex/super/io/reactivex/internal/operators/flowable/FlowableReplay.java
FlowableReplay.createFrom
@SuppressWarnings("unchecked") public static <T> ConnectableFlowable<T> createFrom(Flowable<? extends T> source) { Flowable<T> sourceCast = (Flowable<T>) source; return create(sourceCast, DEFAULT_UNBOUNDED_FACTORY); }
java
@SuppressWarnings("unchecked") public static <T> ConnectableFlowable<T> createFrom(Flowable<? extends T> source) { Flowable<T> sourceCast = (Flowable<T>) source; return create(sourceCast, DEFAULT_UNBOUNDED_FACTORY); }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "public", "static", "<", "T", ">", "ConnectableFlowable", "<", "T", ">", "createFrom", "(", "Flowable", "<", "?", "extends", "T", ">", "source", ")", "{", "Flowable", "<", "T", ">", "sourceCast", "=", "...
Creates a replaying ConnectableObservable with an unbounded buffer. @param <T> the value type @param source the source Publisher to use @return the new ConnectableObservable instance
[ "Creates", "a", "replaying", "ConnectableObservable", "with", "an", "unbounded", "buffer", "." ]
train
https://github.com/intendia-oss/rxjava-gwt/blob/8d5635b12ce40da99e76b59dc6bfe6fc2fffc1fa/src/main/modified/io/reactivex/super/io/reactivex/internal/operators/flowable/FlowableReplay.java#L83-L87
ironjacamar/ironjacamar
core/src/main/java/org/ironjacamar/core/workmanager/transport/remote/jgroups/JGroupsTransport.java
JGroupsTransport.addWorkManager
public void addWorkManager(org.ironjacamar.core.spi.workmanager.Address logicalAddress, org.jgroups.Address address) { super.localWorkManagerAdd(logicalAddress, address); }
java
public void addWorkManager(org.ironjacamar.core.spi.workmanager.Address logicalAddress, org.jgroups.Address address) { super.localWorkManagerAdd(logicalAddress, address); }
[ "public", "void", "addWorkManager", "(", "org", ".", "ironjacamar", ".", "core", ".", "spi", ".", "workmanager", ".", "Address", "logicalAddress", ",", "org", ".", "jgroups", ".", "Address", "address", ")", "{", "super", ".", "localWorkManagerAdd", "(", "log...
Delegator @param logicalAddress The logical address @param address The address
[ "Delegator" ]
train
https://github.com/ironjacamar/ironjacamar/blob/f0389ee7e62aa8b40ba09b251edad76d220ea796/core/src/main/java/org/ironjacamar/core/workmanager/transport/remote/jgroups/JGroupsTransport.java#L298-L301
alkacon/opencms-core
src/org/opencms/file/CmsObject.java
CmsObject.readResource
public I_CmsHistoryResource readResource(CmsUUID structureID, int version) throws CmsException, CmsVfsResourceNotFoundException { CmsResource resource = readResource(structureID, CmsResourceFilter.ALL); return m_securityManager.readResource(m_context, resource, version); }
java
public I_CmsHistoryResource readResource(CmsUUID structureID, int version) throws CmsException, CmsVfsResourceNotFoundException { CmsResource resource = readResource(structureID, CmsResourceFilter.ALL); return m_securityManager.readResource(m_context, resource, version); }
[ "public", "I_CmsHistoryResource", "readResource", "(", "CmsUUID", "structureID", ",", "int", "version", ")", "throws", "CmsException", ",", "CmsVfsResourceNotFoundException", "{", "CmsResource", "resource", "=", "readResource", "(", "structureID", ",", "CmsResourceFilter"...
Reads the historical resource with the given version for the resource given the given structure id.<p> A resource may be of type <code>{@link CmsFile}</code> or <code>{@link CmsFolder}</code>. In case of a file, the resource will not contain the binary file content. Since reading the binary content is a cost-expensive...
[ "Reads", "the", "historical", "resource", "with", "the", "given", "version", "for", "the", "resource", "given", "the", "given", "structure", "id", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/file/CmsObject.java#L3146-L3151
Stratio/stratio-cassandra
src/java/com/stratio/cassandra/index/schema/mapping/Mapping.java
Mapping.validate
public void validate(CFMetaData metadata) { for (Map.Entry<String, ColumnMapper> entry : columnMappers.entrySet()) { String name = entry.getKey(); ColumnMapper columnMapper = entry.getValue(); ByteBuffer columnName = UTF8Type.instance.decompose(name); ColumnDefi...
java
public void validate(CFMetaData metadata) { for (Map.Entry<String, ColumnMapper> entry : columnMappers.entrySet()) { String name = entry.getKey(); ColumnMapper columnMapper = entry.getValue(); ByteBuffer columnName = UTF8Type.instance.decompose(name); ColumnDefi...
[ "public", "void", "validate", "(", "CFMetaData", "metadata", ")", "{", "for", "(", "Map", ".", "Entry", "<", "String", ",", "ColumnMapper", ">", "entry", ":", "columnMappers", ".", "entrySet", "(", ")", ")", "{", "String", "name", "=", "entry", ".", "g...
Checks if this is consistent with the specified column family metadata. @param metadata A column family metadata.
[ "Checks", "if", "this", "is", "consistent", "with", "the", "specified", "column", "family", "metadata", "." ]
train
https://github.com/Stratio/stratio-cassandra/blob/f6416b43ad5309083349ad56266450fa8c6a2106/src/java/com/stratio/cassandra/index/schema/mapping/Mapping.java#L50-L71
google/error-prone
check_api/src/main/java/com/google/errorprone/matchers/Matchers.java
Matchers.contains
public static <T extends Tree, V extends Tree> Matcher<T> contains( Class<V> clazz, Matcher<V> treeMatcher) { final Matcher<Tree> contains = new Contains(toType(clazz, treeMatcher)); return contains::matches; }
java
public static <T extends Tree, V extends Tree> Matcher<T> contains( Class<V> clazz, Matcher<V> treeMatcher) { final Matcher<Tree> contains = new Contains(toType(clazz, treeMatcher)); return contains::matches; }
[ "public", "static", "<", "T", "extends", "Tree", ",", "V", "extends", "Tree", ">", "Matcher", "<", "T", ">", "contains", "(", "Class", "<", "V", ">", "clazz", ",", "Matcher", "<", "V", ">", "treeMatcher", ")", "{", "final", "Matcher", "<", "Tree", ...
Applies the given matcher recursively to all descendants of an AST node, and matches if any matching descendant node is found. @param clazz The type of node to be matched. @param treeMatcher The matcher to apply recursively to the tree.
[ "Applies", "the", "given", "matcher", "recursively", "to", "all", "descendants", "of", "an", "AST", "node", "and", "matches", "if", "any", "matching", "descendant", "node", "is", "found", "." ]
train
https://github.com/google/error-prone/blob/fe2e3cc2cf1958cb7c487bfe89852bb4c225ba9d/check_api/src/main/java/com/google/errorprone/matchers/Matchers.java#L1411-L1415
exoplatform/jcr
exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/statistics/JCRStatisticsManager.java
JCRStatisticsManager.getStatistics
private static Statistics getStatistics(String category, String name) { StatisticsContext context = getContext(category); if (context == null) { return null; } // Format the name name = formatName(name); if (name == null) { return null; } ...
java
private static Statistics getStatistics(String category, String name) { StatisticsContext context = getContext(category); if (context == null) { return null; } // Format the name name = formatName(name); if (name == null) { return null; } ...
[ "private", "static", "Statistics", "getStatistics", "(", "String", "category", ",", "String", "name", ")", "{", "StatisticsContext", "context", "=", "getContext", "(", "category", ")", ";", "if", "(", "context", "==", "null", ")", "{", "return", "null", ";",...
Retrieve statistics of the given category and name. @return the related {@link Statistics}, <code>null</code> otherwise.
[ "Retrieve", "statistics", "of", "the", "given", "category", "and", "name", "." ]
train
https://github.com/exoplatform/jcr/blob/3e7f9ee1b5683640d73a4316fb4b0ad5eac5b8a2/exo.jcr.component.core/src/main/java/org/exoplatform/services/jcr/statistics/JCRStatisticsManager.java#L353-L376
BioPAX/Paxtools
pattern/src/main/java/org/biopax/paxtools/pattern/miner/SIFSearcher.java
SIFSearcher.searchSIF
public boolean searchSIF(Model model, OutputStream out, SIFToText stt) { Set<SIFInteraction> inters = searchSIF(model); if (!inters.isEmpty()) { List<SIFInteraction> interList = new ArrayList<SIFInteraction>(inters); Collections.sort(interList); try { boolean first = true; OutputStreamWriter...
java
public boolean searchSIF(Model model, OutputStream out, SIFToText stt) { Set<SIFInteraction> inters = searchSIF(model); if (!inters.isEmpty()) { List<SIFInteraction> interList = new ArrayList<SIFInteraction>(inters); Collections.sort(interList); try { boolean first = true; OutputStreamWriter...
[ "public", "boolean", "searchSIF", "(", "Model", "model", ",", "OutputStream", "out", ",", "SIFToText", "stt", ")", "{", "Set", "<", "SIFInteraction", ">", "inters", "=", "searchSIF", "(", "model", ")", ";", "if", "(", "!", "inters", ".", "isEmpty", "(", ...
Searches the given model with the contained miners. Writes the textual result to the given output stream. Closes the stream at the end. @param model model to search @param out stream to write @param stt sif to text converter @return true if any output produced successfully
[ "Searches", "the", "given", "model", "with", "the", "contained", "miners", ".", "Writes", "the", "textual", "result", "to", "the", "given", "output", "stream", ".", "Closes", "the", "stream", "at", "the", "end", "." ]
train
https://github.com/BioPAX/Paxtools/blob/2f93afa94426bf8b5afc2e0e61cd4b269a83288d/pattern/src/main/java/org/biopax/paxtools/pattern/miner/SIFSearcher.java#L213-L241
Whiley/WhileyCompiler
src/main/java/wyc/io/WhileyFileParser.java
WhileyFileParser.parseQualifiedAccess
private Expr parseQualifiedAccess(EnclosingScope scope, boolean terminated) { int start = index; // Parse qualified name Name name = parseName(scope); // Construct link to be resolved Decl.Link link = new Decl.Link<>(name); // Decide what we've got int mid = index; Expr expr; if (skipTemplate(scope) &...
java
private Expr parseQualifiedAccess(EnclosingScope scope, boolean terminated) { int start = index; // Parse qualified name Name name = parseName(scope); // Construct link to be resolved Decl.Link link = new Decl.Link<>(name); // Decide what we've got int mid = index; Expr expr; if (skipTemplate(scope) &...
[ "private", "Expr", "parseQualifiedAccess", "(", "EnclosingScope", "scope", ",", "boolean", "terminated", ")", "{", "int", "start", "=", "index", ";", "// Parse qualified name", "Name", "name", "=", "parseName", "(", "scope", ")", ";", "// Construct link to be resolv...
Attempt to parse a possible module identifier. This will reflect a true module identifier only if the root variable is not in the given environment. @param src @param scope The enclosing scope for this statement, which determines the set of visible (i.e. declared) variables and also the current indentation level. @ret...
[ "Attempt", "to", "parse", "a", "possible", "module", "identifier", ".", "This", "will", "reflect", "a", "true", "module", "identifier", "only", "if", "the", "root", "variable", "is", "not", "in", "the", "given", "environment", "." ]
train
https://github.com/Whiley/WhileyCompiler/blob/680f8a657d3fc286f8cc422755988b6d74ab3f4c/src/main/java/wyc/io/WhileyFileParser.java#L2271-L2298
fcrepo3/fcrepo
fcrepo-security/fcrepo-security-pdp/src/main/java/org/fcrepo/server/security/xacml/util/ContextUtil.java
ContextUtil.buildRequest
public RequestCtx buildRequest(List<Map<URI, List<AttributeValue>>> subjects, Map<URI, AttributeValue> actions, Map<URI, AttributeValue> resources, Map<URI, AttributeValue> environment, ...
java
public RequestCtx buildRequest(List<Map<URI, List<AttributeValue>>> subjects, Map<URI, AttributeValue> actions, Map<URI, AttributeValue> resources, Map<URI, AttributeValue> environment, ...
[ "public", "RequestCtx", "buildRequest", "(", "List", "<", "Map", "<", "URI", ",", "List", "<", "AttributeValue", ">", ">", ">", "subjects", ",", "Map", "<", "URI", ",", "AttributeValue", ">", "actions", ",", "Map", "<", "URI", ",", "AttributeValue", ">",...
Constructs a RequestCtx object. @param subjects list of Subjects @param actions list of Action attributes @param resources list of resource Attributes @param environment list of environment Attributes @return the RequestCtx object @throws MelcoeXacmlException
[ "Constructs", "a", "RequestCtx", "object", "." ]
train
https://github.com/fcrepo3/fcrepo/blob/37df51b9b857fd12c6ab8269820d406c3c4ad774/fcrepo-security/fcrepo-security-pdp/src/main/java/org/fcrepo/server/security/xacml/util/ContextUtil.java#L250-L275
zerodhatech/javakiteconnect
kiteconnect/src/com/zerodhatech/kiteconnect/KiteConnect.java
KiteConnect.modifyMFSIP
public boolean modifyMFSIP(String frequency, int day, int instalments, double amount, String status, String sipId) throws KiteException, IOException, JSONException { Map<String, Object> params = new HashMap<String, Object>(); params.put("frequency", frequency); params.put("day", day); pa...
java
public boolean modifyMFSIP(String frequency, int day, int instalments, double amount, String status, String sipId) throws KiteException, IOException, JSONException { Map<String, Object> params = new HashMap<String, Object>(); params.put("frequency", frequency); params.put("day", day); pa...
[ "public", "boolean", "modifyMFSIP", "(", "String", "frequency", ",", "int", "day", ",", "int", "instalments", ",", "double", "amount", ",", "String", "status", ",", "String", "sipId", ")", "throws", "KiteException", ",", "IOException", ",", "JSONException", "{...
Modify a mutualfunds sip. @param frequency weekly, monthly, or quarterly. @param status Pause or unpause an SIP (active or paused). @param amount Amount worth of units to purchase. It should be equal to or greated than minimum_additional_purchase_amount and in multiple of purchase_amount_multiplier in the instrument ma...
[ "Modify", "a", "mutualfunds", "sip", "." ]
train
https://github.com/zerodhatech/javakiteconnect/blob/4a3f15ff2c8a1b3b6ec61799f8bb047e4dfeb92d/kiteconnect/src/com/zerodhatech/kiteconnect/KiteConnect.java#L713-L723
sai-pullabhotla/catatumbo
src/main/java/com/jmethods/catatumbo/BaseQueryRequest.java
BaseQueryRequest.addPositionalBindings
public void addPositionalBindings(Object first, Object... others) { positionalBindings.add(first); positionalBindings.addAll(Arrays.asList(others)); }
java
public void addPositionalBindings(Object first, Object... others) { positionalBindings.add(first); positionalBindings.addAll(Arrays.asList(others)); }
[ "public", "void", "addPositionalBindings", "(", "Object", "first", ",", "Object", "...", "others", ")", "{", "positionalBindings", ".", "add", "(", "first", ")", ";", "positionalBindings", ".", "addAll", "(", "Arrays", ".", "asList", "(", "others", ")", ")",...
Adds the positional bindings that are needed for any positional parameters in the GQL query. @param first the first positional binding @param others subsequent positional bindings, if any
[ "Adds", "the", "positional", "bindings", "that", "are", "needed", "for", "any", "positional", "parameters", "in", "the", "GQL", "query", "." ]
train
https://github.com/sai-pullabhotla/catatumbo/blob/96d4c6dce3a5009624f7112a398406914dd19165/src/main/java/com/jmethods/catatumbo/BaseQueryRequest.java#L152-L155
puniverse/capsule
capsule-util/src/main/java/co/paralleluniverse/capsule/Jar.java
Jar.addEntry
public Jar addEntry(Path path, Path file) throws IOException { return addEntry(path, Files.newInputStream(file)); }
java
public Jar addEntry(Path path, Path file) throws IOException { return addEntry(path, Files.newInputStream(file)); }
[ "public", "Jar", "addEntry", "(", "Path", "path", ",", "Path", "file", ")", "throws", "IOException", "{", "return", "addEntry", "(", "path", ",", "Files", ".", "newInputStream", "(", "file", ")", ")", ";", "}" ]
Adds an entry to this JAR. @param path the entry's path within the JAR @param file the file to add as an entry @return {@code this}
[ "Adds", "an", "entry", "to", "this", "JAR", "." ]
train
https://github.com/puniverse/capsule/blob/291a54e501a32aaf0284707b8c1fbff6a566822b/capsule-util/src/main/java/co/paralleluniverse/capsule/Jar.java#L332-L334
voldemort/voldemort
src/java/voldemort/utils/UpdateClusterUtils.java
UpdateClusterUtils.removePartitionsFromNode
public static Node removePartitionsFromNode(final Node node, final Set<Integer> donatedPartitions) { List<Integer> deepCopy = new ArrayList<Integer>(node.getPartitionIds()); deepCopy.removeAll(donatedPartitions); return updateNode(node, deepCopy); ...
java
public static Node removePartitionsFromNode(final Node node, final Set<Integer> donatedPartitions) { List<Integer> deepCopy = new ArrayList<Integer>(node.getPartitionIds()); deepCopy.removeAll(donatedPartitions); return updateNode(node, deepCopy); ...
[ "public", "static", "Node", "removePartitionsFromNode", "(", "final", "Node", "node", ",", "final", "Set", "<", "Integer", ">", "donatedPartitions", ")", "{", "List", "<", "Integer", ">", "deepCopy", "=", "new", "ArrayList", "<", "Integer", ">", "(", "node",...
Remove the set of partitions from the node provided @param node The node from which we're removing the partitions @param donatedPartitions The list of partitions to remove @return The new node without the partitions
[ "Remove", "the", "set", "of", "partitions", "from", "the", "node", "provided" ]
train
https://github.com/voldemort/voldemort/blob/a7dbdea58032021361680faacf2782cf981c5332/src/java/voldemort/utils/UpdateClusterUtils.java#L103-L108
xcesco/kripton
kripton-processor/src/main/java/com/abubusoft/kripton/processor/sqlite/SqlModifyBuilder.java
SqlModifyBuilder.generateLogForModifiers
public static void generateLogForModifiers(final SQLiteModelMethod method, MethodSpec.Builder methodBuilder) { JQLChecker jqlChecker = JQLChecker.getInstance(); final One<Boolean> usedInWhere = new One<Boolean>(false); methodBuilder.addCode("\n// display log\n"); String sqlForLog = jqlChecker.replace(method, ...
java
public static void generateLogForModifiers(final SQLiteModelMethod method, MethodSpec.Builder methodBuilder) { JQLChecker jqlChecker = JQLChecker.getInstance(); final One<Boolean> usedInWhere = new One<Boolean>(false); methodBuilder.addCode("\n// display log\n"); String sqlForLog = jqlChecker.replace(method, ...
[ "public", "static", "void", "generateLogForModifiers", "(", "final", "SQLiteModelMethod", "method", ",", "MethodSpec", ".", "Builder", "methodBuilder", ")", "{", "JQLChecker", "jqlChecker", "=", "JQLChecker", ".", "getInstance", "(", ")", ";", "final", "One", "<",...
generate sql log. @param method the method @param methodBuilder the method builder
[ "generate", "sql", "log", "." ]
train
https://github.com/xcesco/kripton/blob/90de2c0523d39b99e81b8d38aa996898762f594a/kripton-processor/src/main/java/com/abubusoft/kripton/processor/sqlite/SqlModifyBuilder.java#L579-L640
Axway/Grapes
commons/src/main/java/org/axway/grapes/commons/datamodel/DataModelFactory.java
DataModelFactory.createLicense
public static License createLicense(final String name, final String longName, final String comments, final String regexp, final String url){ final License license = new License(); license.setName(name); license.setLongName(longName); license.setComments(comments); license.setRegexp(regexp); license.setUrl(...
java
public static License createLicense(final String name, final String longName, final String comments, final String regexp, final String url){ final License license = new License(); license.setName(name); license.setLongName(longName); license.setComments(comments); license.setRegexp(regexp); license.setUrl(...
[ "public", "static", "License", "createLicense", "(", "final", "String", "name", ",", "final", "String", "longName", ",", "final", "String", "comments", ",", "final", "String", "regexp", ",", "final", "String", "url", ")", "{", "final", "License", "license", ...
Generates a License regarding the parameters. @param name String @param longName String @param comments String @param regexp String @param url String @return License
[ "Generates", "a", "License", "regarding", "the", "parameters", "." ]
train
https://github.com/Axway/Grapes/blob/ce9cc73d85f83eaa5fbc991abb593915a8c8374e/commons/src/main/java/org/axway/grapes/commons/datamodel/DataModelFactory.java#L124-L134
raydac/java-binary-block-parser
jbbp/src/main/java/com/igormaznitsa/jbbp/model/JBBPFieldStruct.java
JBBPFieldStruct.mapTo
public <T> T mapTo(final Class<T> mappingClass, final JBBPMapperCustomFieldProcessor customFieldProcessor) { return JBBPMapper.map(this, mappingClass, customFieldProcessor); }
java
public <T> T mapTo(final Class<T> mappingClass, final JBBPMapperCustomFieldProcessor customFieldProcessor) { return JBBPMapper.map(this, mappingClass, customFieldProcessor); }
[ "public", "<", "T", ">", "T", "mapTo", "(", "final", "Class", "<", "T", ">", "mappingClass", ",", "final", "JBBPMapperCustomFieldProcessor", "customFieldProcessor", ")", "{", "return", "JBBPMapper", ".", "map", "(", "this", ",", "mappingClass", ",", "customFie...
Map the structure fields to a class fields. @param <T> a class type @param mappingClass a mapping class to be mapped by the structure fields, must not be null and must have the default constructor @param customFieldProcessor a custom field processor to provide values for custom mapping fields,...
[ "Map", "the", "structure", "fields", "to", "a", "class", "fields", "." ]
train
https://github.com/raydac/java-binary-block-parser/blob/6d98abcab01e0c72d525ebcc9e7b694f9ce49f5b/jbbp/src/main/java/com/igormaznitsa/jbbp/model/JBBPFieldStruct.java#L258-L260
molgenis/molgenis
molgenis-data-postgresql/src/main/java/org/molgenis/data/postgresql/PostgreSqlRepositoryCollection.java
PostgreSqlRepositoryCollection.updateUnique
private void updateUnique(EntityType entityType, Attribute attr, Attribute updatedAttr) { if (attr.isUnique() && !updatedAttr.isUnique()) { Attribute idAttr = entityType.getIdAttribute(); if (idAttr != null && idAttr.getName().equals(attr.getName())) { throw new MolgenisDataException( ...
java
private void updateUnique(EntityType entityType, Attribute attr, Attribute updatedAttr) { if (attr.isUnique() && !updatedAttr.isUnique()) { Attribute idAttr = entityType.getIdAttribute(); if (idAttr != null && idAttr.getName().equals(attr.getName())) { throw new MolgenisDataException( ...
[ "private", "void", "updateUnique", "(", "EntityType", "entityType", ",", "Attribute", "attr", ",", "Attribute", "updatedAttr", ")", "{", "if", "(", "attr", ".", "isUnique", "(", ")", "&&", "!", "updatedAttr", ".", "isUnique", "(", ")", ")", "{", "Attribute...
Updates unique constraint based on attribute unique changes. @param entityType entity meta data @param attr current attribute @param updatedAttr updated attribute
[ "Updates", "unique", "constraint", "based", "on", "attribute", "unique", "changes", "." ]
train
https://github.com/molgenis/molgenis/blob/b4d0d6b27e6f6c8d7505a3863dc03b589601f987/molgenis-data-postgresql/src/main/java/org/molgenis/data/postgresql/PostgreSqlRepositoryCollection.java#L658-L672
jferard/fastods
fastods/src/main/java/com/github/jferard/fastods/util/ColorHelper.java
ColorHelper.getFromRGB
public Color getFromRGB(final int red, final int green, final int blue) { return this.getFromString("#" + this.toHexString(red) + this.toHexString(green) + this .toHexString(blue)); }
java
public Color getFromRGB(final int red, final int green, final int blue) { return this.getFromString("#" + this.toHexString(red) + this.toHexString(green) + this .toHexString(blue)); }
[ "public", "Color", "getFromRGB", "(", "final", "int", "red", ",", "final", "int", "green", ",", "final", "int", "blue", ")", "{", "return", "this", ".", "getFromString", "(", "\"#\"", "+", "this", ".", "toHexString", "(", "red", ")", "+", "this", ".", ...
Helper function to create any available color string from color values. @param red The red value, 0-255 @param green The green value, 0-255 @param blue The blue value, 0-255 @return The hex string in the format '#rrggbb'
[ "Helper", "function", "to", "create", "any", "available", "color", "string", "from", "color", "values", "." ]
train
https://github.com/jferard/fastods/blob/a034d173083ffa602dc525699b97f753082eaef9/fastods/src/main/java/com/github/jferard/fastods/util/ColorHelper.java#L87-L90
jeremybrooks/jinx
src/main/java/net/jeremybrooks/jinx/api/PhotosGeoApi.java
PhotosGeoApi.setContext
public Response setContext(String photoId, JinxConstants.GeoContext context) throws JinxException { JinxUtils.validateParams(photoId); Map<String, String> params = new TreeMap<>(); params.put("method", "flickr.photos.geo.setContext"); params.put("photo_id", photoId); params.put("context", Integer.to...
java
public Response setContext(String photoId, JinxConstants.GeoContext context) throws JinxException { JinxUtils.validateParams(photoId); Map<String, String> params = new TreeMap<>(); params.put("method", "flickr.photos.geo.setContext"); params.put("photo_id", photoId); params.put("context", Integer.to...
[ "public", "Response", "setContext", "(", "String", "photoId", ",", "JinxConstants", ".", "GeoContext", "context", ")", "throws", "JinxException", "{", "JinxUtils", ".", "validateParams", "(", "photoId", ")", ";", "Map", "<", "String", ",", "String", ">", "para...
Indicate the state of a photo's geotagginess beyond latitude and longitude. <br> Note : photos passed to this method must already be geotagged. <br> This method requires authentication with 'write' permission. @param photoId (Required) The id of the photo to set context data for. @param context (Required) The photo's ...
[ "Indicate", "the", "state", "of", "a", "photo", "s", "geotagginess", "beyond", "latitude", "and", "longitude", ".", "<br", ">", "Note", ":", "photos", "passed", "to", "this", "method", "must", "already", "be", "geotagged", ".", "<br", ">", "This", "method"...
train
https://github.com/jeremybrooks/jinx/blob/ab7a4b7462d08bcbfd9b98bd3f5029771c20f6c6/src/main/java/net/jeremybrooks/jinx/api/PhotosGeoApi.java#L221-L228
Ordinastie/MalisisCore
src/main/java/net/malisis/core/block/component/ItemTransformComponent.java
ItemTransformComponent.firstPerson
public ItemTransformComponent firstPerson(Matrix4f left, Matrix4f right) { this.firstPersonLeftHand = left; this.firstPersonRightHand = right; return this; }
java
public ItemTransformComponent firstPerson(Matrix4f left, Matrix4f right) { this.firstPersonLeftHand = left; this.firstPersonRightHand = right; return this; }
[ "public", "ItemTransformComponent", "firstPerson", "(", "Matrix4f", "left", ",", "Matrix4f", "right", ")", "{", "this", ".", "firstPersonLeftHand", "=", "left", ";", "this", ".", "firstPersonRightHand", "=", "right", ";", "return", "this", ";", "}" ]
Sets the transforms to use for the {@link Item} in first person. @param left the left @param right the right @return the item transform component
[ "Sets", "the", "transforms", "to", "use", "for", "the", "{", "@link", "Item", "}", "in", "first", "person", "." ]
train
https://github.com/Ordinastie/MalisisCore/blob/4f8e1fa462d5c372fc23414482ba9f429881cc54/src/main/java/net/malisis/core/block/component/ItemTransformComponent.java#L80-L85
lessthanoptimal/BoofCV
main/boofcv-recognition/src/main/java/boofcv/alg/fiducial/square/QuadPoseEstimator.java
QuadPoseEstimator.process
public boolean process(Quadrilateral_F64 corners, boolean unitsPixels) { if( unitsPixels ) { pixelCorners.set(corners); pixelToNorm.compute(corners.a.x, corners.a.y, normCorners.a); pixelToNorm.compute(corners.b.x, corners.b.y, normCorners.b); pixelToNorm.compute(corners.c.x, corners.c.y, normCorners.c);...
java
public boolean process(Quadrilateral_F64 corners, boolean unitsPixels) { if( unitsPixels ) { pixelCorners.set(corners); pixelToNorm.compute(corners.a.x, corners.a.y, normCorners.a); pixelToNorm.compute(corners.b.x, corners.b.y, normCorners.b); pixelToNorm.compute(corners.c.x, corners.c.y, normCorners.c);...
[ "public", "boolean", "process", "(", "Quadrilateral_F64", "corners", ",", "boolean", "unitsPixels", ")", "{", "if", "(", "unitsPixels", ")", "{", "pixelCorners", ".", "set", "(", "corners", ")", ";", "pixelToNorm", ".", "compute", "(", "corners", ".", "a", ...
<p>Estimate the 3D pose of the camera from the observed location of the fiducial.</p> MUST call {@link #setFiducial} and {@link #setLensDistoriton} before calling this function. @param corners Observed corners of the fiducial. @param unitsPixels If true the specified corners are in original image pixels or false for...
[ "<p", ">", "Estimate", "the", "3D", "pose", "of", "the", "camera", "from", "the", "observed", "location", "of", "the", "fiducial", ".", "<", "/", "p", ">" ]
train
https://github.com/lessthanoptimal/BoofCV/blob/f01c0243da0ec086285ee722183804d5923bc3ac/main/boofcv-recognition/src/main/java/boofcv/alg/fiducial/square/QuadPoseEstimator.java#L182-L204
Azure/azure-sdk-for-java
labservices/resource-manager/v2018_10_15/src/main/java/com/microsoft/azure/management/labservices/v2018_10_15/implementation/LabsInner.java
LabsInner.updateAsync
public Observable<LabInner> updateAsync(String resourceGroupName, String labAccountName, String labName, LabFragment lab) { return updateWithServiceResponseAsync(resourceGroupName, labAccountName, labName, lab).map(new Func1<ServiceResponse<LabInner>, LabInner>() { @Override public LabIn...
java
public Observable<LabInner> updateAsync(String resourceGroupName, String labAccountName, String labName, LabFragment lab) { return updateWithServiceResponseAsync(resourceGroupName, labAccountName, labName, lab).map(new Func1<ServiceResponse<LabInner>, LabInner>() { @Override public LabIn...
[ "public", "Observable", "<", "LabInner", ">", "updateAsync", "(", "String", "resourceGroupName", ",", "String", "labAccountName", ",", "String", "labName", ",", "LabFragment", "lab", ")", "{", "return", "updateWithServiceResponseAsync", "(", "resourceGroupName", ",", ...
Modify properties of labs. @param resourceGroupName The name of the resource group. @param labAccountName The name of the lab Account. @param labName The name of the lab. @param lab Represents a lab. @throws IllegalArgumentException thrown if parameters fail the validation @return the observable to the LabInner object
[ "Modify", "properties", "of", "labs", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/labservices/resource-manager/v2018_10_15/src/main/java/com/microsoft/azure/management/labservices/v2018_10_15/implementation/LabsInner.java#L864-L871
apiman/apiman
gateway/engine/policies/src/main/java/io/apiman/gateway/engine/policies/AbstractIPListPolicy.java
AbstractIPListPolicy.getRemoteAddr
protected String getRemoteAddr(ApiRequest request, IPListConfig config) { String httpHeader = config.getHttpHeader(); if (httpHeader != null && httpHeader.trim().length() > 0) { String value = (String) request.getHeaders().get(httpHeader); if (value != null) { ret...
java
protected String getRemoteAddr(ApiRequest request, IPListConfig config) { String httpHeader = config.getHttpHeader(); if (httpHeader != null && httpHeader.trim().length() > 0) { String value = (String) request.getHeaders().get(httpHeader); if (value != null) { ret...
[ "protected", "String", "getRemoteAddr", "(", "ApiRequest", "request", ",", "IPListConfig", "config", ")", "{", "String", "httpHeader", "=", "config", ".", "getHttpHeader", "(", ")", ";", "if", "(", "httpHeader", "!=", "null", "&&", "httpHeader", ".", "trim", ...
Gets the remote address for comparison. @param request the request @param config the config
[ "Gets", "the", "remote", "address", "for", "comparison", "." ]
train
https://github.com/apiman/apiman/blob/8c049c2a2f2e4a69bbb6125686a15edd26f29c21/gateway/engine/policies/src/main/java/io/apiman/gateway/engine/policies/AbstractIPListPolicy.java#L35-L44
JOML-CI/JOML
src/org/joml/Intersectionf.java
Intersectionf.intersectCircleCircle
public static boolean intersectCircleCircle(Vector2fc centerA, float radiusSquaredA, Vector2fc centerB, float radiusSquaredB, Vector3f intersectionCenterAndHL) { return intersectCircleCircle(centerA.x(), centerA.y(), radiusSquaredA, centerB.x(), centerB.y(), radiusSquaredB, intersectionCenterAndHL); }
java
public static boolean intersectCircleCircle(Vector2fc centerA, float radiusSquaredA, Vector2fc centerB, float radiusSquaredB, Vector3f intersectionCenterAndHL) { return intersectCircleCircle(centerA.x(), centerA.y(), radiusSquaredA, centerB.x(), centerB.y(), radiusSquaredB, intersectionCenterAndHL); }
[ "public", "static", "boolean", "intersectCircleCircle", "(", "Vector2fc", "centerA", ",", "float", "radiusSquaredA", ",", "Vector2fc", "centerB", ",", "float", "radiusSquaredB", ",", "Vector3f", "intersectionCenterAndHL", ")", "{", "return", "intersectCircleCircle", "("...
Test whether the one circle with center <code>centerA</code> and square radius <code>radiusSquaredA</code> intersects the other circle with center <code>centerB</code> and square radius <code>radiusSquaredB</code>, and store the center of the line segment of intersection in the <code>(x, y)</code> components of the sup...
[ "Test", "whether", "the", "one", "circle", "with", "center", "<code", ">", "centerA<", "/", "code", ">", "and", "square", "radius", "<code", ">", "radiusSquaredA<", "/", "code", ">", "intersects", "the", "other", "circle", "with", "center", "<code", ">", "...
train
https://github.com/JOML-CI/JOML/blob/ce2652fc236b42bda3875c591f8e6645048a678f/src/org/joml/Intersectionf.java#L3756-L3758
looly/hutool
hutool-crypto/src/main/java/cn/hutool/crypto/digest/HMac.java
HMac.digestHex
public String digestHex(InputStream data, int bufferLength) { return HexUtil.encodeHexStr(digest(data, bufferLength)); }
java
public String digestHex(InputStream data, int bufferLength) { return HexUtil.encodeHexStr(digest(data, bufferLength)); }
[ "public", "String", "digestHex", "(", "InputStream", "data", ",", "int", "bufferLength", ")", "{", "return", "HexUtil", ".", "encodeHexStr", "(", "digest", "(", "data", ",", "bufferLength", ")", ")", ";", "}" ]
生成摘要,并转为16进制字符串<br> 使用默认缓存大小,见 {@link IoUtil#DEFAULT_BUFFER_SIZE} @param data 被摘要数据 @param bufferLength 缓存长度,不足1使用 {@link IoUtil#DEFAULT_BUFFER_SIZE} 做为默认值 @return 摘要
[ "生成摘要,并转为16进制字符串<br", ">", "使用默认缓存大小,见", "{", "@link", "IoUtil#DEFAULT_BUFFER_SIZE", "}" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-crypto/src/main/java/cn/hutool/crypto/digest/HMac.java#L252-L254
lievendoclo/Valkyrie-RCP
valkyrie-rcp-core/src/main/java/org/valkyriercp/form/binding/support/AbstractBinderSelectionStrategy.java
AbstractBinderSelectionStrategy.findBinderByPropertyName
protected Binder findBinderByPropertyName(Class parentObjectType, String propertyName) { PropertyNameKey key = new PropertyNameKey(parentObjectType, propertyName); Binder binder = (Binder)propertyNameBinders.get(key); if (binder == null) { // if no direct match was found try to find ...
java
protected Binder findBinderByPropertyName(Class parentObjectType, String propertyName) { PropertyNameKey key = new PropertyNameKey(parentObjectType, propertyName); Binder binder = (Binder)propertyNameBinders.get(key); if (binder == null) { // if no direct match was found try to find ...
[ "protected", "Binder", "findBinderByPropertyName", "(", "Class", "parentObjectType", ",", "String", "propertyName", ")", "{", "PropertyNameKey", "key", "=", "new", "PropertyNameKey", "(", "parentObjectType", ",", "propertyName", ")", ";", "Binder", "binder", "=", "(...
Try to find a binder for the provided parentObjectType and propertyName. If no direct match found try to find binder for any superclass of the provided objectType which also has the same propertyName.
[ "Try", "to", "find", "a", "binder", "for", "the", "provided", "parentObjectType", "and", "propertyName", ".", "If", "no", "direct", "match", "found", "try", "to", "find", "binder", "for", "any", "superclass", "of", "the", "provided", "objectType", "which", "...
train
https://github.com/lievendoclo/Valkyrie-RCP/blob/6aad6e640b348cda8f3b0841f6e42025233f1eb8/valkyrie-rcp-core/src/main/java/org/valkyriercp/form/binding/support/AbstractBinderSelectionStrategy.java#L93-L113