repository_name
stringlengths
7
58
func_path_in_repository
stringlengths
11
218
func_name
stringlengths
4
140
whole_func_string
stringlengths
153
5.32k
language
stringclasses
1 value
func_code_string
stringlengths
72
4k
func_code_tokens
listlengths
20
832
func_documentation_string
stringlengths
61
2k
func_documentation_tokens
listlengths
1
647
split_name
stringclasses
1 value
func_code_url
stringlengths
102
339
alkacon/opencms-core
src/org/opencms/ui/apps/git/CmsGitCheckin.java
CmsGitCheckin.checkIn
public int checkIn() { """ Start export and check in of the selected modules. @return The exit code of the check in procedure (like a script's exit code). """ try { synchronized (STATIC_LOCK) { m_logStream = new PrintStream(new FileOutputStream(DEFAULT_LOGFILE_PATH, false)...
java
public int checkIn() { try { synchronized (STATIC_LOCK) { m_logStream = new PrintStream(new FileOutputStream(DEFAULT_LOGFILE_PATH, false)); CmsObject cms = getCmsObject(); if (cms != null) { return checkInInternal(); ...
[ "public", "int", "checkIn", "(", ")", "{", "try", "{", "synchronized", "(", "STATIC_LOCK", ")", "{", "m_logStream", "=", "new", "PrintStream", "(", "new", "FileOutputStream", "(", "DEFAULT_LOGFILE_PATH", ",", "false", ")", ")", ";", "CmsObject", "cms", "=", ...
Start export and check in of the selected modules. @return The exit code of the check in procedure (like a script's exit code).
[ "Start", "export", "and", "check", "in", "of", "the", "selected", "modules", "." ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/ui/apps/git/CmsGitCheckin.java#L232-L249
google/j2objc
jre_emul/android/platform/libcore/ojluni/src/main/java/java/time/LocalTime.java
LocalTime.plusMinutes
public LocalTime plusMinutes(long minutesToAdd) { """ Returns a copy of this {@code LocalTime} with the specified number of minutes added. <p> This adds the specified number of minutes to this time, returning a new time. The calculation wraps around midnight. <p> This instance is immutable and unaffected by t...
java
public LocalTime plusMinutes(long minutesToAdd) { if (minutesToAdd == 0) { return this; } int mofd = hour * MINUTES_PER_HOUR + minute; int newMofd = ((int) (minutesToAdd % MINUTES_PER_DAY) + mofd + MINUTES_PER_DAY) % MINUTES_PER_DAY; if (mofd == newMofd) { ...
[ "public", "LocalTime", "plusMinutes", "(", "long", "minutesToAdd", ")", "{", "if", "(", "minutesToAdd", "==", "0", ")", "{", "return", "this", ";", "}", "int", "mofd", "=", "hour", "*", "MINUTES_PER_HOUR", "+", "minute", ";", "int", "newMofd", "=", "(", ...
Returns a copy of this {@code LocalTime} with the specified number of minutes added. <p> This adds the specified number of minutes to this time, returning a new time. The calculation wraps around midnight. <p> This instance is immutable and unaffected by this method call. @param minutesToAdd the minutes to add, may b...
[ "Returns", "a", "copy", "of", "this", "{", "@code", "LocalTime", "}", "with", "the", "specified", "number", "of", "minutes", "added", ".", "<p", ">", "This", "adds", "the", "specified", "number", "of", "minutes", "to", "this", "time", "returning", "a", "...
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/time/LocalTime.java#L1085-L1097
google/j2objc
jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/impl/duration/Period.java
Period.setTimeUnitInternalValue
private Period setTimeUnitInternalValue(TimeUnit unit, int value) { """ Sets the period to have the provided value, 1/1000 of the unit plus 1. Thus unset values are '0', 1' is the set value '0', 2 is the set value '1/1000', 3 is the set value '2/1000' etc. @param p the period to change @param value the int va...
java
private Period setTimeUnitInternalValue(TimeUnit unit, int value) { int ord = unit.ordinal; if (counts[ord] != value) { int[] newCounts = new int[counts.length]; for (int i = 0; i < counts.length; ++i) { newCounts[i] = counts[i]; } newCounts[ord] = value; return new Period(...
[ "private", "Period", "setTimeUnitInternalValue", "(", "TimeUnit", "unit", ",", "int", "value", ")", "{", "int", "ord", "=", "unit", ".", "ordinal", ";", "if", "(", "counts", "[", "ord", "]", "!=", "value", ")", "{", "int", "[", "]", "newCounts", "=", ...
Sets the period to have the provided value, 1/1000 of the unit plus 1. Thus unset values are '0', 1' is the set value '0', 2 is the set value '1/1000', 3 is the set value '2/1000' etc. @param p the period to change @param value the int value as described above. @eturn the new Period object.
[ "Sets", "the", "period", "to", "have", "the", "provided", "value", "1", "/", "1000", "of", "the", "unit", "plus", "1", ".", "Thus", "unset", "values", "are", "0", "1", "is", "the", "set", "value", "0", "2", "is", "the", "set", "value", "1", "/", ...
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/impl/duration/Period.java#L331-L342
looly/hutool
hutool-core/src/main/java/cn/hutool/core/io/watch/WatchUtil.java
WatchUtil.createModify
public static WatchMonitor createModify(URL url, int maxDepth, Watcher watcher) { """ 创建并初始化监听,监听修改事件 @param url URL @param maxDepth 当监听目录时,监听目录的最大深度,当设置值为1(或小于1)时,表示不递归监听子目录 @param watcher {@link Watcher} @return {@link WatchMonitor} @since 4.5.2 """ return createModify(URLUtil.toURI(url), maxDepth,...
java
public static WatchMonitor createModify(URL url, int maxDepth, Watcher watcher) { return createModify(URLUtil.toURI(url), maxDepth, watcher); }
[ "public", "static", "WatchMonitor", "createModify", "(", "URL", "url", ",", "int", "maxDepth", ",", "Watcher", "watcher", ")", "{", "return", "createModify", "(", "URLUtil", ".", "toURI", "(", "url", ")", ",", "maxDepth", ",", "watcher", ")", ";", "}" ]
创建并初始化监听,监听修改事件 @param url URL @param maxDepth 当监听目录时,监听目录的最大深度,当设置值为1(或小于1)时,表示不递归监听子目录 @param watcher {@link Watcher} @return {@link WatchMonitor} @since 4.5.2
[ "创建并初始化监听,监听修改事件" ]
train
https://github.com/looly/hutool/blob/bbd74eda4c7e8a81fe7a991fa6c2276eec062e6a/hutool-core/src/main/java/cn/hutool/core/io/watch/WatchUtil.java#L275-L277
opendatatrentino/s-match
src/main/java/it/unitn/disi/common/components/Configurable.java
Configurable.getComponentProperties
protected static Properties getComponentProperties(String componentPrefix, Properties properties) { """ Returns only properties that start with componentPrefix, removing this prefix. @param componentPrefix a prefix to search @param properties properties @return properties that start with componentPrefix ...
java
protected static Properties getComponentProperties(String componentPrefix, Properties properties) { Properties result = new Properties(); if (null != componentPrefix) { int componentPrefixLength = componentPrefix.length(); for (String propertyName : properties.stringPropertyN...
[ "protected", "static", "Properties", "getComponentProperties", "(", "String", "componentPrefix", ",", "Properties", "properties", ")", "{", "Properties", "result", "=", "new", "Properties", "(", ")", ";", "if", "(", "null", "!=", "componentPrefix", ")", "{", "in...
Returns only properties that start with componentPrefix, removing this prefix. @param componentPrefix a prefix to search @param properties properties @return properties that start with componentPrefix
[ "Returns", "only", "properties", "that", "start", "with", "componentPrefix", "removing", "this", "prefix", "." ]
train
https://github.com/opendatatrentino/s-match/blob/ba5982ef406b7010c2f92592e43887a485935aa1/src/main/java/it/unitn/disi/common/components/Configurable.java#L61-L72
pressgang-ccms/PressGangCCMSBuilder
src/main/java/org/jboss/pressgang/ccms/contentspec/builder/PublicanPODocBookBuilder.java
PublicanPODocBookBuilder.addStringsFromRelationships
protected void addStringsFromRelationships(final BuildData buildData, final List<Relationship> relationships, final String roleName, final Map<String, TranslationDetails> translations) { """ Add the translation strings from a list of relationships. @param buildData Information and data structure...
java
protected void addStringsFromRelationships(final BuildData buildData, final List<Relationship> relationships, final String roleName, final Map<String, TranslationDetails> translations) { final boolean useFixedUrls = buildData.isUseFixedUrls(); for (final Relationship relationship : relation...
[ "protected", "void", "addStringsFromRelationships", "(", "final", "BuildData", "buildData", ",", "final", "List", "<", "Relationship", ">", "relationships", ",", "final", "String", "roleName", ",", "final", "Map", "<", "String", ",", "TranslationDetails", ">", "tr...
Add the translation strings from a list of relationships. @param buildData Information and data structures for the build. @param relationships The list of relationships to add strings for. @param roleName The role name to be used on the relationship xrefs. @param translations The mapping of original strings ...
[ "Add", "the", "translation", "strings", "from", "a", "list", "of", "relationships", "." ]
train
https://github.com/pressgang-ccms/PressGangCCMSBuilder/blob/5436d36ba1b3c5baa246b270e5fc350e6778bce8/src/main/java/org/jboss/pressgang/ccms/contentspec/builder/PublicanPODocBookBuilder.java#L1225-L1240
Nexmo/nexmo-java
src/main/java/com/nexmo/client/voice/VoiceClient.java
VoiceClient.startStream
public StreamResponse startStream(String uuid, String streamUrl, int loop) throws IOException, NexmoClientException { """ Stream audio to an ongoing call. @param uuid The UUID of the call, obtained from the object returned by {@link #createCall(Call)}. This value can be obtained with {@link CallEvent#getU...
java
public StreamResponse startStream(String uuid, String streamUrl, int loop) throws IOException, NexmoClientException { return streams.put(new StreamRequest(uuid, streamUrl, loop)); }
[ "public", "StreamResponse", "startStream", "(", "String", "uuid", ",", "String", "streamUrl", ",", "int", "loop", ")", "throws", "IOException", ",", "NexmoClientException", "{", "return", "streams", ".", "put", "(", "new", "StreamRequest", "(", "uuid", ",", "s...
Stream audio to an ongoing call. @param uuid The UUID of the call, obtained from the object returned by {@link #createCall(Call)}. This value can be obtained with {@link CallEvent#getUuid()} @param streamUrl A URL of an audio file in MP3 or 16-bit WAV format, to be streamed to the call. @param loop The numbe...
[ "Stream", "audio", "to", "an", "ongoing", "call", "." ]
train
https://github.com/Nexmo/nexmo-java/blob/7427eff6d6baa5a5bd9197fa096bcf2564191cf5/src/main/java/com/nexmo/client/voice/VoiceClient.java#L206-L208
ModeShape/modeshape
modeshape-schematic/src/main/java/org/modeshape/schematic/internal/schema/DocumentTransformer.java
DocumentTransformer.convertValuesWithMismatchedTypes
public static Document convertValuesWithMismatchedTypes( Document original, SchemaLibrary.Results results ) { """ Return a copy of the supplied document that contains converted values for all of the fields (including in the nested documents and arrays) ...
java
public static Document convertValuesWithMismatchedTypes( Document original, SchemaLibrary.Results results ) { if (results == null || !results.hasProblems()) return original; // Create a conversion object for each of the field values with mism...
[ "public", "static", "Document", "convertValuesWithMismatchedTypes", "(", "Document", "original", ",", "SchemaLibrary", ".", "Results", "results", ")", "{", "if", "(", "results", "==", "null", "||", "!", "results", ".", "hasProblems", "(", ")", ")", "return", "...
Return a copy of the supplied document that contains converted values for all of the fields (including in the nested documents and arrays) that have values that are of the wrong type but can be converted to be of the correct type. <p> This method does nothing and returns the original document if there are no changes to...
[ "Return", "a", "copy", "of", "the", "supplied", "document", "that", "contains", "converted", "values", "for", "all", "of", "the", "fields", "(", "including", "in", "the", "nested", "documents", "and", "arrays", ")", "that", "have", "values", "that", "are", ...
train
https://github.com/ModeShape/modeshape/blob/794cfdabb67a90f24629c4fff0424a6125f8f95b/modeshape-schematic/src/main/java/org/modeshape/schematic/internal/schema/DocumentTransformer.java#L266-L281
greese/dasein-persist
src/main/java/org/dasein/persist/HandlerSocketCache.java
HandlerSocketCache.getSession
private IndexSession getSession(String index, String... columns) throws PersistenceException { """ Opens a connection and a session to a HandlerSocket server. Specify the table's index to hit as well as the columns you want. A common index is PRIMRY - for the primary key. You may also have a multi-column key ...
java
private IndexSession getSession(String index, String... columns) throws PersistenceException { IndexSession session = null; String sessionKey = index + Arrays.hashCode(columns); // both index and columns play a role in opening a session try { if (hsClient == null) { hsClient = new HSClientImpl(handlerSo...
[ "private", "IndexSession", "getSession", "(", "String", "index", ",", "String", "...", "columns", ")", "throws", "PersistenceException", "{", "IndexSession", "session", "=", "null", ";", "String", "sessionKey", "=", "index", "+", "Arrays", ".", "hashCode", "(", ...
Opens a connection and a session to a HandlerSocket server. Specify the table's index to hit as well as the columns you want. A common index is PRIMRY - for the primary key. You may also have a multi-column key named NAME_EMAIL with columns (`name`,`email`).
[ "Opens", "a", "connection", "and", "a", "session", "to", "a", "HandlerSocket", "server", ".", "Specify", "the", "table", "s", "index", "to", "hit", "as", "well", "as", "the", "columns", "you", "want", ".", "A", "common", "index", "is", "PRIMRY", "-", "...
train
https://github.com/greese/dasein-persist/blob/1104621ad1670a45488b093b984ec1db4c7be781/src/main/java/org/dasein/persist/HandlerSocketCache.java#L319-L339
UrielCh/ovh-java-sdk
ovh-java-sdk-order/src/main/java/net/minidev/ovh/api/ApiOvhOrder.java
ApiOvhOrder.email_exchange_organizationName_service_exchangeService_outlook_GET
public ArrayList<String> email_exchange_organizationName_service_exchangeService_outlook_GET(String organizationName, String exchangeService, OvhOutlookVersionEnum licence, String primaryEmailAddress) throws IOException { """ Get allowed durations for 'outlook' option REST: GET /order/email/exchange/{organizati...
java
public ArrayList<String> email_exchange_organizationName_service_exchangeService_outlook_GET(String organizationName, String exchangeService, OvhOutlookVersionEnum licence, String primaryEmailAddress) throws IOException { String qPath = "/order/email/exchange/{organizationName}/service/{exchangeService}/outlook"; S...
[ "public", "ArrayList", "<", "String", ">", "email_exchange_organizationName_service_exchangeService_outlook_GET", "(", "String", "organizationName", ",", "String", "exchangeService", ",", "OvhOutlookVersionEnum", "licence", ",", "String", "primaryEmailAddress", ")", "throws", ...
Get allowed durations for 'outlook' option REST: GET /order/email/exchange/{organizationName}/service/{exchangeService}/outlook @param licence [required] Outlook version @param primaryEmailAddress [required] Primary email address for account which You want to buy an outlook @param organizationName [required] The inter...
[ "Get", "allowed", "durations", "for", "outlook", "option" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-order/src/main/java/net/minidev/ovh/api/ApiOvhOrder.java#L3870-L3877
iig-uni-freiburg/SEWOL
src/de/uni/freiburg/iig/telematik/sewol/context/process/ProcessContext.java
ProcessContext.validateAttribute
public void validateAttribute(String attribute) throws CompatibilityException { """ Checks if the given attribute is known, i.e. is contained in the attribute list. @param attribute Attribute to be checked. @throws IllegalArgumentException If the given attribute is not known. """ try { ...
java
public void validateAttribute(String attribute) throws CompatibilityException { try { super.validateObject(attribute); } catch (CompatibilityException e) { throw new CompatibilityException("Unknown attribute: " + attribute, e); ...
[ "public", "void", "validateAttribute", "(", "String", "attribute", ")", "throws", "CompatibilityException", "{", "try", "{", "super", ".", "validateObject", "(", "attribute", ")", ";", "}", "catch", "(", "CompatibilityException", "e", ")", "{", "throw", "new", ...
Checks if the given attribute is known, i.e. is contained in the attribute list. @param attribute Attribute to be checked. @throws IllegalArgumentException If the given attribute is not known.
[ "Checks", "if", "the", "given", "attribute", "is", "known", "i", ".", "e", ".", "is", "contained", "in", "the", "attribute", "list", "." ]
train
https://github.com/iig-uni-freiburg/SEWOL/blob/e791cb07a6e62ecf837d760d58a25f32fbf6bbca/src/de/uni/freiburg/iig/telematik/sewol/context/process/ProcessContext.java#L886-L892
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/util/UserProperties.java
UserProperties.init
public void init(MainApplication app, String strKey) { """ Constructor. @param app The parent application for these properties. @param strKey The lookup key for these properties. """ m_app = app; if (strKey == null) strKey = Constants.BLANK; m_strKey = strKey; // + "\\"; ...
java
public void init(MainApplication app, String strKey) { m_app = app; if (strKey == null) strKey = Constants.BLANK; m_strKey = strKey; // + "\\"; m_app.addUserProperties(this); }
[ "public", "void", "init", "(", "MainApplication", "app", ",", "String", "strKey", ")", "{", "m_app", "=", "app", ";", "if", "(", "strKey", "==", "null", ")", "strKey", "=", "Constants", ".", "BLANK", ";", "m_strKey", "=", "strKey", ";", "// + \"\\\\\";",...
Constructor. @param app The parent application for these properties. @param strKey The lookup key for these properties.
[ "Constructor", "." ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/util/UserProperties.java#L79-L86
OpenLiberty/open-liberty
dev/com.ibm.ws.monitor/src/com/ibm/ws/monitor/internal/ProbeManagerImpl.java
ProbeManagerImpl.addActiveProbesforListener
public void addActiveProbesforListener(ProbeListener listener, Collection<ProbeImpl> probes) { """ Update the appropriate collections to reflect recently activated probes for the specified listener. @param listener the listener with recently activated probes @param probes the collection of probes that were ac...
java
public void addActiveProbesforListener(ProbeListener listener, Collection<ProbeImpl> probes) { // Add the probes for the specified listener. This is purely additive. // Since a listener's configuration can't be updated after registration, // we're adding probes for recently initialized / modifi...
[ "public", "void", "addActiveProbesforListener", "(", "ProbeListener", "listener", ",", "Collection", "<", "ProbeImpl", ">", "probes", ")", "{", "// Add the probes for the specified listener. This is purely additive.", "// Since a listener's configuration can't be updated after registr...
Update the appropriate collections to reflect recently activated probes for the specified listener. @param listener the listener with recently activated probes @param probes the collection of probes that were activated
[ "Update", "the", "appropriate", "collections", "to", "reflect", "recently", "activated", "probes", "for", "the", "specified", "listener", "." ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.monitor/src/com/ibm/ws/monitor/internal/ProbeManagerImpl.java#L673-L682
jhalterman/failsafe
src/main/java/net/jodah/failsafe/RetryPolicy.java
RetryPolicy.isAbortable
public boolean isAbortable(R result, Throwable failure) { """ Returns whether an execution result can be aborted given the configured abort conditions. @see #abortOn(Class...) @see #abortOn(List) @see #abortOn(Predicate) @see #abortIf(BiPredicate) @see #abortIf(Predicate) @see #abortWhen(R) """ for...
java
public boolean isAbortable(R result, Throwable failure) { for (BiPredicate<R, Throwable> predicate : abortConditions) { try { if (predicate.test(result, failure)) return true; } catch (Exception t) { // Ignore confused user-supplied predicates. // They should not be all...
[ "public", "boolean", "isAbortable", "(", "R", "result", ",", "Throwable", "failure", ")", "{", "for", "(", "BiPredicate", "<", "R", ",", "Throwable", ">", "predicate", ":", "abortConditions", ")", "{", "try", "{", "if", "(", "predicate", ".", "test", "("...
Returns whether an execution result can be aborted given the configured abort conditions. @see #abortOn(Class...) @see #abortOn(List) @see #abortOn(Predicate) @see #abortIf(BiPredicate) @see #abortIf(Predicate) @see #abortWhen(R)
[ "Returns", "whether", "an", "execution", "result", "can", "be", "aborted", "given", "the", "configured", "abort", "conditions", "." ]
train
https://github.com/jhalterman/failsafe/blob/65fcd3a82f7b232d2ff59bc525a59d693dd8e223/src/main/java/net/jodah/failsafe/RetryPolicy.java#L243-L254
windup/windup
rules-java/api/src/main/java/org/jboss/windup/rules/apps/java/scan/provider/DiscoverMavenProjectsRuleProvider.java
DiscoverMavenProjectsRuleProvider.getMavenProject
private MavenProjectModel getMavenProject(MavenProjectService mavenProjectService, String groupId, String artifactId, String version) { """ This will return a {@link MavenProjectModel} with the give gav, preferring one that has been found in the input application as opposed to a stub. """ Iterable<Mav...
java
private MavenProjectModel getMavenProject(MavenProjectService mavenProjectService, String groupId, String artifactId, String version) { Iterable<MavenProjectModel> possibleProjects = mavenProjectService.findByGroupArtifactVersion(groupId, artifactId, version); MavenProjectModel project = null; ...
[ "private", "MavenProjectModel", "getMavenProject", "(", "MavenProjectService", "mavenProjectService", ",", "String", "groupId", ",", "String", "artifactId", ",", "String", "version", ")", "{", "Iterable", "<", "MavenProjectModel", ">", "possibleProjects", "=", "mavenPro...
This will return a {@link MavenProjectModel} with the give gav, preferring one that has been found in the input application as opposed to a stub.
[ "This", "will", "return", "a", "{" ]
train
https://github.com/windup/windup/blob/6668f09e7f012d24a0b4212ada8809417225b2ad/rules-java/api/src/main/java/org/jboss/windup/rules/apps/java/scan/provider/DiscoverMavenProjectsRuleProvider.java#L378-L394
TheHortonMachine/hortonmachine
gears/src/main/java/org/hortonmachine/gears/io/dxfdwg/libs/dwg/utils/ByteUtils.java
ByteUtils.bytesToShort
public static final short bytesToShort( byte[] data, int[] offset ) { """ Return the <code>short</code> represented by the bytes in <code>data</code> staring at offset <code>offset[0]</code>. @param data the array from which to read @param offset A single element array whose first element is the index in dat...
java
public static final short bytesToShort( byte[] data, int[] offset ) { /** * TODO: We use network-order within OceanStore, but temporarily * supporting intel-order to work with some JNI code until JNI code is * set to interoperate with network-order. */ short result = ...
[ "public", "static", "final", "short", "bytesToShort", "(", "byte", "[", "]", "data", ",", "int", "[", "]", "offset", ")", "{", "/**\n * TODO: We use network-order within OceanStore, but temporarily\n * supporting intel-order to work with some JNI code until JNI code...
Return the <code>short</code> represented by the bytes in <code>data</code> staring at offset <code>offset[0]</code>. @param data the array from which to read @param offset A single element array whose first element is the index in data from which to begin reading on function entry, and which on function exit has been...
[ "Return", "the", "<code", ">", "short<", "/", "code", ">", "represented", "by", "the", "bytes", "in", "<code", ">", "data<", "/", "code", ">", "staring", "at", "offset", "<code", ">", "offset", "[", "0", "]", "<", "/", "code", ">", "." ]
train
https://github.com/TheHortonMachine/hortonmachine/blob/d2b436bbdf951dc1fda56096a42dbc0eae4d35a5/gears/src/main/java/org/hortonmachine/gears/io/dxfdwg/libs/dwg/utils/ByteUtils.java#L106-L120
hyperledger/fabric-sdk-java
src/main/java/org/hyperledger/fabric/sdk/Channel.java
Channel.sendTransaction
public CompletableFuture<TransactionEvent> sendTransaction(Collection<? extends ProposalResponse> proposalResponses, Collection<Orderer> orderers) { """ Send transaction to one of the specified orderers using the usercontext set on the client.. @param proposalResponses The proposal responses to be sent to the o...
java
public CompletableFuture<TransactionEvent> sendTransaction(Collection<? extends ProposalResponse> proposalResponses, Collection<Orderer> orderers) { return sendTransaction(proposalResponses, orderers, client.getUserContext()); }
[ "public", "CompletableFuture", "<", "TransactionEvent", ">", "sendTransaction", "(", "Collection", "<", "?", "extends", "ProposalResponse", ">", "proposalResponses", ",", "Collection", "<", "Orderer", ">", "orderers", ")", "{", "return", "sendTransaction", "(", "pro...
Send transaction to one of the specified orderers using the usercontext set on the client.. @param proposalResponses The proposal responses to be sent to the orderer @param orderers The orderers to send the transaction to. @return a future allowing access to the result of the transaction invocation once compl...
[ "Send", "transaction", "to", "one", "of", "the", "specified", "orderers", "using", "the", "usercontext", "set", "on", "the", "client", ".." ]
train
https://github.com/hyperledger/fabric-sdk-java/blob/4a2d7b3408b8b0a1ed812aa36942c438159c37a0/src/main/java/org/hyperledger/fabric/sdk/Channel.java#L4657-L4660
google/j2objc
jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/Calendar.java
Calendar.handleGetMonthLength
protected int handleGetMonthLength(int extendedYear, int month) { """ Returns the number of days in the given month of the given extended year of this calendar system. Subclasses should override this method if they can provide a more correct or more efficient implementation than the default implementation in C...
java
protected int handleGetMonthLength(int extendedYear, int month) { return handleComputeMonthStart(extendedYear, month+1, true) - handleComputeMonthStart(extendedYear, month, true); }
[ "protected", "int", "handleGetMonthLength", "(", "int", "extendedYear", ",", "int", "month", ")", "{", "return", "handleComputeMonthStart", "(", "extendedYear", ",", "month", "+", "1", ",", "true", ")", "-", "handleComputeMonthStart", "(", "extendedYear", ",", "...
Returns the number of days in the given month of the given extended year of this calendar system. Subclasses should override this method if they can provide a more correct or more efficient implementation than the default implementation in Calendar.
[ "Returns", "the", "number", "of", "days", "in", "the", "given", "month", "of", "the", "given", "extended", "year", "of", "this", "calendar", "system", ".", "Subclasses", "should", "override", "this", "method", "if", "they", "can", "provide", "a", "more", "...
train
https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/Calendar.java#L5648-L5651
wildfly/wildfly-core
remoting/subsystem/src/main/java/org/jboss/as/remoting/RemotingServices.java
RemotingServices.channelServiceName
public static ServiceName channelServiceName(final ServiceName endpointName, final String channelName) { """ Create the service name for a channel @param channelName the channel name @return the service name """ return endpointName.append("channel").append(channelName); }
java
public static ServiceName channelServiceName(final ServiceName endpointName, final String channelName) { return endpointName.append("channel").append(channelName); }
[ "public", "static", "ServiceName", "channelServiceName", "(", "final", "ServiceName", "endpointName", ",", "final", "String", "channelName", ")", "{", "return", "endpointName", ".", "append", "(", "\"channel\"", ")", ".", "append", "(", "channelName", ")", ";", ...
Create the service name for a channel @param channelName the channel name @return the service name
[ "Create", "the", "service", "name", "for", "a", "channel" ]
train
https://github.com/wildfly/wildfly-core/blob/cfaf0479dcbb2d320a44c5374b93b944ec39fade/remoting/subsystem/src/main/java/org/jboss/as/remoting/RemotingServices.java#L96-L98
docusign/docusign-java-client
src/main/java/com/docusign/esign/api/UsersApi.java
UsersApi.getInformation
public UserInformation getInformation(String accountId, String userId) throws ApiException { """ Gets the user information for a specified user. Retrieves the user information for the specified user. To return additional user information that details the last login date, login status, and the user&#39;s passwor...
java
public UserInformation getInformation(String accountId, String userId) throws ApiException { return getInformation(accountId, userId, null); }
[ "public", "UserInformation", "getInformation", "(", "String", "accountId", ",", "String", "userId", ")", "throws", "ApiException", "{", "return", "getInformation", "(", "accountId", ",", "userId", ",", "null", ")", ";", "}" ]
Gets the user information for a specified user. Retrieves the user information for the specified user. To return additional user information that details the last login date, login status, and the user&#39;s password expiration date, set the optional &#x60;additional_info&#x60; query string parameter to **true**. @pa...
[ "Gets", "the", "user", "information", "for", "a", "specified", "user", ".", "Retrieves", "the", "user", "information", "for", "the", "specified", "user", ".", "To", "return", "additional", "user", "information", "that", "details", "the", "last", "login", "date...
train
https://github.com/docusign/docusign-java-client/blob/17ae82ace0f023e98edf813be832950568212e34/src/main/java/com/docusign/esign/api/UsersApi.java#L619-L621
taimos/RESTUtils
src/main/java/de/taimos/restutils/RESTAssert.java
RESTAssert.assertEquals
@SuppressWarnings("null") public static void assertEquals(final Object one, final Object two, final StatusType status) { """ assert that objects are equal.<br> This means they are both <i>null</i> or <code>one.equals(two)</code> returns <i>true</i> @param one the first object @param two the second object @p...
java
@SuppressWarnings("null") public static void assertEquals(final Object one, final Object two, final StatusType status) { if ((one == null) && (two == null)) { return; } RESTAssert.assertNotNull(one, status); RESTAssert.assertTrue(one.equals(two), status); }
[ "@", "SuppressWarnings", "(", "\"null\"", ")", "public", "static", "void", "assertEquals", "(", "final", "Object", "one", ",", "final", "Object", "two", ",", "final", "StatusType", "status", ")", "{", "if", "(", "(", "one", "==", "null", ")", "&&", "(", ...
assert that objects are equal.<br> This means they are both <i>null</i> or <code>one.equals(two)</code> returns <i>true</i> @param one the first object @param two the second object @param status the status code to throw @throws WebApplicationException with given status code
[ "assert", "that", "objects", "are", "equal", ".", "<br", ">", "This", "means", "they", "are", "both", "<i", ">", "null<", "/", "i", ">", "or", "<code", ">", "one", ".", "equals", "(", "two", ")", "<", "/", "code", ">", "returns", "<i", ">", "true...
train
https://github.com/taimos/RESTUtils/blob/bdb1bf9a2eb13ede0eec6f071c10cb2698313501/src/main/java/de/taimos/restutils/RESTAssert.java#L251-L258
xcesco/kripton
kripton-processor/src/main/java/com/abubusoft/kripton/processor/sqlite/BindDataSourceBuilder.java
BindDataSourceBuilder.generateDaoUids
public static void generateDaoUids(TypeSpec.Builder classBuilder, SQLiteDatabaseSchema schema) { """ Generate Dao's UID. If specified, prefix will be used to @param classBuilder the class builder @param schema the schema """ for (SQLiteDaoDefinition dao : schema.getCollection()) { classBuilder.add...
java
public static void generateDaoUids(TypeSpec.Builder classBuilder, SQLiteDatabaseSchema schema) { for (SQLiteDaoDefinition dao : schema.getCollection()) { classBuilder.addField( FieldSpec.builder(Integer.TYPE, dao.daoUidName, Modifier.FINAL, Modifier.STATIC, Modifier.PUBLIC) .initializer("" + dao.daoU...
[ "public", "static", "void", "generateDaoUids", "(", "TypeSpec", ".", "Builder", "classBuilder", ",", "SQLiteDatabaseSchema", "schema", ")", "{", "for", "(", "SQLiteDaoDefinition", "dao", ":", "schema", ".", "getCollection", "(", ")", ")", "{", "classBuilder", "....
Generate Dao's UID. If specified, prefix will be used to @param classBuilder the class builder @param schema the schema
[ "Generate", "Dao", "s", "UID", ".", "If", "specified", "prefix", "will", "be", "used", "to" ]
train
https://github.com/xcesco/kripton/blob/90de2c0523d39b99e81b8d38aa996898762f594a/kripton-processor/src/main/java/com/abubusoft/kripton/processor/sqlite/BindDataSourceBuilder.java#L445-L454
Stratio/bdt
src/main/java/com/stratio/qa/specs/MiscSpec.java
MiscSpec.saveInEnvironment
@Given("^I save \'(.+?)\' in variable \'(.+?)\'$") public void saveInEnvironment(String value, String envVar) { """ Save value for future use. @param value value to be saved @param envVar thread environment variable where to store the value """ ThreadProperty.set(envVar, value); }
java
@Given("^I save \'(.+?)\' in variable \'(.+?)\'$") public void saveInEnvironment(String value, String envVar) { ThreadProperty.set(envVar, value); }
[ "@", "Given", "(", "\"^I save \\'(.+?)\\' in variable \\'(.+?)\\'$\"", ")", "public", "void", "saveInEnvironment", "(", "String", "value", ",", "String", "envVar", ")", "{", "ThreadProperty", ".", "set", "(", "envVar", ",", "value", ")", ";", "}" ]
Save value for future use. @param value value to be saved @param envVar thread environment variable where to store the value
[ "Save", "value", "for", "future", "use", "." ]
train
https://github.com/Stratio/bdt/blob/55324d19e7497764ad3dd7139923e13eb9841d75/src/main/java/com/stratio/qa/specs/MiscSpec.java#L105-L108
rzwitserloot/lombok
src/installer/lombok/installer/WindowsDriveInfo.java
WindowsDriveInfo.isFixedDisk
public boolean isFixedDisk(String letter) { """ Feed it a drive letter (such as 'A') to see if it is a fixed disk. """ if (letter.length() != 1) throw new IllegalArgumentException("Supply 1 letter, not: " + letter); char drive = Character.toUpperCase(letter.charAt(0)); if (drive < 'A' || drive > 'Z') thr...
java
public boolean isFixedDisk(String letter) { if (letter.length() != 1) throw new IllegalArgumentException("Supply 1 letter, not: " + letter); char drive = Character.toUpperCase(letter.charAt(0)); if (drive < 'A' || drive > 'Z') throw new IllegalArgumentException( "A drive is indicated by a letter, so A-Z inclu...
[ "public", "boolean", "isFixedDisk", "(", "String", "letter", ")", "{", "if", "(", "letter", ".", "length", "(", ")", "!=", "1", ")", "throw", "new", "IllegalArgumentException", "(", "\"Supply 1 letter, not: \"", "+", "letter", ")", ";", "char", "drive", "=",...
Feed it a drive letter (such as 'A') to see if it is a fixed disk.
[ "Feed", "it", "a", "drive", "letter", "(", "such", "as", "A", ")", "to", "see", "if", "it", "is", "a", "fixed", "disk", "." ]
train
https://github.com/rzwitserloot/lombok/blob/75601240760bd81ff95fcde7a1b8185769ce64e8/src/installer/lombok/installer/WindowsDriveInfo.java#L96-L102
OpenLiberty/open-liberty
dev/com.ibm.ws.monitor/src/com/ibm/ws/monitor/internal/jmx/PmiCollaborator.java
PmiCollaborator.setCustomSetString
@Override public void setCustomSetString(String setting, Boolean recursive) { """ New in 6.0: Set custom statistic set using fine-grained control """ if (tc.isEntryEnabled()) Tr.entry(tc, "setCustomSetString (String, Boolean): " + setting); setInstrumentationLevel(_createSLSFro...
java
@Override public void setCustomSetString(String setting, Boolean recursive) { if (tc.isEntryEnabled()) Tr.entry(tc, "setCustomSetString (String, Boolean): " + setting); setInstrumentationLevel(_createSLSFromString(setting), recursive); if (tc.isEntryEnabled()) Tr.ex...
[ "@", "Override", "public", "void", "setCustomSetString", "(", "String", "setting", ",", "Boolean", "recursive", ")", "{", "if", "(", "tc", ".", "isEntryEnabled", "(", ")", ")", "Tr", ".", "entry", "(", "tc", ",", "\"setCustomSetString (String, Boolean): \"", "...
New in 6.0: Set custom statistic set using fine-grained control
[ "New", "in", "6", ".", "0", ":", "Set", "custom", "statistic", "set", "using", "fine", "-", "grained", "control" ]
train
https://github.com/OpenLiberty/open-liberty/blob/ca725d9903e63645018f9fa8cbda25f60af83a5d/dev/com.ibm.ws.monitor/src/com/ibm/ws/monitor/internal/jmx/PmiCollaborator.java#L89-L98
DataSketches/sketches-core
src/main/java/com/yahoo/sketches/ByteArrayUtil.java
ByteArrayUtil.getLongBE
public static long getLongBE(final byte[] array, final int offset) { """ Get a <i>long</i> from the source byte array starting at the given offset in big endian order. There is no bounds checking. @param array source byte array @param offset source starting point @return the <i>long</i> """ return ( ...
java
public static long getLongBE(final byte[] array, final int offset) { return ( array[offset + 7] & 0XFFL ) | ((array[offset + 6] & 0XFFL) << 8) | ((array[offset + 5] & 0XFFL) << 16) | ((array[offset + 4] & 0XFFL) << 24) | ((array[offset + 3] & 0XFFL) << 32) |...
[ "public", "static", "long", "getLongBE", "(", "final", "byte", "[", "]", "array", ",", "final", "int", "offset", ")", "{", "return", "(", "array", "[", "offset", "+", "7", "]", "&", "0XFF", "L", ")", "|", "(", "(", "array", "[", "offset", "+", "6...
Get a <i>long</i> from the source byte array starting at the given offset in big endian order. There is no bounds checking. @param array source byte array @param offset source starting point @return the <i>long</i>
[ "Get", "a", "<i", ">", "long<", "/", "i", ">", "from", "the", "source", "byte", "array", "starting", "at", "the", "given", "offset", "in", "big", "endian", "order", ".", "There", "is", "no", "bounds", "checking", "." ]
train
https://github.com/DataSketches/sketches-core/blob/900c8c9668a1e2f1d54d453e956caad54702e540/src/main/java/com/yahoo/sketches/ByteArrayUtil.java#L163-L172
orbisgis/h2gis
h2gis-functions/src/main/java/org/h2gis/functions/io/gpx/model/GpxParserTrk.java
GpxParserTrk.endElement
@Override public void endElement(String uri, String localName, String qName) throws SAXException { """ Fires whenever an XML end markup is encountered. It catches attributes of trackPoints, trackSegments or routes and saves them in corresponding values[]. @param uri URI of the local element @param localN...
java
@Override public void endElement(String uri, String localName, String qName) throws SAXException { super.endElement(uri, localName, qName); if ((getCurrentElement().equalsIgnoreCase(GPXTags.TEXT)) && (isPoint())) { getCurrentPoint().setLinkText(getContentBuffer()); } else if (get...
[ "@", "Override", "public", "void", "endElement", "(", "String", "uri", ",", "String", "localName", ",", "String", "qName", ")", "throws", "SAXException", "{", "super", ".", "endElement", "(", "uri", ",", "localName", ",", "qName", ")", ";", "if", "(", "(...
Fires whenever an XML end markup is encountered. It catches attributes of trackPoints, trackSegments or routes and saves them in corresponding values[]. @param uri URI of the local element @param localName Name of the local element (without prefix) @param qName qName of the local element (with prefix) @throws SAXExcep...
[ "Fires", "whenever", "an", "XML", "end", "markup", "is", "encountered", ".", "It", "catches", "attributes", "of", "trackPoints", "trackSegments", "or", "routes", "and", "saves", "them", "in", "corresponding", "values", "[]", "." ]
train
https://github.com/orbisgis/h2gis/blob/9cd70b447e6469cecbc2fc64b16774b59491df3b/h2gis-functions/src/main/java/org/h2gis/functions/io/gpx/model/GpxParserTrk.java#L83-L91
apache/spark
launcher/src/main/java/org/apache/spark/launcher/CommandBuilderUtils.java
CommandBuilderUtils.checkArgument
static void checkArgument(boolean check, String msg, Object... args) { """ Throws IllegalArgumentException with the given message if the check is false. """ if (!check) { throw new IllegalArgumentException(String.format(msg, args)); } }
java
static void checkArgument(boolean check, String msg, Object... args) { if (!check) { throw new IllegalArgumentException(String.format(msg, args)); } }
[ "static", "void", "checkArgument", "(", "boolean", "check", ",", "String", "msg", ",", "Object", "...", "args", ")", "{", "if", "(", "!", "check", ")", "{", "throw", "new", "IllegalArgumentException", "(", "String", ".", "format", "(", "msg", ",", "args"...
Throws IllegalArgumentException with the given message if the check is false.
[ "Throws", "IllegalArgumentException", "with", "the", "given", "message", "if", "the", "check", "is", "false", "." ]
train
https://github.com/apache/spark/blob/25ee0474f47d9c30d6f553a7892d9549f91071cf/launcher/src/main/java/org/apache/spark/launcher/CommandBuilderUtils.java#L219-L223
Azure/azure-sdk-for-java
network/resource-manager/v2018_08_01/src/main/java/com/microsoft/azure/management/network/v2018_08_01/implementation/P2sVpnGatewaysInner.java
P2sVpnGatewaysInner.beginCreateOrUpdate
public P2SVpnGatewayInner beginCreateOrUpdate(String resourceGroupName, String gatewayName, P2SVpnGatewayInner p2SVpnGatewayParameters) { """ Creates a virtual wan p2s vpn gateway if it doesn't exist else updates the existing gateway. @param resourceGroupName The resource group name of the P2SVpnGateway. @para...
java
public P2SVpnGatewayInner beginCreateOrUpdate(String resourceGroupName, String gatewayName, P2SVpnGatewayInner p2SVpnGatewayParameters) { return beginCreateOrUpdateWithServiceResponseAsync(resourceGroupName, gatewayName, p2SVpnGatewayParameters).toBlocking().single().body(); }
[ "public", "P2SVpnGatewayInner", "beginCreateOrUpdate", "(", "String", "resourceGroupName", ",", "String", "gatewayName", ",", "P2SVpnGatewayInner", "p2SVpnGatewayParameters", ")", "{", "return", "beginCreateOrUpdateWithServiceResponseAsync", "(", "resourceGroupName", ",", "gate...
Creates a virtual wan p2s vpn gateway if it doesn't exist else updates the existing gateway. @param resourceGroupName The resource group name of the P2SVpnGateway. @param gatewayName The name of the gateway. @param p2SVpnGatewayParameters Parameters supplied to create or Update a virtual wan p2s vpn gateway. @throws I...
[ "Creates", "a", "virtual", "wan", "p2s", "vpn", "gateway", "if", "it", "doesn", "t", "exist", "else", "updates", "the", "existing", "gateway", "." ]
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/network/resource-manager/v2018_08_01/src/main/java/com/microsoft/azure/management/network/v2018_08_01/implementation/P2sVpnGatewaysInner.java#L298-L300
wildfly/wildfly-core
controller/src/main/java/org/jboss/as/controller/services/path/PathManagerService.java
PathManagerService.changeRelativePath
final void changeRelativePath(String pathName, String relativePath, boolean check) throws OperationFailedException { """ Updates the {@link PathEntry#getRelativeTo() relative to} value for an entry and sends an {@link org.jboss.as.controller.services.path.PathManager.Event#UPDATED} notification to any registered...
java
final void changeRelativePath(String pathName, String relativePath, boolean check) throws OperationFailedException { PathEntry pathEntry = findPathEntry(pathName); synchronized (pathEntries) { if (check && relativePath != null && pathEntries.get(relativePath) == null) { // TO...
[ "final", "void", "changeRelativePath", "(", "String", "pathName", ",", "String", "relativePath", ",", "boolean", "check", ")", "throws", "OperationFailedException", "{", "PathEntry", "pathEntry", "=", "findPathEntry", "(", "pathName", ")", ";", "synchronized", "(", ...
Updates the {@link PathEntry#getRelativeTo() relative to} value for an entry and sends an {@link org.jboss.as.controller.services.path.PathManager.Event#UPDATED} notification to any registered {@linkplain org.jboss.as.controller.services.path.PathManager.Callback#pathEvent(Event, PathEntry) callbacks}. @param pathName ...
[ "Updates", "the", "{" ]
train
https://github.com/wildfly/wildfly-core/blob/cfaf0479dcbb2d320a44c5374b93b944ec39fade/controller/src/main/java/org/jboss/as/controller/services/path/PathManagerService.java#L323-L341
ical4j/ical4j
src/main/java/net/fortuna/ical4j/data/CalendarParserImpl.java
CalendarParserImpl.skipNewLines
private int skipNewLines(StreamTokenizer tokeniser, Reader in, String token) throws ParserException, IOException { """ Skip newlines and linefeed at the beginning. @param tokeniser @param in @param token @return int value of the ttype field of the tokeniser @throws ParserException @throws IOException "...
java
private int skipNewLines(StreamTokenizer tokeniser, Reader in, String token) throws ParserException, IOException { for (int i = 0;; i++) { try { return assertToken(tokeniser, in, StreamTokenizer.TT_WORD); } catch (ParserException exc) { //Skip a maximum of...
[ "private", "int", "skipNewLines", "(", "StreamTokenizer", "tokeniser", ",", "Reader", "in", ",", "String", "token", ")", "throws", "ParserException", ",", "IOException", "{", "for", "(", "int", "i", "=", "0", ";", ";", "i", "++", ")", "{", "try", "{", ...
Skip newlines and linefeed at the beginning. @param tokeniser @param in @param token @return int value of the ttype field of the tokeniser @throws ParserException @throws IOException
[ "Skip", "newlines", "and", "linefeed", "at", "the", "beginning", "." ]
train
https://github.com/ical4j/ical4j/blob/7ac4bd1ce2bb2e0a2906fb69a56fbd2d9d974156/src/main/java/net/fortuna/ical4j/data/CalendarParserImpl.java#L542-L553
awslabs/amazon-sqs-java-messaging-lib
src/main/java/com/amazon/sqs/javamessaging/message/SQSMessage.java
SQSMessage.setObjectProperty
@Override public void setObjectProperty(String name, Object value) throws JMSException { """ Sets a Java object property value with the specified name into the message. <P> Note that this method works only for the boxed primitive object types (Integer, Double, Long ...) and String objects. @param name ...
java
@Override public void setObjectProperty(String name, Object value) throws JMSException { if (name == null || name.isEmpty()) { throw new IllegalArgumentException("Property name can not be null or empty."); } if (value == null || "".equals(value)) { throw new IllegalAr...
[ "@", "Override", "public", "void", "setObjectProperty", "(", "String", "name", ",", "Object", "value", ")", "throws", "JMSException", "{", "if", "(", "name", "==", "null", "||", "name", ".", "isEmpty", "(", ")", ")", "{", "throw", "new", "IllegalArgumentEx...
Sets a Java object property value with the specified name into the message. <P> Note that this method works only for the boxed primitive object types (Integer, Double, Long ...) and String objects. @param name The name of the property to set. @param value The object value of the property to set. @throws JMSException O...
[ "Sets", "a", "Java", "object", "property", "value", "with", "the", "specified", "name", "into", "the", "message", ".", "<P", ">", "Note", "that", "this", "method", "works", "only", "for", "the", "boxed", "primitive", "object", "types", "(", "Integer", "Dou...
train
https://github.com/awslabs/amazon-sqs-java-messaging-lib/blob/efa716d34d51ef1c5572790626cdb795419cb342/src/main/java/com/amazon/sqs/javamessaging/message/SQSMessage.java#L902-L915
mgledi/DRUMS
src/main/java/com/unister/semweb/drums/storable/GeneralStructure.java
GeneralStructure.addKeyPart
public boolean addKeyPart(String name, Basic_Field_Types type) throws IOException { """ Adds a new KeyPart. This is a wrapper method for <code>addKeyPart(String, int)</code>. @param name the name of the key part. With this name you can access this part @param type the type of the key part. @return true if a...
java
public boolean addKeyPart(String name, Basic_Field_Types type) throws IOException { return addKeyPart(name, type.size); }
[ "public", "boolean", "addKeyPart", "(", "String", "name", ",", "Basic_Field_Types", "type", ")", "throws", "IOException", "{", "return", "addKeyPart", "(", "name", ",", "type", ".", "size", ")", ";", "}" ]
Adds a new KeyPart. This is a wrapper method for <code>addKeyPart(String, int)</code>. @param name the name of the key part. With this name you can access this part @param type the type of the key part. @return true if adding the key part was successful @throws IOException
[ "Adds", "a", "new", "KeyPart", ".", "This", "is", "a", "wrapper", "method", "for", "<code", ">", "addKeyPart", "(", "String", "int", ")", "<", "/", "code", ">", "." ]
train
https://github.com/mgledi/DRUMS/blob/a670f17a2186c9a15725f26617d77ce8e444e072/src/main/java/com/unister/semweb/drums/storable/GeneralStructure.java#L154-L156
Ordinastie/MalisisCore
src/main/java/net/malisis/core/renderer/animation/transformation/ColorTransform.java
ColorTransform.doTransform
@Override protected void doTransform(ITransformable.Color transformable, float comp) { """ Calculates the transformation. @param transformable the transformable @param comp the comp """ if (comp <= 0) return; int from = reversed ? toColor : fromColor; int to = reversed ? fromColor : toColor; ...
java
@Override protected void doTransform(ITransformable.Color transformable, float comp) { if (comp <= 0) return; int from = reversed ? toColor : fromColor; int to = reversed ? fromColor : toColor; int r = (int) (red(from) + (red(to) - red(from)) * comp); int g = (int) (green(from) + (green(to) - green(fro...
[ "@", "Override", "protected", "void", "doTransform", "(", "ITransformable", ".", "Color", "transformable", ",", "float", "comp", ")", "{", "if", "(", "comp", "<=", "0", ")", "return", ";", "int", "from", "=", "reversed", "?", "toColor", ":", "fromColor", ...
Calculates the transformation. @param transformable the transformable @param comp the comp
[ "Calculates", "the", "transformation", "." ]
train
https://github.com/Ordinastie/MalisisCore/blob/4f8e1fa462d5c372fc23414482ba9f429881cc54/src/main/java/net/malisis/core/renderer/animation/transformation/ColorTransform.java#L124-L138
modelmapper/modelmapper
core/src/main/java/org/modelmapper/internal/PropertyInfoRegistry.java
PropertyInfoRegistry.mutatorFor
static synchronized Mutator mutatorFor(Class<?> type, Method method, Configuration configuration, String name) { """ Returns a Mutator instance for the given mutator method. The method must be externally validated to ensure that it accepts one argument and returns void.class. """ PropertyInfoKey k...
java
static synchronized Mutator mutatorFor(Class<?> type, Method method, Configuration configuration, String name) { PropertyInfoKey key = new PropertyInfoKey(type, name, configuration); Mutator mutator = MUTATOR_CACHE.get(key); if (mutator == null) { mutator = new MethodMutator(type, method, n...
[ "static", "synchronized", "Mutator", "mutatorFor", "(", "Class", "<", "?", ">", "type", ",", "Method", "method", ",", "Configuration", "configuration", ",", "String", "name", ")", "{", "PropertyInfoKey", "key", "=", "new", "PropertyInfoKey", "(", "type", ",", ...
Returns a Mutator instance for the given mutator method. The method must be externally validated to ensure that it accepts one argument and returns void.class.
[ "Returns", "a", "Mutator", "instance", "for", "the", "given", "mutator", "method", ".", "The", "method", "must", "be", "externally", "validated", "to", "ensure", "that", "it", "accepts", "one", "argument", "and", "returns", "void", ".", "class", "." ]
train
https://github.com/modelmapper/modelmapper/blob/491d165ded9dc9aba7ce8b56984249e1a1363204/core/src/main/java/org/modelmapper/internal/PropertyInfoRegistry.java#L152-L162
Terracotta-OSS/offheap-store
src/main/java/org/terracotta/offheapstore/storage/allocator/IntegerBestFitAllocator.java
IntegerBestFitAllocator.checkMallocedChunk
private void checkMallocedChunk(int mem, int s) { """ /* Check properties of malloced chunks at the point they are malloced """ if (VALIDATING) { int p = memToChunk(mem); int sz = head(p) & ~INUSE_BITS; checkInUseChunk(p); if (sz < MIN_CHUNK_SIZE) throw new AssertionError("...
java
private void checkMallocedChunk(int mem, int s) { if (VALIDATING) { int p = memToChunk(mem); int sz = head(p) & ~INUSE_BITS; checkInUseChunk(p); if (sz < MIN_CHUNK_SIZE) throw new AssertionError("Allocated chunk " + p + " is too small"); if ((sz & CHUNK_ALIGN_MASK) != 0) ...
[ "private", "void", "checkMallocedChunk", "(", "int", "mem", ",", "int", "s", ")", "{", "if", "(", "VALIDATING", ")", "{", "int", "p", "=", "memToChunk", "(", "mem", ")", ";", "int", "sz", "=", "head", "(", "p", ")", "&", "~", "INUSE_BITS", ";", "...
/* Check properties of malloced chunks at the point they are malloced
[ "/", "*", "Check", "properties", "of", "malloced", "chunks", "at", "the", "point", "they", "are", "malloced" ]
train
https://github.com/Terracotta-OSS/offheap-store/blob/600486cddb33c0247025c0cb69eff289eb6d7d93/src/main/java/org/terracotta/offheapstore/storage/allocator/IntegerBestFitAllocator.java#L1063-L1078
lightblueseas/file-worker
src/main/java/de/alpharogroup/file/copy/CopyFileExtensions.java
CopyFileExtensions.copyFileToDirectory
public static boolean copyFileToDirectory(final File source, final File destinationDir, final boolean lastModified) throws FileIsNotADirectoryException, IOException, FileIsADirectoryException { """ Copies the given source file to the given destination directory with the option to set the lastModified time fro...
java
public static boolean copyFileToDirectory(final File source, final File destinationDir, final boolean lastModified) throws FileIsNotADirectoryException, IOException, FileIsADirectoryException { if (null == destinationDir) { throw new IllegalArgumentException("Destination must not be null"); } if (!dest...
[ "public", "static", "boolean", "copyFileToDirectory", "(", "final", "File", "source", ",", "final", "File", "destinationDir", ",", "final", "boolean", "lastModified", ")", "throws", "FileIsNotADirectoryException", ",", "IOException", ",", "FileIsADirectoryException", "{...
Copies the given source file to the given destination directory with the option to set the lastModified time from the given destination directory. @param source The source directory. @param destinationDir The destination directory. @param lastModified Flag the tells if the attribute lastModified has to be set with the...
[ "Copies", "the", "given", "source", "file", "to", "the", "given", "destination", "directory", "with", "the", "option", "to", "set", "the", "lastModified", "time", "from", "the", "given", "destination", "directory", "." ]
train
https://github.com/lightblueseas/file-worker/blob/2c81de10fb5d68de64c1abc3ed64ca681ce76da8/src/main/java/de/alpharogroup/file/copy/CopyFileExtensions.java#L620-L637
apache/incubator-shardingsphere
sharding-core/sharding-core-api/src/main/java/org/apache/shardingsphere/api/hint/HintManager.java
HintManager.addTableShardingValue
public void addTableShardingValue(final String logicTable, final Comparable<?> value) { """ Add sharding value for table. <p>The sharding operator is {@code =}</p> @param logicTable logic table name @param value sharding value """ tableShardingValues.put(logicTable, value); databaseShard...
java
public void addTableShardingValue(final String logicTable, final Comparable<?> value) { tableShardingValues.put(logicTable, value); databaseShardingOnly = false; }
[ "public", "void", "addTableShardingValue", "(", "final", "String", "logicTable", ",", "final", "Comparable", "<", "?", ">", "value", ")", "{", "tableShardingValues", ".", "put", "(", "logicTable", ",", "value", ")", ";", "databaseShardingOnly", "=", "false", "...
Add sharding value for table. <p>The sharding operator is {@code =}</p> @param logicTable logic table name @param value sharding value
[ "Add", "sharding", "value", "for", "table", "." ]
train
https://github.com/apache/incubator-shardingsphere/blob/f88fd29fc345dfb31fdce12e9e96cbfa0fd2402d/sharding-core/sharding-core-api/src/main/java/org/apache/shardingsphere/api/hint/HintManager.java#L95-L98
threerings/gwt-utils
src/main/java/com/threerings/gwt/ui/Popups.java
Popups.bindPopped
public static void bindPopped (final Value<Boolean> popped, final PopupPanel panel) { """ Binds the popped up state of a popup to the supplied boolean value and vice versa (i.e. if the popup is popped down, the value will be updated to false). """ Preconditions.checkNotNull(panel, "panel"); pa...
java
public static void bindPopped (final Value<Boolean> popped, final PopupPanel panel) { Preconditions.checkNotNull(panel, "panel"); panel.addCloseHandler(new CloseHandler<PopupPanel>() { public void onClose (CloseEvent<PopupPanel> event) { popped.update(false); ...
[ "public", "static", "void", "bindPopped", "(", "final", "Value", "<", "Boolean", ">", "popped", ",", "final", "PopupPanel", "panel", ")", "{", "Preconditions", ".", "checkNotNull", "(", "panel", ",", "\"panel\"", ")", ";", "panel", ".", "addCloseHandler", "(...
Binds the popped up state of a popup to the supplied boolean value and vice versa (i.e. if the popup is popped down, the value will be updated to false).
[ "Binds", "the", "popped", "up", "state", "of", "a", "popup", "to", "the", "supplied", "boolean", "value", "and", "vice", "versa", "(", "i", ".", "e", ".", "if", "the", "popup", "is", "popped", "down", "the", "value", "will", "be", "updated", "to", "f...
train
https://github.com/threerings/gwt-utils/blob/31b31a23b667f2a9c683160d77646db259f2aae5/src/main/java/com/threerings/gwt/ui/Popups.java#L324-L341
geomajas/geomajas-project-client-gwt
client/src/main/java/org/geomajas/gwt/client/map/workflow/SequenceProcessor.java
SequenceProcessor.doActivities
public void doActivities(Object seedData) { """ This method kicks off the processing of workflow activities. It goes over them one by one and executes them. @param seedData A data object to be passed along to the {@link WorkflowContext} before starting the activities. """ // retrieve injected by Spring ...
java
public void doActivities(Object seedData) { // retrieve injected by Spring List<Activity> activities = getActivities(); if (seedData != null) { context.setSeedData(seedData); } for (Activity activity : activities) { try { context = activity.execute(context); } catch (Throwable th) { Workflo...
[ "public", "void", "doActivities", "(", "Object", "seedData", ")", "{", "// retrieve injected by Spring", "List", "<", "Activity", ">", "activities", "=", "getActivities", "(", ")", ";", "if", "(", "seedData", "!=", "null", ")", "{", "context", ".", "setSeedDat...
This method kicks off the processing of workflow activities. It goes over them one by one and executes them. @param seedData A data object to be passed along to the {@link WorkflowContext} before starting the activities.
[ "This", "method", "kicks", "off", "the", "processing", "of", "workflow", "activities", ".", "It", "goes", "over", "them", "one", "by", "one", "and", "executes", "them", "." ]
train
https://github.com/geomajas/geomajas-project-client-gwt/blob/1c1adc48deb192ed825265eebcc74d70bbf45670/client/src/main/java/org/geomajas/gwt/client/map/workflow/SequenceProcessor.java#L69-L95
javalite/activejdbc
activejdbc/src/main/java/org/javalite/activejdbc/Model.java
Model.toUpdate
public String toUpdate(Dialect dialect, String ... replacements) { """ Generates UPDATE SQL based on this model with the provided dialect. Example: <pre> String sql = user.toUpdate(new MySQLDialect()); //yields this output: //UPDATE users SET email = 'mmonroe@yahoo.com', first_name = 'Marilyn', last_name = 'M...
java
public String toUpdate(Dialect dialect, String ... replacements) { return dialect.update(metaModelLocal, attributes, replacements); }
[ "public", "String", "toUpdate", "(", "Dialect", "dialect", ",", "String", "...", "replacements", ")", "{", "return", "dialect", ".", "update", "(", "metaModelLocal", ",", "attributes", ",", "replacements", ")", ";", "}" ]
Generates UPDATE SQL based on this model with the provided dialect. Example: <pre> String sql = user.toUpdate(new MySQLDialect()); //yields this output: //UPDATE users SET email = 'mmonroe@yahoo.com', first_name = 'Marilyn', last_name = 'Monroe' WHERE id = 1 </pre> @param dialect dialect to be used to generate the SQL...
[ "Generates", "UPDATE", "SQL", "based", "on", "this", "model", "with", "the", "provided", "dialect", ".", "Example", ":", "<pre", ">", "String", "sql", "=", "user", ".", "toUpdate", "(", "new", "MySQLDialect", "()", ")", ";", "//", "yields", "this", "outp...
train
https://github.com/javalite/activejdbc/blob/ffcf5457cace19622a8f71e856cbbbe9e7dd5fcc/activejdbc/src/main/java/org/javalite/activejdbc/Model.java#L3074-L3076
mapbox/mapbox-plugins-android
plugin-offline/src/main/java/com/mapbox/mapboxsdk/plugins/offline/offline/OfflineDownloadService.java
OfflineDownloadService.finishDownload
void finishDownload(OfflineDownloadOptions offlineDownload, OfflineRegion offlineRegion) { """ When a particular download has been completed, this method's called which handles removing the notification and setting the download state. @param offlineRegion the region which has finished being downloaded @para...
java
void finishDownload(OfflineDownloadOptions offlineDownload, OfflineRegion offlineRegion) { OfflineDownloadStateReceiver.dispatchSuccessBroadcast(this, offlineDownload); offlineRegion.setDownloadState(OfflineRegion.STATE_INACTIVE); offlineRegion.setObserver(null); removeOfflineRegion(offlineDownload.uuid...
[ "void", "finishDownload", "(", "OfflineDownloadOptions", "offlineDownload", ",", "OfflineRegion", "offlineRegion", ")", "{", "OfflineDownloadStateReceiver", ".", "dispatchSuccessBroadcast", "(", "this", ",", "offlineDownload", ")", ";", "offlineRegion", ".", "setDownloadSta...
When a particular download has been completed, this method's called which handles removing the notification and setting the download state. @param offlineRegion the region which has finished being downloaded @param offlineDownload the corresponding options used to define the offline region @since 0.1.0
[ "When", "a", "particular", "download", "has", "been", "completed", "this", "method", "s", "called", "which", "handles", "removing", "the", "notification", "and", "setting", "the", "download", "state", "." ]
train
https://github.com/mapbox/mapbox-plugins-android/blob/c683cad4d8306945d71838d96fae73b8cbe2e6c9/plugin-offline/src/main/java/com/mapbox/mapboxsdk/plugins/offline/offline/OfflineDownloadService.java#L251-L256
sarl/sarl
main/coreplugins/io.sarl.lang.ui/src/io/sarl/lang/ui/outline/SARLOutlineTreeProvider.java
SARLOutlineTreeProvider._createChildren
protected void _createChildren(DocumentRootNode parentNode, SarlScript modelElement) { """ Create a node for the SARL script. @param parentNode the parent node. @param modelElement the feature container for which a node should be created. """ if (!Strings.isNullOrEmpty(modelElement.getPackage())) { //...
java
protected void _createChildren(DocumentRootNode parentNode, SarlScript modelElement) { if (!Strings.isNullOrEmpty(modelElement.getPackage())) { // Create the node for the package declaration. createEStructuralFeatureNode( parentNode, modelElement, XtendPackage.Literals.XTEND_FILE__PACKAGE, this.i...
[ "protected", "void", "_createChildren", "(", "DocumentRootNode", "parentNode", ",", "SarlScript", "modelElement", ")", "{", "if", "(", "!", "Strings", ".", "isNullOrEmpty", "(", "modelElement", ".", "getPackage", "(", ")", ")", ")", "{", "// Create the node for th...
Create a node for the SARL script. @param parentNode the parent node. @param modelElement the feature container for which a node should be created.
[ "Create", "a", "node", "for", "the", "SARL", "script", "." ]
train
https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.ui/src/io/sarl/lang/ui/outline/SARLOutlineTreeProvider.java#L103-L123
jbundle/jbundle
base/message/trx/src/main/java/org/jbundle/base/message/trx/transport/email/EmailMessageTransport.java
EmailMessageTransport.createExternalMessage
public ExternalMessage createExternalMessage(BaseMessage message, Object rawData) { """ Get the external message container for this Internal message. Typically, the overriding class supplies a default format for the transport type. <br/>NOTE: The message header from the internal message is copies, but not the me...
java
public ExternalMessage createExternalMessage(BaseMessage message, Object rawData) { ExternalMessage externalTrxMessage = super.createExternalMessage(message, rawData); if (externalTrxMessage == null) { if ((message.getMessageHeader() != null) && (MessageTypeMo...
[ "public", "ExternalMessage", "createExternalMessage", "(", "BaseMessage", "message", ",", "Object", "rawData", ")", "{", "ExternalMessage", "externalTrxMessage", "=", "super", ".", "createExternalMessage", "(", "message", ",", "rawData", ")", ";", "if", "(", "extern...
Get the external message container for this Internal message. Typically, the overriding class supplies a default format for the transport type. <br/>NOTE: The message header from the internal message is copies, but not the message itself. @param The internalTrxMessage that I will convert to this external format. @retur...
[ "Get", "the", "external", "message", "container", "for", "this", "Internal", "message", ".", "Typically", "the", "overriding", "class", "supplies", "a", "default", "format", "for", "the", "transport", "type", ".", "<br", "/", ">", "NOTE", ":", "The", "messag...
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/message/trx/src/main/java/org/jbundle/base/message/trx/transport/email/EmailMessageTransport.java#L107-L119
Whiley/WhileyCompiler
src/main/java/wyc/io/WhileyFileParser.java
WhileyFileParser.parseStaticVariableDeclaration
private Decl.StaticVariable parseStaticVariableDeclaration(Tuple<Modifier> modifiers) { """ Parse a constant declaration in a Whiley source file, which has the form: <pre> ConstantDeclaration ::= "constant" Identifier "is"Expr </pre> A simple example to illustrate is: <pre> constant PI is 3.141592654 ...
java
private Decl.StaticVariable parseStaticVariableDeclaration(Tuple<Modifier> modifiers) { // int start = index; EnclosingScope scope = new EnclosingScope(); // Type type = parseType(scope); // Identifier name = parseIdentifier(); match(Equals); Expr e = parseExpression(scope, false); int end = index; ...
[ "private", "Decl", ".", "StaticVariable", "parseStaticVariableDeclaration", "(", "Tuple", "<", "Modifier", ">", "modifiers", ")", "{", "//", "int", "start", "=", "index", ";", "EnclosingScope", "scope", "=", "new", "EnclosingScope", "(", ")", ";", "//", "Type"...
Parse a constant declaration in a Whiley source file, which has the form: <pre> ConstantDeclaration ::= "constant" Identifier "is"Expr </pre> A simple example to illustrate is: <pre> constant PI is 3.141592654 </pre> Here, we are defining a constant called <code>PI</code> which represents the decimal value "3.14159...
[ "Parse", "a", "constant", "declaration", "in", "a", "Whiley", "source", "file", "which", "has", "the", "form", ":" ]
train
https://github.com/Whiley/WhileyCompiler/blob/680f8a657d3fc286f8cc422755988b6d74ab3f4c/src/main/java/wyc/io/WhileyFileParser.java#L545-L558
DataSketches/sketches-core
src/main/java/com/yahoo/sketches/fdt/FdtSketch.java
FdtSketch.getLowerBound
public double getLowerBound(final int numStdDev, final int numSubsetEntries) { """ Gets the estimate of the lower bound of the true distinct population represented by the count of entries in a group. @param numStdDev <a href="{@docRoot}/resources/dictionary.html#numStdDev">See Number of Standard Deviations</a> ...
java
public double getLowerBound(final int numStdDev, final int numSubsetEntries) { if (!isEstimationMode()) { return numSubsetEntries; } return BinomialBoundsN.getLowerBound(numSubsetEntries, getTheta(), numStdDev, isEmpty()); }
[ "public", "double", "getLowerBound", "(", "final", "int", "numStdDev", ",", "final", "int", "numSubsetEntries", ")", "{", "if", "(", "!", "isEstimationMode", "(", ")", ")", "{", "return", "numSubsetEntries", ";", "}", "return", "BinomialBoundsN", ".", "getLowe...
Gets the estimate of the lower bound of the true distinct population represented by the count of entries in a group. @param numStdDev <a href="{@docRoot}/resources/dictionary.html#numStdDev">See Number of Standard Deviations</a> @param numSubsetEntries number of entries for a chosen subset of the sketch. @return the es...
[ "Gets", "the", "estimate", "of", "the", "lower", "bound", "of", "the", "true", "distinct", "population", "represented", "by", "the", "count", "of", "entries", "in", "a", "group", "." ]
train
https://github.com/DataSketches/sketches-core/blob/900c8c9668a1e2f1d54d453e956caad54702e540/src/main/java/com/yahoo/sketches/fdt/FdtSketch.java#L135-L138
alkacon/opencms-core
src/org/opencms/ui/CmsVaadinUtils.java
CmsVaadinUtils.replaceComponent
public static void replaceComponent(Component component, Component replacement) { """ Replaces component with new component.<p> @param component to be replaced @param replacement new component """ if (!component.isAttached()) { throw new IllegalArgumentException("Component must be atta...
java
public static void replaceComponent(Component component, Component replacement) { if (!component.isAttached()) { throw new IllegalArgumentException("Component must be attached"); } HasComponents parent = component.getParent(); if (parent instanceof ComponentContainer) { ...
[ "public", "static", "void", "replaceComponent", "(", "Component", "component", ",", "Component", "replacement", ")", "{", "if", "(", "!", "component", ".", "isAttached", "(", ")", ")", "{", "throw", "new", "IllegalArgumentException", "(", "\"Component must be atta...
Replaces component with new component.<p> @param component to be replaced @param replacement new component
[ "Replaces", "component", "with", "new", "component", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/ui/CmsVaadinUtils.java#L1105-L1118
aws/aws-sdk-java
aws-java-sdk-robomaker/src/main/java/com/amazonaws/services/robomaker/model/DescribeFleetResult.java
DescribeFleetResult.withTags
public DescribeFleetResult withTags(java.util.Map<String, String> tags) { """ <p> The list of all tags added to the specified fleet. </p> @param tags The list of all tags added to the specified fleet. @return Returns a reference to this object so that method calls can be chained together. """ se...
java
public DescribeFleetResult withTags(java.util.Map<String, String> tags) { setTags(tags); return this; }
[ "public", "DescribeFleetResult", "withTags", "(", "java", ".", "util", ".", "Map", "<", "String", ",", "String", ">", "tags", ")", "{", "setTags", "(", "tags", ")", ";", "return", "this", ";", "}" ]
<p> The list of all tags added to the specified fleet. </p> @param tags The list of all tags added to the specified fleet. @return Returns a reference to this object so that method calls can be chained together.
[ "<p", ">", "The", "list", "of", "all", "tags", "added", "to", "the", "specified", "fleet", ".", "<", "/", "p", ">" ]
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-robomaker/src/main/java/com/amazonaws/services/robomaker/model/DescribeFleetResult.java#L439-L442
duracloud/duracloud
durastore/src/main/java/org/duracloud/durastore/rest/SpaceRest.java
SpaceRest.addSpace
@Path("/ { """ see SpaceResource.addSpace(String, String, String, String) @return 201 response with request URI """spaceID}") @PUT public Response addSpace(@PathParam("spaceID") String spaceID, @QueryParam("storeID") String storeID) { String msg = "adding space("...
java
@Path("/{spaceID}") @PUT public Response addSpace(@PathParam("spaceID") String spaceID, @QueryParam("storeID") String storeID) { String msg = "adding space(" + spaceID + ", " + storeID + ")"; try { log.debug(msg); return doAddSpace(spaceID, s...
[ "@", "Path", "(", "\"/{spaceID}\"", ")", "@", "PUT", "public", "Response", "addSpace", "(", "@", "PathParam", "(", "\"spaceID\"", ")", "String", "spaceID", ",", "@", "QueryParam", "(", "\"storeID\"", ")", "String", "storeID", ")", "{", "String", "msg", "="...
see SpaceResource.addSpace(String, String, String, String) @return 201 response with request URI
[ "see", "SpaceResource", ".", "addSpace", "(", "String", "String", "String", "String", ")" ]
train
https://github.com/duracloud/duracloud/blob/dc4f3a1716d43543cc3b2e1880605f9389849b66/durastore/src/main/java/org/duracloud/durastore/rest/SpaceRest.java#L236-L255
DDTH/ddth-commons
ddth-commons-core/src/main/java/com/github/ddth/commons/utils/TypesafeConfigUtils.java
TypesafeConfigUtils.loadConfig
public static Config loadConfig(Reader configReader, boolean useSystemEnvironment) { """ Load, Parse & Resolve configurations from a reader, with default parse & resolve options. @param configReader @param useSystemEnvironment {@code true} to resolve substitutions falling back to environment variables @retu...
java
public static Config loadConfig(Reader configReader, boolean useSystemEnvironment) { return loadConfig(ConfigParseOptions.defaults(), ConfigResolveOptions.defaults().setUseSystemEnvironment(useSystemEnvironment), configReader); }
[ "public", "static", "Config", "loadConfig", "(", "Reader", "configReader", ",", "boolean", "useSystemEnvironment", ")", "{", "return", "loadConfig", "(", "ConfigParseOptions", ".", "defaults", "(", ")", ",", "ConfigResolveOptions", ".", "defaults", "(", ")", ".", ...
Load, Parse & Resolve configurations from a reader, with default parse & resolve options. @param configReader @param useSystemEnvironment {@code true} to resolve substitutions falling back to environment variables @return
[ "Load", "Parse", "&", "Resolve", "configurations", "from", "a", "reader", "with", "default", "parse", "&", "resolve", "options", "." ]
train
https://github.com/DDTH/ddth-commons/blob/734f0e77321d41eeca78a557be9884df9874e46e/ddth-commons-core/src/main/java/com/github/ddth/commons/utils/TypesafeConfigUtils.java#L71-L75
jbossws/jbossws-common
src/main/java/org/jboss/ws/common/injection/finders/ReflectionUtils.java
ReflectionUtils.assertNoParameters
public static void assertNoParameters(final Method method, Class<? extends Annotation> annotation) { """ Asserts method have no parameters. @param method to validate @param annotation annotation to propagate in exception message """ if (method.getParameterTypes().length != 0) { throw a...
java
public static void assertNoParameters(final Method method, Class<? extends Annotation> annotation) { if (method.getParameterTypes().length != 0) { throw annotation == null ? MESSAGES.methodHasToHaveNoParameters(method) : MESSAGES.methodHasToHaveNoParameters2(method, annotation); } }
[ "public", "static", "void", "assertNoParameters", "(", "final", "Method", "method", ",", "Class", "<", "?", "extends", "Annotation", ">", "annotation", ")", "{", "if", "(", "method", ".", "getParameterTypes", "(", ")", ".", "length", "!=", "0", ")", "{", ...
Asserts method have no parameters. @param method to validate @param annotation annotation to propagate in exception message
[ "Asserts", "method", "have", "no", "parameters", "." ]
train
https://github.com/jbossws/jbossws-common/blob/fcff8a3ef9bfe046d6fa8c855a3fe4f62841add7/src/main/java/org/jboss/ws/common/injection/finders/ReflectionUtils.java#L104-L110
aws/aws-sdk-java
aws-java-sdk-apigatewayv2/src/main/java/com/amazonaws/services/apigatewayv2/model/UpdateRouteRequest.java
UpdateRouteRequest.withRequestModels
public UpdateRouteRequest withRequestModels(java.util.Map<String, String> requestModels) { """ <p> The request models for the route. </p> @param requestModels The request models for the route. @return Returns a reference to this object so that method calls can be chained together. """ setRequest...
java
public UpdateRouteRequest withRequestModels(java.util.Map<String, String> requestModels) { setRequestModels(requestModels); return this; }
[ "public", "UpdateRouteRequest", "withRequestModels", "(", "java", ".", "util", ".", "Map", "<", "String", ",", "String", ">", "requestModels", ")", "{", "setRequestModels", "(", "requestModels", ")", ";", "return", "this", ";", "}" ]
<p> The request models for the route. </p> @param requestModels The request models for the route. @return Returns a reference to this object so that method calls can be chained together.
[ "<p", ">", "The", "request", "models", "for", "the", "route", ".", "<", "/", "p", ">" ]
train
https://github.com/aws/aws-sdk-java/blob/aa38502458969b2d13a1c3665a56aba600e4dbd0/aws-java-sdk-apigatewayv2/src/main/java/com/amazonaws/services/apigatewayv2/model/UpdateRouteRequest.java#L494-L497
PeterisP/LVTagger
src/main/java/edu/stanford/nlp/sequences/SequenceGibbsSampler.java
SequenceGibbsSampler.samplePosition
public double samplePosition(SequenceModel model, int[] sequence, int pos, double temperature) { """ Samples a single position in the sequence. Destructively modifies the sequence in place. returns the score of the new sequence @param sequence the sequence to start with @param pos the position to sample. "...
java
public double samplePosition(SequenceModel model, int[] sequence, int pos, double temperature) { double[] distribution = model.scoresOf(sequence, pos); if (temperature!=1.0) { if (temperature==0.0) { // set the max to 1.0 int argmax = ArrayMath.argmax(distribution); Arrays.fi...
[ "public", "double", "samplePosition", "(", "SequenceModel", "model", ",", "int", "[", "]", "sequence", ",", "int", "pos", ",", "double", "temperature", ")", "{", "double", "[", "]", "distribution", "=", "model", ".", "scoresOf", "(", "sequence", ",", "pos"...
Samples a single position in the sequence. Destructively modifies the sequence in place. returns the score of the new sequence @param sequence the sequence to start with @param pos the position to sample.
[ "Samples", "a", "single", "position", "in", "the", "sequence", ".", "Destructively", "modifies", "the", "sequence", "in", "place", ".", "returns", "the", "score", "of", "the", "new", "sequence" ]
train
https://github.com/PeterisP/LVTagger/blob/b3d44bab9ec07ace0d13612c448a6b7298c1f681/src/main/java/edu/stanford/nlp/sequences/SequenceGibbsSampler.java#L241-L263
digipost/signature-api-client-java
src/main/java/no/digipost/signature/client/direct/StatusReference.java
StatusReference.ofUrl
public static StatusUrlContruction ofUrl(final String statusUrl) { """ Start constructing a new {@link StatusReference}. @param statusUrl the status url for the job @return partially constructed {@link StatusReference} which must be completed with a status query token using {@link StatusUrlContruction#withSt...
java
public static StatusUrlContruction ofUrl(final String statusUrl) { return new StatusUrlContruction() { @Override public StatusReference withStatusQueryToken(String token) { return new StatusReference(statusUrl, token); } }; }
[ "public", "static", "StatusUrlContruction", "ofUrl", "(", "final", "String", "statusUrl", ")", "{", "return", "new", "StatusUrlContruction", "(", ")", "{", "@", "Override", "public", "StatusReference", "withStatusQueryToken", "(", "String", "token", ")", "{", "ret...
Start constructing a new {@link StatusReference}. @param statusUrl the status url for the job @return partially constructed {@link StatusReference} which must be completed with a status query token using {@link StatusUrlContruction#withStatusQueryToken(String) .withStatusQueryToken(token)}
[ "Start", "constructing", "a", "new", "{", "@link", "StatusReference", "}", "." ]
train
https://github.com/digipost/signature-api-client-java/blob/246207571641fbac6beda5ffc585eec188825c45/src/main/java/no/digipost/signature/client/direct/StatusReference.java#L35-L42
google/error-prone-javac
src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/SourceToHTMLConverter.java
SourceToHTMLConverter.addLineNo
private static void addLineNo(Content pre, int lineno) { """ Add the line numbers for the source code. @param pre the content tree to which the line number will be added @param lineno The line number """ HtmlTree span = new HtmlTree(HtmlTag.SPAN); span.addStyle(HtmlStyle.sourceLineNo); ...
java
private static void addLineNo(Content pre, int lineno) { HtmlTree span = new HtmlTree(HtmlTag.SPAN); span.addStyle(HtmlStyle.sourceLineNo); if (lineno < 10) { span.addContent("00" + Integer.toString(lineno)); } else if (lineno < 100) { span.addContent("0" + Intege...
[ "private", "static", "void", "addLineNo", "(", "Content", "pre", ",", "int", "lineno", ")", "{", "HtmlTree", "span", "=", "new", "HtmlTree", "(", "HtmlTag", ".", "SPAN", ")", ";", "span", ".", "addStyle", "(", "HtmlStyle", ".", "sourceLineNo", ")", ";", ...
Add the line numbers for the source code. @param pre the content tree to which the line number will be added @param lineno The line number
[ "Add", "the", "line", "numbers", "for", "the", "source", "code", "." ]
train
https://github.com/google/error-prone-javac/blob/a53d069bbdb2c60232ed3811c19b65e41c3e60e0/src/jdk.javadoc/share/classes/com/sun/tools/doclets/formats/html/SourceToHTMLConverter.java#L247-L258
micronaut-projects/micronaut-core
inject/src/main/java/io/micronaut/inject/writer/AbstractClassFileWriter.java
AbstractClassFileWriter.buildArgument
protected static void buildArgument(GeneratorAdapter generatorAdapter, String argumentName, Object objectType) { """ Builds an argument instance. @param generatorAdapter The generator adapter. @param argumentName The argument name @param objectType The object type """ // 1st argument: the type ...
java
protected static void buildArgument(GeneratorAdapter generatorAdapter, String argumentName, Object objectType) { // 1st argument: the type generatorAdapter.push(getTypeReference(objectType)); // 2nd argument: the name generatorAdapter.push(argumentName); // Argument.create( .. )...
[ "protected", "static", "void", "buildArgument", "(", "GeneratorAdapter", "generatorAdapter", ",", "String", "argumentName", ",", "Object", "objectType", ")", "{", "// 1st argument: the type", "generatorAdapter", ".", "push", "(", "getTypeReference", "(", "objectType", "...
Builds an argument instance. @param generatorAdapter The generator adapter. @param argumentName The argument name @param objectType The object type
[ "Builds", "an", "argument", "instance", "." ]
train
https://github.com/micronaut-projects/micronaut-core/blob/c31f5b03ce0eb88c2f6470710987db03b8967d5c/inject/src/main/java/io/micronaut/inject/writer/AbstractClassFileWriter.java#L143-L155
ozimov/cirneco
hamcrest/hamcrest-matchers/src/main/java/it/ozimov/cirneco/hamcrest/date/IsDateWithTime.java
IsDateWithTime.hasHourAndMin
public static Matcher<Date> hasHourAndMin(final int hour, final int minute) { """ Creates a matcher that matches when the examined {@linkplain Date} has the given values <code>hour</code> in a 24 hours clock period and <code>minute</code>. """ return new IsDateWithTime(hour, minute, null, null); }
java
public static Matcher<Date> hasHourAndMin(final int hour, final int minute) { return new IsDateWithTime(hour, minute, null, null); }
[ "public", "static", "Matcher", "<", "Date", ">", "hasHourAndMin", "(", "final", "int", "hour", ",", "final", "int", "minute", ")", "{", "return", "new", "IsDateWithTime", "(", "hour", ",", "minute", ",", "null", ",", "null", ")", ";", "}" ]
Creates a matcher that matches when the examined {@linkplain Date} has the given values <code>hour</code> in a 24 hours clock period and <code>minute</code>.
[ "Creates", "a", "matcher", "that", "matches", "when", "the", "examined", "{" ]
train
https://github.com/ozimov/cirneco/blob/78ad782da0a2256634cfbebb2f97ed78c993b999/hamcrest/hamcrest-matchers/src/main/java/it/ozimov/cirneco/hamcrest/date/IsDateWithTime.java#L92-L94
eobermuhlner/big-math
ch.obermuhlner.math.big/src/main/java/ch/obermuhlner/math/big/stream/BigFloatStream.java
BigFloatStream.rangeClosed
public static Stream<BigFloat> rangeClosed(BigFloat startInclusive, BigFloat endInclusive, BigFloat step) { """ Returns a sequential ordered {@code Stream<BigFloat>} from {@code startInclusive} (inclusive) to {@code endInclusive} (inclusive) by an incremental {@code step}. <p>An equivalent sequence of increasi...
java
public static Stream<BigFloat> rangeClosed(BigFloat startInclusive, BigFloat endInclusive, BigFloat step) { if (step.isZero()) { throw new IllegalArgumentException("invalid step: 0"); } if (endInclusive.subtract(startInclusive).signum() == -step.signum()) { return Stream.empty(); } re...
[ "public", "static", "Stream", "<", "BigFloat", ">", "rangeClosed", "(", "BigFloat", "startInclusive", ",", "BigFloat", "endInclusive", ",", "BigFloat", "step", ")", "{", "if", "(", "step", ".", "isZero", "(", ")", ")", "{", "throw", "new", "IllegalArgumentEx...
Returns a sequential ordered {@code Stream<BigFloat>} from {@code startInclusive} (inclusive) to {@code endInclusive} (inclusive) by an incremental {@code step}. <p>An equivalent sequence of increasing values can be produced sequentially using a {@code for} loop as follows: <pre>for (BigFloat i = startInclusive; i.isL...
[ "Returns", "a", "sequential", "ordered", "{", "@code", "Stream<BigFloat", ">", "}", "from", "{", "@code", "startInclusive", "}", "(", "inclusive", ")", "to", "{", "@code", "endInclusive", "}", "(", "inclusive", ")", "by", "an", "incremental", "{", "@code", ...
train
https://github.com/eobermuhlner/big-math/blob/52c4fc334d0d722b295de740c1018ee400e3e8f2/ch.obermuhlner.math.big/src/main/java/ch/obermuhlner/math/big/stream/BigFloatStream.java#L93-L101
deeplearning4j/deeplearning4j
deeplearning4j/deeplearning4j-nn/src/main/java/org/deeplearning4j/util/ModelSerializer.java
ModelSerializer.writeModel
public static void writeModel(@NonNull Model model, @NonNull File file, boolean saveUpdater,DataNormalization dataNormalization) throws IOException { """ Write a model to a file @param model the model to write @param file the file to write to @param saveUpdater whether to save the updater or not @param dataNor...
java
public static void writeModel(@NonNull Model model, @NonNull File file, boolean saveUpdater,DataNormalization dataNormalization) throws IOException { try (BufferedOutputStream stream = new BufferedOutputStream(new FileOutputStream(file))) { writeModel(model, stream, saveUpdater,dataNormalization); ...
[ "public", "static", "void", "writeModel", "(", "@", "NonNull", "Model", "model", ",", "@", "NonNull", "File", "file", ",", "boolean", "saveUpdater", ",", "DataNormalization", "dataNormalization", ")", "throws", "IOException", "{", "try", "(", "BufferedOutputStream...
Write a model to a file @param model the model to write @param file the file to write to @param saveUpdater whether to save the updater or not @param dataNormalization the normalizer to save (optional) @throws IOException
[ "Write", "a", "model", "to", "a", "file" ]
train
https://github.com/deeplearning4j/deeplearning4j/blob/effce52f2afd7eeb53c5bcca699fcd90bd06822f/deeplearning4j/deeplearning4j-nn/src/main/java/org/deeplearning4j/util/ModelSerializer.java#L89-L93
alkacon/opencms-core
src/org/opencms/db/CmsExportPointDriver.java
CmsExportPointDriver.writeResource
protected void writeResource(File file, byte[] content) { """ Writes file data to the RFS.<p> @param file the RFS file location @param content the file content """ try { File folder; if (content == null) { // a folder is to be created folder ...
java
protected void writeResource(File file, byte[] content) { try { File folder; if (content == null) { // a folder is to be created folder = file; } else { // a file is to be written folder = file.getParentFile(); ...
[ "protected", "void", "writeResource", "(", "File", "file", ",", "byte", "[", "]", "content", ")", "{", "try", "{", "File", "folder", ";", "if", "(", "content", "==", "null", ")", "{", "// a folder is to be created", "folder", "=", "file", ";", "}", "else...
Writes file data to the RFS.<p> @param file the RFS file location @param content the file content
[ "Writes", "file", "data", "to", "the", "RFS", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/db/CmsExportPointDriver.java#L188-L218
fernandospr/javapns-jdk16
src/main/java/javapns/communication/KeystoreManager.java
KeystoreManager.ensureReusableKeystore
static Object ensureReusableKeystore(AppleServer server, Object keystore) throws KeystoreException { """ Make sure that the provided keystore will be reusable. @param server the server the keystore is intended for @param keystore a keystore containing your private key and the certificate signed by Apple (File,...
java
static Object ensureReusableKeystore(AppleServer server, Object keystore) throws KeystoreException { if (keystore instanceof InputStream) keystore = loadKeystore(server, keystore, false); return keystore; }
[ "static", "Object", "ensureReusableKeystore", "(", "AppleServer", "server", ",", "Object", "keystore", ")", "throws", "KeystoreException", "{", "if", "(", "keystore", "instanceof", "InputStream", ")", "keystore", "=", "loadKeystore", "(", "server", ",", "keystore", ...
Make sure that the provided keystore will be reusable. @param server the server the keystore is intended for @param keystore a keystore containing your private key and the certificate signed by Apple (File, InputStream, byte[], KeyStore or String for a file path) @return a reusable keystore @throws KeystoreException
[ "Make", "sure", "that", "the", "provided", "keystore", "will", "be", "reusable", "." ]
train
https://github.com/fernandospr/javapns-jdk16/blob/84de6d9328ab01af92f77cc60c4554de02420909/src/main/java/javapns/communication/KeystoreManager.java#L86-L89
BioPAX/Paxtools
pattern/src/main/java/org/biopax/paxtools/pattern/PatternBox.java
PatternBox.molecularInteraction
public static Pattern molecularInteraction() { """ Constructs a pattern where first and last molecules are participants of a MolecularInteraction. @return the pattern """ Pattern p = new Pattern(SequenceEntityReference.class, "Protein 1"); p.add(linkedER(true), "Protein 1", "generic Protein 1"); p.add(...
java
public static Pattern molecularInteraction() { Pattern p = new Pattern(SequenceEntityReference.class, "Protein 1"); p.add(linkedER(true), "Protein 1", "generic Protein 1"); p.add(erToPE(), "generic Protein 1", "SPE1"); p.add(linkToComplex(), "SPE1", "PE1"); p.add(new PathConstraint("PhysicalEntity/participan...
[ "public", "static", "Pattern", "molecularInteraction", "(", ")", "{", "Pattern", "p", "=", "new", "Pattern", "(", "SequenceEntityReference", ".", "class", ",", "\"Protein 1\"", ")", ";", "p", ".", "add", "(", "linkedER", "(", "true", ")", ",", "\"Protein 1\"...
Constructs a pattern where first and last molecules are participants of a MolecularInteraction. @return the pattern
[ "Constructs", "a", "pattern", "where", "first", "and", "last", "molecules", "are", "participants", "of", "a", "MolecularInteraction", "." ]
train
https://github.com/BioPAX/Paxtools/blob/2f93afa94426bf8b5afc2e0e61cd4b269a83288d/pattern/src/main/java/org/biopax/paxtools/pattern/PatternBox.java#L647-L668
alkacon/opencms-core
src-gwt/org/opencms/gwt/client/ui/CmsTabbedPanel.java
CmsTabbedPanel.addWithLeftMargin
public void addWithLeftMargin(E tabContent, String tabName) { """ Add a new tab with the provided name and content and additional left margin.<p> @param tabContent the widget to add as a tab @param tabName the name of the tab to display in the tabbar """ tabContent.addStyleName(I_CmsLayoutBundle.I...
java
public void addWithLeftMargin(E tabContent, String tabName) { tabContent.addStyleName(I_CmsLayoutBundle.INSTANCE.generalCss().cornerAll()); m_tabPanel.add(tabContent, CmsDomUtil.stripHtml(tabName)); int tabIndex = m_tabPanel.getWidgetIndex(tabContent); Element tabElement = getTabElemen...
[ "public", "void", "addWithLeftMargin", "(", "E", "tabContent", ",", "String", "tabName", ")", "{", "tabContent", ".", "addStyleName", "(", "I_CmsLayoutBundle", ".", "INSTANCE", ".", "generalCss", "(", ")", ".", "cornerAll", "(", ")", ")", ";", "m_tabPanel", ...
Add a new tab with the provided name and content and additional left margin.<p> @param tabContent the widget to add as a tab @param tabName the name of the tab to display in the tabbar
[ "Add", "a", "new", "tab", "with", "the", "provided", "name", "and", "content", "and", "additional", "left", "margin", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src-gwt/org/opencms/gwt/client/ui/CmsTabbedPanel.java#L352-L367
lessthanoptimal/BoofCV
main/boofcv-geo/src/main/java/boofcv/abst/geo/bundle/SceneStructureMetric.java
SceneStructureMetric.setRigid
public void setRigid( int which , boolean fixed , Se3_F64 worldToObject , int totalPoints ) { """ Declares the data structure for a rigid object. Location of points are set by accessing the object directly. Rigid objects are useful in known scenes with calibration targets. @param which Index of rigid object @...
java
public void setRigid( int which , boolean fixed , Se3_F64 worldToObject , int totalPoints ) { Rigid r = rigids[which] = new Rigid(); r.known = fixed; r.objectToWorld.set(worldToObject); r.points = new Point[totalPoints]; for (int i = 0; i < totalPoints; i++) { r.points[i] = new Point(pointSize); } }
[ "public", "void", "setRigid", "(", "int", "which", ",", "boolean", "fixed", ",", "Se3_F64", "worldToObject", ",", "int", "totalPoints", ")", "{", "Rigid", "r", "=", "rigids", "[", "which", "]", "=", "new", "Rigid", "(", ")", ";", "r", ".", "known", "...
Declares the data structure for a rigid object. Location of points are set by accessing the object directly. Rigid objects are useful in known scenes with calibration targets. @param which Index of rigid object @param fixed If the pose is known or not @param worldToObject Initial estimated location of rigid object @pa...
[ "Declares", "the", "data", "structure", "for", "a", "rigid", "object", ".", "Location", "of", "points", "are", "set", "by", "accessing", "the", "object", "directly", ".", "Rigid", "objects", "are", "useful", "in", "known", "scenes", "with", "calibration", "t...
train
https://github.com/lessthanoptimal/BoofCV/blob/f01c0243da0ec086285ee722183804d5923bc3ac/main/boofcv-geo/src/main/java/boofcv/abst/geo/bundle/SceneStructureMetric.java#L168-L176
pip-services3-java/pip-services3-components-java
src/org/pipservices3/components/count/CompositeCounters.java
CompositeCounters.endTiming
public void endTiming(String name, float elapsed) { """ Ends measurement of execution elapsed time and updates specified counter. @param name a counter name @param elapsed execution elapsed time in milliseconds to update the counter. @see Timing#endTiming() """ for (ICounters counter : _counters) {...
java
public void endTiming(String name, float elapsed) { for (ICounters counter : _counters) { if (counter instanceof ITimingCallback) ((ITimingCallback) counter).endTiming(name, elapsed); } }
[ "public", "void", "endTiming", "(", "String", "name", ",", "float", "elapsed", ")", "{", "for", "(", "ICounters", "counter", ":", "_counters", ")", "{", "if", "(", "counter", "instanceof", "ITimingCallback", ")", "(", "(", "ITimingCallback", ")", "counter", ...
Ends measurement of execution elapsed time and updates specified counter. @param name a counter name @param elapsed execution elapsed time in milliseconds to update the counter. @see Timing#endTiming()
[ "Ends", "measurement", "of", "execution", "elapsed", "time", "and", "updates", "specified", "counter", "." ]
train
https://github.com/pip-services3-java/pip-services3-components-java/blob/122352fbf9b208f6417376da7b8ad725bc85ee58/src/org/pipservices3/components/count/CompositeCounters.java#L86-L91
alkacon/opencms-core
src/org/opencms/workflow/CmsExtendedWorkflowManager.java
CmsExtendedWorkflowManager.getPublishBrokenRelationsResponse
protected CmsWorkflowResponse getPublishBrokenRelationsResponse( CmsObject userCms, List<CmsPublishResource> publishResources) { """ Helper method for generating the workflow response which should be sent when publishing the resources would break relations.<p> @param userCms the user's CMS con...
java
protected CmsWorkflowResponse getPublishBrokenRelationsResponse( CmsObject userCms, List<CmsPublishResource> publishResources) { List<CmsWorkflowAction> actions = new ArrayList<CmsWorkflowAction>(); String forcePublishLabel = Messages.get().getBundle(getLocale(userCms)).key( ...
[ "protected", "CmsWorkflowResponse", "getPublishBrokenRelationsResponse", "(", "CmsObject", "userCms", ",", "List", "<", "CmsPublishResource", ">", "publishResources", ")", "{", "List", "<", "CmsWorkflowAction", ">", "actions", "=", "new", "ArrayList", "<", "CmsWorkflowA...
Helper method for generating the workflow response which should be sent when publishing the resources would break relations.<p> @param userCms the user's CMS context @param publishResources the resources whose links would be broken @return the workflow response
[ "Helper", "method", "for", "generating", "the", "workflow", "response", "which", "should", "be", "sent", "when", "publishing", "the", "resources", "would", "break", "relations", ".", "<p", ">" ]
train
https://github.com/alkacon/opencms-core/blob/bc104acc75d2277df5864da939a1f2de5fdee504/src/org/opencms/workflow/CmsExtendedWorkflowManager.java#L579-L595
intellimate/Izou
src/main/java/org/intellimate/izou/support/SystemMail.java
SystemMail.sendMail
public void sendMail(String toAddress, String subject, String content) { """ Sends a mail to the address of {@code toAddress} with a subject of {@code subject} and a content of {@code content} WITHOUT an attachment @param toAddress the address to send the mail to @param subject the subject of the email to sen...
java
public void sendMail(String toAddress, String subject, String content) { final String SSL_FACTORY = "javax.net.ssl.SSLSocketFactory"; logger.debug("Sending mail..."); Properties props = System.getProperties(); props.setProperty("mail.smtp.host", "smtp.gmail.com"); props.setPrope...
[ "public", "void", "sendMail", "(", "String", "toAddress", ",", "String", "subject", ",", "String", "content", ")", "{", "final", "String", "SSL_FACTORY", "=", "\"javax.net.ssl.SSLSocketFactory\"", ";", "logger", ".", "debug", "(", "\"Sending mail...\"", ")", ";", ...
Sends a mail to the address of {@code toAddress} with a subject of {@code subject} and a content of {@code content} WITHOUT an attachment @param toAddress the address to send the mail to @param subject the subject of the email to send @param content the content of the email (without attachment)
[ "Sends", "a", "mail", "to", "the", "address", "of", "{", "@code", "toAddress", "}", "with", "a", "subject", "of", "{", "@code", "subject", "}", "and", "a", "content", "of", "{", "@code", "content", "}", "WITHOUT", "an", "attachment" ]
train
https://github.com/intellimate/Izou/blob/40a808b97998e17655c4a78e30ce7326148aed27/src/main/java/org/intellimate/izou/support/SystemMail.java#L135-L170
molgenis/molgenis
molgenis-data-postgresql/src/main/java/org/molgenis/data/postgresql/PostgreSqlExceptionTranslator.java
PostgreSqlExceptionTranslator.translateForeignKeyViolation
MolgenisValidationException translateForeignKeyViolation(PSQLException pSqlException) { """ Package private for testability @param pSqlException PostgreSQL exception @return translated validation exception """ ServerErrorMessage serverErrorMessage = pSqlException.getServerErrorMessage(); String tab...
java
MolgenisValidationException translateForeignKeyViolation(PSQLException pSqlException) { ServerErrorMessage serverErrorMessage = pSqlException.getServerErrorMessage(); String tableName = serverErrorMessage.getTable(); String detailMessage = serverErrorMessage.getDetail(); Matcher m = Pattern.compile("\\(...
[ "MolgenisValidationException", "translateForeignKeyViolation", "(", "PSQLException", "pSqlException", ")", "{", "ServerErrorMessage", "serverErrorMessage", "=", "pSqlException", ".", "getServerErrorMessage", "(", ")", ";", "String", "tableName", "=", "serverErrorMessage", "."...
Package private for testability @param pSqlException PostgreSQL exception @return translated validation exception
[ "Package", "private", "for", "testability" ]
train
https://github.com/molgenis/molgenis/blob/b4d0d6b27e6f6c8d7505a3863dc03b589601f987/molgenis-data-postgresql/src/main/java/org/molgenis/data/postgresql/PostgreSqlExceptionTranslator.java#L329-L370
Carbonado/Carbonado
src/main/java/com/amazon/carbonado/qe/AbstractQueryExecutor.java
AbstractQueryExecutor.indent
protected void indent(Appendable app, int indentLevel) throws IOException { """ Appends spaces to the given appendable. Useful for implementing printNative and printPlan. """ for (int i=0; i<indentLevel; i++) { app.append(' '); } }
java
protected void indent(Appendable app, int indentLevel) throws IOException { for (int i=0; i<indentLevel; i++) { app.append(' '); } }
[ "protected", "void", "indent", "(", "Appendable", "app", ",", "int", "indentLevel", ")", "throws", "IOException", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "indentLevel", ";", "i", "++", ")", "{", "app", ".", "append", "(", "'", "'", ")...
Appends spaces to the given appendable. Useful for implementing printNative and printPlan.
[ "Appends", "spaces", "to", "the", "given", "appendable", ".", "Useful", "for", "implementing", "printNative", "and", "printPlan", "." ]
train
https://github.com/Carbonado/Carbonado/blob/eee29b365a61c8f03e1a1dc6bed0692e6b04b1db/src/main/java/com/amazon/carbonado/qe/AbstractQueryExecutor.java#L133-L137
RestComm/Restcomm-Connect
restcomm/restcomm.telephony.api/src/main/java/org/restcomm/connect/telephony/api/util/B2BUAHelper.java
B2BUAHelper.addHeadersToMessage
private static void addHeadersToMessage(SipServletMessage message, Map<String, String> customHeaders) { """ Method adds custom headers to a SipServlet message @param message @param customHeaders """ for (Map.Entry<String, String> entry: customHeaders.entrySet()) { String headerName = en...
java
private static void addHeadersToMessage(SipServletMessage message, Map<String, String> customHeaders) { for (Map.Entry<String, String> entry: customHeaders.entrySet()) { String headerName = entry.getKey(); String headerVal = entry.getValue(); message.addHeader(headerName,...
[ "private", "static", "void", "addHeadersToMessage", "(", "SipServletMessage", "message", ",", "Map", "<", "String", ",", "String", ">", "customHeaders", ")", "{", "for", "(", "Map", ".", "Entry", "<", "String", ",", "String", ">", "entry", ":", "customHeader...
Method adds custom headers to a SipServlet message @param message @param customHeaders
[ "Method", "adds", "custom", "headers", "to", "a", "SipServlet", "message" ]
train
https://github.com/RestComm/Restcomm-Connect/blob/2194dee4fc524cdfd0af77a218ba5f212f97f7c5/restcomm/restcomm.telephony.api/src/main/java/org/restcomm/connect/telephony/api/util/B2BUAHelper.java#L726-L732
Azure/azure-sdk-for-java
labservices/resource-manager/v2018_10_15/src/main/java/com/microsoft/azure/management/labservices/v2018_10_15/implementation/EnvironmentsInner.java
EnvironmentsInner.listAsync
public Observable<Page<EnvironmentInner>> listAsync(final String resourceGroupName, final String labAccountName, final String labName, final String environmentSettingName) { """ List environments in a given environment setting. @param resourceGroupName The name of the resource group. @param labAccountName The ...
java
public Observable<Page<EnvironmentInner>> listAsync(final String resourceGroupName, final String labAccountName, final String labName, final String environmentSettingName) { return listWithServiceResponseAsync(resourceGroupName, labAccountName, labName, environmentSettingName) .map(new Func1<Service...
[ "public", "Observable", "<", "Page", "<", "EnvironmentInner", ">", ">", "listAsync", "(", "final", "String", "resourceGroupName", ",", "final", "String", "labAccountName", ",", "final", "String", "labName", ",", "final", "String", "environmentSettingName", ")", "{...
List environments in a given environment setting. @param resourceGroupName The name of the resource group. @param labAccountName The name of the lab Account. @param labName The name of the lab. @param environmentSettingName The name of the environment Setting. @throws IllegalArgumentException thrown if parameters fail...
[ "List", "environments", "in", "a", "given", "environment", "setting", "." ]
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/EnvironmentsInner.java#L181-L189
raydac/java-binary-block-parser
jbbp/src/main/java/com/igormaznitsa/jbbp/mapper/JBBPMapper.java
JBBPMapper.allocateMemoryForClass
private static <T> T allocateMemoryForClass(final JBBPFieldStruct root, final Class<T> klazz) { """ Makes an instance of a class without call of its constructor, just allocate memory @param <T> a class which instance is needed @param root the structure to be mapped, it is needed as info for exception @par...
java
private static <T> T allocateMemoryForClass(final JBBPFieldStruct root, final Class<T> klazz) { try { return CLASS_INSTANTIATOR.makeClassInstance(klazz); } catch (InstantiationException ex) { throw new JBBPMapperException("Can't make an instance of a class", root, klazz, null, ex); } }
[ "private", "static", "<", "T", ">", "T", "allocateMemoryForClass", "(", "final", "JBBPFieldStruct", "root", ",", "final", "Class", "<", "T", ">", "klazz", ")", "{", "try", "{", "return", "CLASS_INSTANTIATOR", ".", "makeClassInstance", "(", "klazz", ")", ";",...
Makes an instance of a class without call of its constructor, just allocate memory @param <T> a class which instance is needed @param root the structure to be mapped, it is needed as info for exception @param klazz the class which instance is needed @return an instance of the class without called constructor @throw...
[ "Makes", "an", "instance", "of", "a", "class", "without", "call", "of", "its", "constructor", "just", "allocate", "memory" ]
train
https://github.com/raydac/java-binary-block-parser/blob/6d98abcab01e0c72d525ebcc9e7b694f9ce49f5b/jbbp/src/main/java/com/igormaznitsa/jbbp/mapper/JBBPMapper.java#L601-L607
wildfly/wildfly-core
controller-client/src/main/java/org/jboss/as/controller/client/helpers/Operations.java
Operations.createWriteAttributeOperation
public static ModelNode createWriteAttributeOperation(final ModelNode address, final String attributeName, final boolean value) { """ Creates an operation to write an attribute value represented by the {@code attributeName} parameter. @param address the address to create the write attribute for @param at...
java
public static ModelNode createWriteAttributeOperation(final ModelNode address, final String attributeName, final boolean value) { final ModelNode op = createNoValueWriteOperation(address, attributeName); op.get(VALUE).set(value); return op; }
[ "public", "static", "ModelNode", "createWriteAttributeOperation", "(", "final", "ModelNode", "address", ",", "final", "String", "attributeName", ",", "final", "boolean", "value", ")", "{", "final", "ModelNode", "op", "=", "createNoValueWriteOperation", "(", "address",...
Creates an operation to write an attribute value represented by the {@code attributeName} parameter. @param address the address to create the write attribute for @param attributeName the name of the attribute to write @param value the value to set the attribute to @return the operation
[ "Creates", "an", "operation", "to", "write", "an", "attribute", "value", "represented", "by", "the", "{", "@code", "attributeName", "}", "parameter", "." ]
train
https://github.com/wildfly/wildfly-core/blob/cfaf0479dcbb2d320a44c5374b93b944ec39fade/controller-client/src/main/java/org/jboss/as/controller/client/helpers/Operations.java#L274-L278
UrielCh/ovh-java-sdk
ovh-java-sdk-telephony/src/main/java/net/minidev/ovh/api/ApiOvhTelephony.java
ApiOvhTelephony.billingAccount_line_serviceName_phone_rma_id_PUT
public void billingAccount_line_serviceName_phone_rma_id_PUT(String billingAccount, String serviceName, String id, OvhRma body) throws IOException { """ Alter this object properties REST: PUT /telephony/{billingAccount}/line/{serviceName}/phone/rma/{id} @param body [required] New object properties @param bill...
java
public void billingAccount_line_serviceName_phone_rma_id_PUT(String billingAccount, String serviceName, String id, OvhRma body) throws IOException { String qPath = "/telephony/{billingAccount}/line/{serviceName}/phone/rma/{id}"; StringBuilder sb = path(qPath, billingAccount, serviceName, id); exec(qPath, "PUT", s...
[ "public", "void", "billingAccount_line_serviceName_phone_rma_id_PUT", "(", "String", "billingAccount", ",", "String", "serviceName", ",", "String", "id", ",", "OvhRma", "body", ")", "throws", "IOException", "{", "String", "qPath", "=", "\"/telephony/{billingAccount}/line/...
Alter this object properties REST: PUT /telephony/{billingAccount}/line/{serviceName}/phone/rma/{id} @param body [required] New object properties @param billingAccount [required] The name of your billingAccount @param serviceName [required] @param id [required] Return merchandise authorisation identifier
[ "Alter", "this", "object", "properties" ]
train
https://github.com/UrielCh/ovh-java-sdk/blob/6d531a40e56e09701943e334c25f90f640c55701/ovh-java-sdk-telephony/src/main/java/net/minidev/ovh/api/ApiOvhTelephony.java#L1012-L1016
atomix/atomix
protocols/raft/src/main/java/io/atomix/protocols/raft/service/RaftServiceContext.java
RaftServiceContext.executeCommand
public OperationResult executeCommand(long index, long sequence, long timestamp, RaftSession session, PrimitiveOperation operation) { """ Executes the given command on the state machine. @param index The index of the command. @param timestamp The timestamp of the command. @param sequence The command sequ...
java
public OperationResult executeCommand(long index, long sequence, long timestamp, RaftSession session, PrimitiveOperation operation) { // If the service has been deleted then throw an unknown service exception. if (deleted) { log.warn("Service {} has been deleted by another process", serviceName); th...
[ "public", "OperationResult", "executeCommand", "(", "long", "index", ",", "long", "sequence", ",", "long", "timestamp", ",", "RaftSession", "session", ",", "PrimitiveOperation", "operation", ")", "{", "// If the service has been deleted then throw an unknown service exception...
Executes the given command on the state machine. @param index The index of the command. @param timestamp The timestamp of the command. @param sequence The command sequence number. @param session The session that submitted the command. @param operation The command to execute. @return A future to be completed wit...
[ "Executes", "the", "given", "command", "on", "the", "state", "machine", "." ]
train
https://github.com/atomix/atomix/blob/3a94b7c80576d762dd0d396d4645df07a0b37c31/protocols/raft/src/main/java/io/atomix/protocols/raft/service/RaftServiceContext.java#L483-L516
terrestris/shogun-core
src/shogun-core-main/src/main/java/de/terrestris/shoguncore/dao/GenericHibernateDao.java
GenericHibernateDao.addCriterionsToCriteria
private void addCriterionsToCriteria(Criteria criteria, Criterion... criterion) { """ Helper method: Adds all criterions to the criteria (if not null). @param criteria @param criterion """ if (criteria != null) { for (Criterion c : criterion) { if (c != null) { ...
java
private void addCriterionsToCriteria(Criteria criteria, Criterion... criterion) { if (criteria != null) { for (Criterion c : criterion) { if (c != null) { criteria.add(c); } } } }
[ "private", "void", "addCriterionsToCriteria", "(", "Criteria", "criteria", ",", "Criterion", "...", "criterion", ")", "{", "if", "(", "criteria", "!=", "null", ")", "{", "for", "(", "Criterion", "c", ":", "criterion", ")", "{", "if", "(", "c", "!=", "nul...
Helper method: Adds all criterions to the criteria (if not null). @param criteria @param criterion
[ "Helper", "method", ":", "Adds", "all", "criterions", "to", "the", "criteria", "(", "if", "not", "null", ")", "." ]
train
https://github.com/terrestris/shogun-core/blob/3dbabda35ae63235265913c865dba389b050b6e6/src/shogun-core-main/src/main/java/de/terrestris/shoguncore/dao/GenericHibernateDao.java#L489-L497
graphhopper/graphhopper
client-hc/src/main/java/com/graphhopper/api/MatrixResponse.java
MatrixResponse.getTime
public long getTime(int from, int to) { """ Returns the time for the specific entry (from -&gt; to) in milliseconds. """ if (hasErrors()) { throw new IllegalStateException("Cannot return time (" + from + "," + to + ") if errors occured " + getErrors()); } if (from >= times....
java
public long getTime(int from, int to) { if (hasErrors()) { throw new IllegalStateException("Cannot return time (" + from + "," + to + ") if errors occured " + getErrors()); } if (from >= times.length) { throw new IllegalStateException("Cannot get 'from' " + from + " from...
[ "public", "long", "getTime", "(", "int", "from", ",", "int", "to", ")", "{", "if", "(", "hasErrors", "(", ")", ")", "{", "throw", "new", "IllegalStateException", "(", "\"Cannot return time (\"", "+", "from", "+", "\",\"", "+", "to", "+", "\") if errors occ...
Returns the time for the specific entry (from -&gt; to) in milliseconds.
[ "Returns", "the", "time", "for", "the", "specific", "entry", "(", "from", "-", "&gt", ";", "to", ")", "in", "milliseconds", "." ]
train
https://github.com/graphhopper/graphhopper/blob/c235e306e6e823043cadcc41ead0e685bdebf737/client-hc/src/main/java/com/graphhopper/api/MatrixResponse.java#L101-L112
smartsheet-platform/smartsheet-java-sdk
src/main/java/com/smartsheet/api/internal/AbstractResources.java
AbstractResources.copyStream
@Deprecated // replace with StreamUtil.copyContentIntoOutputStream() private static void copyStream(InputStream input, OutputStream output) throws IOException { """ Copy stream. @param input the input @param output the output @throws IOException Signals that an I/O exception has occurred. """ ...
java
@Deprecated // replace with StreamUtil.copyContentIntoOutputStream() private static void copyStream(InputStream input, OutputStream output) throws IOException { byte[] buffer = new byte[BUFFER_SIZE]; int len; while ((len = input.read(buffer)) != -1) { output.write(buffer, 0, len)...
[ "@", "Deprecated", "// replace with StreamUtil.copyContentIntoOutputStream()", "private", "static", "void", "copyStream", "(", "InputStream", "input", ",", "OutputStream", "output", ")", "throws", "IOException", "{", "byte", "[", "]", "buffer", "=", "new", "byte", "["...
Copy stream. @param input the input @param output the output @throws IOException Signals that an I/O exception has occurred.
[ "Copy", "stream", "." ]
train
https://github.com/smartsheet-platform/smartsheet-java-sdk/blob/f60e264412076271f83b65889ef9b891fad83df8/src/main/java/com/smartsheet/api/internal/AbstractResources.java#L972-L979
apptentive/apptentive-android
apptentive/src/main/java/com/apptentive/android/sdk/util/threading/DispatchQueue.java
DispatchQueue.createBackgroundQueue
public static DispatchQueue createBackgroundQueue(String name, DispatchQueueType type) { """ Creates a background queue with specified <code>name</code> and dispatch type. """ if (type == DispatchQueueType.Serial) { return new SerialDispatchQueue(name); } if (type == DispatchQueueType.Concurrent) { ...
java
public static DispatchQueue createBackgroundQueue(String name, DispatchQueueType type) { if (type == DispatchQueueType.Serial) { return new SerialDispatchQueue(name); } if (type == DispatchQueueType.Concurrent) { return new ConcurrentDispatchQueue(name); } throw new IllegalArgumentException("Unexpected...
[ "public", "static", "DispatchQueue", "createBackgroundQueue", "(", "String", "name", ",", "DispatchQueueType", "type", ")", "{", "if", "(", "type", "==", "DispatchQueueType", ".", "Serial", ")", "{", "return", "new", "SerialDispatchQueue", "(", "name", ")", ";",...
Creates a background queue with specified <code>name</code> and dispatch type.
[ "Creates", "a", "background", "queue", "with", "specified", "<code", ">", "name<", "/", "code", ">", "and", "dispatch", "type", "." ]
train
https://github.com/apptentive/apptentive-android/blob/887c08d7bd5ae6488a90366dfb58f58938861a93/apptentive/src/main/java/com/apptentive/android/sdk/util/threading/DispatchQueue.java#L132-L141
apache/incubator-gobblin
gobblin-config-management/gobblin-config-core/src/main/java/org/apache/gobblin/config/common/impl/ConfigStoreBackedValueInspector.java
ConfigStoreBackedValueInspector.getResolvedConfig
public Config getResolvedConfig(ConfigKeyPath configKey, Optional<Config> runtimeConfig) { """ {@inheritDoc}. <p> This implementation simply delegate the functionality to the internal {@link ConfigStore}/version if the internal {@link ConfigStore} is {@link ConfigStoreWithResolution}, otherwise based on {@lin...
java
public Config getResolvedConfig(ConfigKeyPath configKey, Optional<Config> runtimeConfig) { return getResolvedConfigRecursive(configKey, Sets.<String>newHashSet(), runtimeConfig) .withFallback(ConfigFactory.defaultOverrides()).withFallback(ConfigFactory.systemEnvironment()).resolve(); }
[ "public", "Config", "getResolvedConfig", "(", "ConfigKeyPath", "configKey", ",", "Optional", "<", "Config", ">", "runtimeConfig", ")", "{", "return", "getResolvedConfigRecursive", "(", "configKey", ",", "Sets", ".", "<", "String", ">", "newHashSet", "(", ")", ",...
{@inheritDoc}. <p> This implementation simply delegate the functionality to the internal {@link ConfigStore}/version if the internal {@link ConfigStore} is {@link ConfigStoreWithResolution}, otherwise based on {@link ConfigStoreTopologyInspector} 1. find out all the imports recursively 2. resolved the config on the f...
[ "{", "@inheritDoc", "}", "." ]
train
https://github.com/apache/incubator-gobblin/blob/f029b4c0fea0fe4aa62f36dda2512344ff708bae/gobblin-config-management/gobblin-config-core/src/main/java/org/apache/gobblin/config/common/impl/ConfigStoreBackedValueInspector.java#L154-L157
meltmedia/cadmium
core/src/main/java/com/meltmedia/cadmium/core/config/impl/YamlConfigurationParser.java
YamlConfigurationParser.getEnvConfig
private <T> T getEnvConfig(Map<String, ?> configs, String key, Class<T> type) { """ Helper method used to retrieve the value from a given map if it matches the type specified. @param configs The map to pull from. @param key The key to pull. @param type The expected type of the value. @return """ if(c...
java
private <T> T getEnvConfig(Map<String, ?> configs, String key, Class<T> type) { if(configs.containsKey(key)) { Object config = configs.get(key); if(type.isAssignableFrom(config.getClass())) { return type.cast(config); } } return null; }
[ "private", "<", "T", ">", "T", "getEnvConfig", "(", "Map", "<", "String", ",", "?", ">", "configs", ",", "String", "key", ",", "Class", "<", "T", ">", "type", ")", "{", "if", "(", "configs", ".", "containsKey", "(", "key", ")", ")", "{", "Object"...
Helper method used to retrieve the value from a given map if it matches the type specified. @param configs The map to pull from. @param key The key to pull. @param type The expected type of the value. @return
[ "Helper", "method", "used", "to", "retrieve", "the", "value", "from", "a", "given", "map", "if", "it", "matches", "the", "type", "specified", "." ]
train
https://github.com/meltmedia/cadmium/blob/bca585030e141803a73b58abb128d130157b6ddf/core/src/main/java/com/meltmedia/cadmium/core/config/impl/YamlConfigurationParser.java#L201-L209
Stratio/deep-spark
deep-commons/src/main/java/com/stratio/deep/commons/entity/Cells.java
Cells.getBigDecimal
public BigDecimal getBigDecimal(String nameSpace, String cellName) { """ Returns the {@code BigInteger} value of the {@link Cell} (associated to {@code table}) whose name iscellName, or null if this Cells object contains no cell whose name is cellName. @param nameSpace the name of the owning table @param cell...
java
public BigDecimal getBigDecimal(String nameSpace, String cellName) { return getValue(nameSpace, cellName, BigDecimal.class); }
[ "public", "BigDecimal", "getBigDecimal", "(", "String", "nameSpace", ",", "String", "cellName", ")", "{", "return", "getValue", "(", "nameSpace", ",", "cellName", ",", "BigDecimal", ".", "class", ")", ";", "}" ]
Returns the {@code BigInteger} value of the {@link Cell} (associated to {@code table}) whose name iscellName, or null if this Cells object contains no cell whose name is cellName. @param nameSpace the name of the owning table @param cellName the name of the Cell we want to retrieve from this Cells object. @return the...
[ "Returns", "the", "{", "@code", "BigInteger", "}", "value", "of", "the", "{", "@link", "Cell", "}", "(", "associated", "to", "{", "@code", "table", "}", ")", "whose", "name", "iscellName", "or", "null", "if", "this", "Cells", "object", "contains", "no", ...
train
https://github.com/Stratio/deep-spark/blob/b9621c9b7a6d996f80fce1d073d696a157bed095/deep-commons/src/main/java/com/stratio/deep/commons/entity/Cells.java#L1267-L1269
gallandarakhneorg/afc
core/vmutils/src/main/java/org/arakhne/afc/vmutil/VMCommandLine.java
VMCommandLine.saveVMParametersIfNotSet
public static void saveVMParametersIfNotSet(String classToLaunch, String... parameters) { """ Save parameters that permit to relaunch a VM with {@link #relaunchVM()}. @param classToLaunch is the class which contains a <code>main</code>. @param parameters is the parameters to pass to the <code>main</code>. @s...
java
public static void saveVMParametersIfNotSet(String classToLaunch, String... parameters) { if (classnameToLaunch == null || "".equals(classnameToLaunch)) { //$NON-NLS-1$ saveVMParameters(classToLaunch, parameters); } }
[ "public", "static", "void", "saveVMParametersIfNotSet", "(", "String", "classToLaunch", ",", "String", "...", "parameters", ")", "{", "if", "(", "classnameToLaunch", "==", "null", "||", "\"\"", ".", "equals", "(", "classnameToLaunch", ")", ")", "{", "//$NON-NLS-...
Save parameters that permit to relaunch a VM with {@link #relaunchVM()}. @param classToLaunch is the class which contains a <code>main</code>. @param parameters is the parameters to pass to the <code>main</code>. @since 6.2
[ "Save", "parameters", "that", "permit", "to", "relaunch", "a", "VM", "with", "{", "@link", "#relaunchVM", "()", "}", "." ]
train
https://github.com/gallandarakhneorg/afc/blob/0c7d2e1ddefd4167ef788416d970a6c1ef6f8bbb/core/vmutils/src/main/java/org/arakhne/afc/vmutil/VMCommandLine.java#L354-L358
DavidPizarro/PinView
library/src/main/java/com/dpizarro/pinview/library/PinView.java
PinView.onFocusChange
@Override public void onFocusChange(View v, boolean hasFocus) { """ Called when the focus state of a PinBox {@link EditText} has changed. @param v The PinBox {@link EditText} whose state has changed. @param hasFocus The new focus state of v. """ if (getOnFocusChangeListener() != null) { ...
java
@Override public void onFocusChange(View v, boolean hasFocus) { if (getOnFocusChangeListener() != null) { getOnFocusChangeListener().onFocusChange(v, hasFocus); } EditText et = (EditText) v; if (et.getText().toString().length() >= 1 && hasFocus && isDeleteOnClick()) { ...
[ "@", "Override", "public", "void", "onFocusChange", "(", "View", "v", ",", "boolean", "hasFocus", ")", "{", "if", "(", "getOnFocusChangeListener", "(", ")", "!=", "null", ")", "{", "getOnFocusChangeListener", "(", ")", ".", "onFocusChange", "(", "v", ",", ...
Called when the focus state of a PinBox {@link EditText} has changed. @param v The PinBox {@link EditText} whose state has changed. @param hasFocus The new focus state of v.
[ "Called", "when", "the", "focus", "state", "of", "a", "PinBox", "{", "@link", "EditText", "}", "has", "changed", "." ]
train
https://github.com/DavidPizarro/PinView/blob/b171a89694921475b5442585810b8475ef1cfe35/library/src/main/java/com/dpizarro/pinview/library/PinView.java#L150-L171
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/db/GridTable.java
GridTable.bookmarkToIndex
public int bookmarkToIndex(Object bookmark, int iHandleType) { """ Search through the buffers for this bookmark. @return int index in table; or -1 if not found. @param bookmark java.lang.Object The bookmark to search for. @param iHandleType The bookmark type. """ if (bookmark == null) re...
java
public int bookmarkToIndex(Object bookmark, int iHandleType) { if (bookmark == null) return -1; int iTargetPosition = m_gridBuffer.bookmarkToIndex(bookmark, iHandleType); if (iTargetPosition == -1) iTargetPosition = m_gridList.bookmarkToIndex(bookmark, iHandleType); ...
[ "public", "int", "bookmarkToIndex", "(", "Object", "bookmark", ",", "int", "iHandleType", ")", "{", "if", "(", "bookmark", "==", "null", ")", "return", "-", "1", ";", "int", "iTargetPosition", "=", "m_gridBuffer", ".", "bookmarkToIndex", "(", "bookmark", ","...
Search through the buffers for this bookmark. @return int index in table; or -1 if not found. @param bookmark java.lang.Object The bookmark to search for. @param iHandleType The bookmark type.
[ "Search", "through", "the", "buffers", "for", "this", "bookmark", "." ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/db/GridTable.java#L222-L230
riversun/d6
src/main/java/org/riversun/d6/core/ModelClazzColumnNameAndFieldMapper.java
ModelClazzColumnNameAndFieldMapper.build
private void build(Map<String, D6ModelClassFieldInfo> refFieldMap) { """ To populate FieldMap(key is columnName,value is fieldInfo) holding the column and fields @param refFieldMap reference of non-null field map @return """ refFieldMap.clear(); final Field[] fields = mModelClazz.ge...
java
private void build(Map<String, D6ModelClassFieldInfo> refFieldMap) { refFieldMap.clear(); final Field[] fields = mModelClazz.getFields(); for (int i = 0; i < fields.length; i++) { final Field field = fields[i]; final DBColumn annoColumn = field.getAnnotatio...
[ "private", "void", "build", "(", "Map", "<", "String", ",", "D6ModelClassFieldInfo", ">", "refFieldMap", ")", "{", "refFieldMap", ".", "clear", "(", ")", ";", "final", "Field", "[", "]", "fields", "=", "mModelClazz", ".", "getFields", "(", ")", ";", "for...
To populate FieldMap(key is columnName,value is fieldInfo) holding the column and fields @param refFieldMap reference of non-null field map @return
[ "To", "populate", "FieldMap", "(", "key", "is", "columnName", "value", "is", "fieldInfo", ")", "holding", "the", "column", "and", "fields" ]
train
https://github.com/riversun/d6/blob/2798bd876b9380dbfea8182d11ad306cb1b0e114/src/main/java/org/riversun/d6/core/ModelClazzColumnNameAndFieldMapper.java#L68-L106
census-instrumentation/opencensus-java
contrib/resource_util/src/main/java/io/opencensus/contrib/resource/util/HostResource.java
HostResource.create
public static Resource create(String hostname, String name, String id, String type) { """ Returns a {@link Resource} that describes a k8s container. @param hostname the hostname of the host. @param name the name of the host. @param id the unique host id (instance id in Cloud). @param type the type of the hos...
java
public static Resource create(String hostname, String name, String id, String type) { Map<String, String> labels = new LinkedHashMap<String, String>(); labels.put(HOSTNAME_KEY, checkNotNull(hostname, "hostname")); labels.put(NAME_KEY, checkNotNull(name, "name")); labels.put(ID_KEY, checkNotNull(id, "id"...
[ "public", "static", "Resource", "create", "(", "String", "hostname", ",", "String", "name", ",", "String", "id", ",", "String", "type", ")", "{", "Map", "<", "String", ",", "String", ">", "labels", "=", "new", "LinkedHashMap", "<", "String", ",", "String...
Returns a {@link Resource} that describes a k8s container. @param hostname the hostname of the host. @param name the name of the host. @param id the unique host id (instance id in Cloud). @param type the type of the host (machine type). @return a {@link Resource} that describes a k8s container. @since 0.20
[ "Returns", "a", "{", "@link", "Resource", "}", "that", "describes", "a", "k8s", "container", "." ]
train
https://github.com/census-instrumentation/opencensus-java/blob/deefac9bed77e40a2297bff1ca5ec5aa48a5f755/contrib/resource_util/src/main/java/io/opencensus/contrib/resource/util/HostResource.java#L82-L89
googlegenomics/utils-java
src/main/java/com/google/cloud/genomics/utils/GenomicsFactory.java
GenomicsFactory.fromOfflineAuth
public <T extends AbstractGoogleJsonClient.Builder> T fromOfflineAuth(T builder, OfflineAuth auth) { """ Prepare an AbstractGoogleJsonClient.Builder with the given OfflineAuth object. @param builder The builder to be prepared. @param auth The OfflineAuth @return The passed in builder, for easy chaining. "...
java
public <T extends AbstractGoogleJsonClient.Builder> T fromOfflineAuth(T builder, OfflineAuth auth) { Preconditions.checkNotNull(builder); Preconditions.checkNotNull(auth); if(auth.hasApiKey()) { return fromApiKey(builder, auth.getApiKey()); } return fromCredential(builder, auth.getCredential()...
[ "public", "<", "T", "extends", "AbstractGoogleJsonClient", ".", "Builder", ">", "T", "fromOfflineAuth", "(", "T", "builder", ",", "OfflineAuth", "auth", ")", "{", "Preconditions", ".", "checkNotNull", "(", "builder", ")", ";", "Preconditions", ".", "checkNotNull...
Prepare an AbstractGoogleJsonClient.Builder with the given OfflineAuth object. @param builder The builder to be prepared. @param auth The OfflineAuth @return The passed in builder, for easy chaining.
[ "Prepare", "an", "AbstractGoogleJsonClient", ".", "Builder", "with", "the", "given", "OfflineAuth", "object", "." ]
train
https://github.com/googlegenomics/utils-java/blob/7205d5b4e4f61fc6b93acb4bdd76b93df5b5f612/src/main/java/com/google/cloud/genomics/utils/GenomicsFactory.java#L490-L497
TakahikoKawasaki/nv-bluetooth
src/main/java/com/neovisionaries/bluetooth/ble/util/Bytes.java
Bytes.parseBE4BytesAsUnsigned
public static long parseBE4BytesAsUnsigned(byte[] data, int offset) { """ Parse 4 bytes in big endian byte order as an unsigned integer. """ long value = ((long)(data[offset + 0] & 0xFF) << 24) | ((long)(data[offset + 1] & 0xFF) << 16) | ((long)(data[offset + 2] & ...
java
public static long parseBE4BytesAsUnsigned(byte[] data, int offset) { long value = ((long)(data[offset + 0] & 0xFF) << 24) | ((long)(data[offset + 1] & 0xFF) << 16) | ((long)(data[offset + 2] & 0xFF) << 8) | ((long)(data[offset + 3] & 0xFF) << 0); ...
[ "public", "static", "long", "parseBE4BytesAsUnsigned", "(", "byte", "[", "]", "data", ",", "int", "offset", ")", "{", "long", "value", "=", "(", "(", "long", ")", "(", "data", "[", "offset", "+", "0", "]", "&", "0xFF", ")", "<<", "24", ")", "|", ...
Parse 4 bytes in big endian byte order as an unsigned integer.
[ "Parse", "4", "bytes", "in", "big", "endian", "byte", "order", "as", "an", "unsigned", "integer", "." ]
train
https://github.com/TakahikoKawasaki/nv-bluetooth/blob/ef0099e941cd377571398615ea5e18cfc84cadd3/src/main/java/com/neovisionaries/bluetooth/ble/util/Bytes.java#L64-L72
jbundle/jbundle
base/base/src/main/java/org/jbundle/base/field/event/DateUpdatedHandler.java
DateUpdatedHandler.fieldChanged
public int fieldChanged(boolean bDisplayOption, int iMoveMode) { """ The Field has Changed. @param bDisplayOption If true, display the change. @param iMoveMode The type of move being done (init/read/screen). @return The error code (or NORMAL_RETURN if okay). """ // Read a valid record if (this.getOw...
java
public int fieldChanged(boolean bDisplayOption, int iMoveMode) { // Read a valid record if (this.getOwner().getRecord().getField(m_iMainFilesFieldSeq) instanceof DateTimeField) { DateTimeField thisField = ((DateTimeField)this.getOwner().getRecord().getField(m_iMainFilesFieldSeq)); ...
[ "public", "int", "fieldChanged", "(", "boolean", "bDisplayOption", ",", "int", "iMoveMode", ")", "{", "// Read a valid record", "if", "(", "this", ".", "getOwner", "(", ")", ".", "getRecord", "(", ")", ".", "getField", "(", "m_iMainFilesFieldSeq", ")", "instan...
The Field has Changed. @param bDisplayOption If true, display the change. @param iMoveMode The type of move being done (init/read/screen). @return The error code (or NORMAL_RETURN if okay).
[ "The", "Field", "has", "Changed", "." ]
train
https://github.com/jbundle/jbundle/blob/4037fcfa85f60c7d0096c453c1a3cd573c2b0abc/base/base/src/main/java/org/jbundle/base/field/event/DateUpdatedHandler.java#L92-L108
apache/incubator-gobblin
gobblin-core/src/main/java/org/apache/gobblin/source/extractor/utils/Utils.java
Utils.csvToJsonObject
public static JsonObject csvToJsonObject(List<String> bulkRecordHeader, List<String> record, int columnCount) { """ Convert CSV record(List<Strings>) to JsonObject using header(column Names) @param header record @param data record @param column Count @return JsonObject """ ObjectMapper mapper = new Obj...
java
public static JsonObject csvToJsonObject(List<String> bulkRecordHeader, List<String> record, int columnCount) { ObjectMapper mapper = new ObjectMapper(); Map<String, String> resultInfo = new HashMap<>(); for (int i = 0; i < columnCount; i++) { resultInfo.put(bulkRecordHeader.get(i), record.get(i)); ...
[ "public", "static", "JsonObject", "csvToJsonObject", "(", "List", "<", "String", ">", "bulkRecordHeader", ",", "List", "<", "String", ">", "record", ",", "int", "columnCount", ")", "{", "ObjectMapper", "mapper", "=", "new", "ObjectMapper", "(", ")", ";", "Ma...
Convert CSV record(List<Strings>) to JsonObject using header(column Names) @param header record @param data record @param column Count @return JsonObject
[ "Convert", "CSV", "record", "(", "List<Strings", ">", ")", "to", "JsonObject", "using", "header", "(", "column", "Names", ")" ]
train
https://github.com/apache/incubator-gobblin/blob/f029b4c0fea0fe4aa62f36dda2512344ff708bae/gobblin-core/src/main/java/org/apache/gobblin/source/extractor/utils/Utils.java#L240-L250
Whiley/WhileyCompiler
src/main/java/wyc/io/WhileyFileParser.java
WhileyFileParser.parseLValTerm
private LVal parseLValTerm(int start, EnclosingScope scope) { """ Parse an lval term, which is of the form: <pre> TermLVal ::= Identifier // Variable assignment | '(' LVal ')' // Bracketed assignment </pre> @param scope The enclosing scope for this statement, which determines the ...
java
private LVal parseLValTerm(int start, EnclosingScope scope) { checkNotEof(); start = index; // First, attempt to disambiguate the easy forms: Token lookahead = tokens.get(index); switch (lookahead.kind) { case Identifier: Identifier name = parseIdentifier(); LVal var; if(scope.isVariable(name)) { ...
[ "private", "LVal", "parseLValTerm", "(", "int", "start", ",", "EnclosingScope", "scope", ")", "{", "checkNotEof", "(", ")", ";", "start", "=", "index", ";", "// First, attempt to disambiguate the easy forms:", "Token", "lookahead", "=", "tokens", ".", "get", "(", ...
Parse an lval term, which is of the form: <pre> TermLVal ::= Identifier // Variable assignment | '(' LVal ')' // Bracketed assignment </pre> @param scope The enclosing scope for this statement, which determines the set of visible (i.e. declared) variables and also the current indentation level....
[ "Parse", "an", "lval", "term", "which", "is", "of", "the", "form", ":" ]
train
https://github.com/Whiley/WhileyCompiler/blob/680f8a657d3fc286f8cc422755988b6d74ab3f4c/src/main/java/wyc/io/WhileyFileParser.java#L1526-L1556
aspectran/aspectran
core/src/main/java/com/aspectran/core/component/session/FileSessionDataStore.java
FileSessionDataStore.sweepFile
public void sweepFile(long now, Path p) throws Exception { """ Check to see if the expiry on the file is very old, and delete the file if so. "Old" means that it expired at least 5 gracePeriods ago. @param now the time now in msec @param p the file to check @throws Exception indicating error in sweep ""...
java
public void sweepFile(long now, Path p) throws Exception { if (p == null) { return; } long expiry = getExpiryFromFilename(p.getFileName().toString()); // files with 0 expiry never expire if (expiry > 0 && ((now - expiry) >= (5 * TimeUnit.SECONDS.toMillis(gracePe...
[ "public", "void", "sweepFile", "(", "long", "now", ",", "Path", "p", ")", "throws", "Exception", "{", "if", "(", "p", "==", "null", ")", "{", "return", ";", "}", "long", "expiry", "=", "getExpiryFromFilename", "(", "p", ".", "getFileName", "(", ")", ...
Check to see if the expiry on the file is very old, and delete the file if so. "Old" means that it expired at least 5 gracePeriods ago. @param now the time now in msec @param p the file to check @throws Exception indicating error in sweep
[ "Check", "to", "see", "if", "the", "expiry", "on", "the", "file", "is", "very", "old", "and", "delete", "the", "file", "if", "so", ".", "Old", "means", "that", "it", "expired", "at", "least", "5", "gracePeriods", "ago", "." ]
train
https://github.com/aspectran/aspectran/blob/2d758a2a28b71ee85b42823c12dc44674d7f2c70/core/src/main/java/com/aspectran/core/component/session/FileSessionDataStore.java#L315-L327
basho/riak-java-client
src/main/java/com/basho/riak/client/api/commands/kv/KvResponseBase.java
KvResponseBase.getValue
public <T> T getValue(Converter<T> converter, ConflictResolver<T> resolver) throws UnresolvedConflictException { """ Get a single, resolved object from this response. <p> The values will be converted to objects using the supplied {@link com.basho.riak.client.api.convert.Converter} rather than one registered wi...
java
public <T> T getValue(Converter<T> converter, ConflictResolver<T> resolver) throws UnresolvedConflictException { List<T> convertedValues = convertValues(converter); T resolved = resolver.resolve(convertedValues); if (hasValues() && resolved != null) { VClock vclock = val...
[ "public", "<", "T", ">", "T", "getValue", "(", "Converter", "<", "T", ">", "converter", ",", "ConflictResolver", "<", "T", ">", "resolver", ")", "throws", "UnresolvedConflictException", "{", "List", "<", "T", ">", "convertedValues", "=", "convertValues", "("...
Get a single, resolved object from this response. <p> The values will be converted to objects using the supplied {@link com.basho.riak.client.api.convert.Converter} rather than one registered with the {@link com.basho.riak.client.api.convert.ConverterFactory}. </p> <p>If there are multiple values present (siblings), th...
[ "Get", "a", "single", "resolved", "object", "from", "this", "response", ".", "<p", ">", "The", "values", "will", "be", "converted", "to", "objects", "using", "the", "supplied", "{" ]
train
https://github.com/basho/riak-java-client/blob/bed6cd60f360bacf1b873ab92dd74f2526651e71/src/main/java/com/basho/riak/client/api/commands/kv/KvResponseBase.java#L176-L188
BBN-E/bue-common-open
common-core-open/src/main/java/com/bbn/bue/common/collections/CollectionUtils.java
CollectionUtils.minOr
public static <T extends Comparable<T>> T minOr(Collection<T> values, T defaultVal) { """ Like {@link Collections#min(java.util.Collection)} except with a default value returned in the case of an empty collection. """ if (values.isEmpty()) { return defaultVal; } else { return Collections.m...
java
public static <T extends Comparable<T>> T minOr(Collection<T> values, T defaultVal) { if (values.isEmpty()) { return defaultVal; } else { return Collections.min(values); } }
[ "public", "static", "<", "T", "extends", "Comparable", "<", "T", ">", ">", "T", "minOr", "(", "Collection", "<", "T", ">", "values", ",", "T", "defaultVal", ")", "{", "if", "(", "values", ".", "isEmpty", "(", ")", ")", "{", "return", "defaultVal", ...
Like {@link Collections#min(java.util.Collection)} except with a default value returned in the case of an empty collection.
[ "Like", "{" ]
train
https://github.com/BBN-E/bue-common-open/blob/d618652674d647867306e2e4b987a21b7c29c015/common-core-open/src/main/java/com/bbn/bue/common/collections/CollectionUtils.java#L197-L203
ical4j/ical4j
src/main/java/net/fortuna/ical4j/transform/recurrence/AbstractDateExpansionRule.java
AbstractDateExpansionRule.getTime
protected static Date getTime(final Date referenceDate, final Calendar cal) { """ Get a DateTime from cal.getTime() with the timezone of the given reference date. @param referenceDate @param cal @return """ final Date zonedDate = new DateTime(referenceDate); zonedDate.setTime(cal.getTime()...
java
protected static Date getTime(final Date referenceDate, final Calendar cal) { final Date zonedDate = new DateTime(referenceDate); zonedDate.setTime(cal.getTime().getTime()); return zonedDate; }
[ "protected", "static", "Date", "getTime", "(", "final", "Date", "referenceDate", ",", "final", "Calendar", "cal", ")", "{", "final", "Date", "zonedDate", "=", "new", "DateTime", "(", "referenceDate", ")", ";", "zonedDate", ".", "setTime", "(", "cal", ".", ...
Get a DateTime from cal.getTime() with the timezone of the given reference date. @param referenceDate @param cal @return
[ "Get", "a", "DateTime", "from", "cal", ".", "getTime", "()", "with", "the", "timezone", "of", "the", "given", "reference", "date", "." ]
train
https://github.com/ical4j/ical4j/blob/7ac4bd1ce2bb2e0a2906fb69a56fbd2d9d974156/src/main/java/net/fortuna/ical4j/transform/recurrence/AbstractDateExpansionRule.java#L128-L132
konvergeio/cofoja
src/main/java/com/google/java/contract/core/agent/SpecificationMethodAdapter.java
SpecificationMethodAdapter.visitMaxs
@Override public void visitMaxs(int maxStack, int maxLocals) { """ Advises the method by injecting exceptional postconditions and invariants after the original code. This code only gets executed if an exception has been thrown (otherwise, a {@code return} instruction would have ended execution of the method a...
java
@Override public void visitMaxs(int maxStack, int maxLocals) { if (withPreconditions || withPostconditions || withInvariants) { mark(methodEnd); catchException(methodStart, methodEnd, null); if (withPostconditions) { Label skipEx = new Label(); dup(); instanceOf(EXCEPTIO...
[ "@", "Override", "public", "void", "visitMaxs", "(", "int", "maxStack", ",", "int", "maxLocals", ")", "{", "if", "(", "withPreconditions", "||", "withPostconditions", "||", "withInvariants", ")", "{", "mark", "(", "methodEnd", ")", ";", "catchException", "(", ...
Advises the method by injecting exceptional postconditions and invariants after the original code. This code only gets executed if an exception has been thrown (otherwise, a {@code return} instruction would have ended execution of the method already).
[ "Advises", "the", "method", "by", "injecting", "exceptional", "postconditions", "and", "invariants", "after", "the", "original", "code", ".", "This", "code", "only", "gets", "executed", "if", "an", "exception", "has", "been", "thrown", "(", "otherwise", "a", "...
train
https://github.com/konvergeio/cofoja/blob/6ded58fa05eb5bf85f16353c8dd4c70bee59121a/src/main/java/com/google/java/contract/core/agent/SpecificationMethodAdapter.java#L272-L309
OwlPlatform/java-owl-sensor
src/main/java/com/owlplatform/sensor/SensorAggregatorInterface.java
SensorAggregatorInterface.exceptionCaught
protected void exceptionCaught(IoSession session, Throwable cause) { """ Responds to exceptions and errors on the aggregator session. If {@code #disconnectOnException} is {@code true}, then disconnects from the aggregator. An OutOfMemory error will force a JVM exit. @param session the session that threw the ...
java
protected void exceptionCaught(IoSession session, Throwable cause) { log.error("Exception while communicating with " + this + ".", cause); // Nothing to do if we have no memory if (cause instanceof OutOfMemoryError) { System.exit(1); } if (this.disconnectOnException) { this._disconnect()...
[ "protected", "void", "exceptionCaught", "(", "IoSession", "session", ",", "Throwable", "cause", ")", "{", "log", ".", "error", "(", "\"Exception while communicating with \"", "+", "this", "+", "\".\"", ",", "cause", ")", ";", "// Nothing to do if we have no memory", ...
Responds to exceptions and errors on the aggregator session. If {@code #disconnectOnException} is {@code true}, then disconnects from the aggregator. An OutOfMemory error will force a JVM exit. @param session the session that threw the exception or error. @param cause the Throwable that was thrown.
[ "Responds", "to", "exceptions", "and", "errors", "on", "the", "aggregator", "session", ".", "If", "{", "@code", "#disconnectOnException", "}", "is", "{", "@code", "true", "}", "then", "disconnects", "from", "the", "aggregator", ".", "An", "OutOfMemory", "error...
train
https://github.com/OwlPlatform/java-owl-sensor/blob/7d98e985f2fc150dd696ca5683ad9ef6514be92b/src/main/java/com/owlplatform/sensor/SensorAggregatorInterface.java#L783-L792
Azure/azure-sdk-for-java
batch/data-plane/src/main/java/com/microsoft/azure/batch/JobScheduleOperations.java
JobScheduleOperations.updateJobSchedule
public void updateJobSchedule(String jobScheduleId, Schedule schedule, JobSpecification jobSpecification) throws BatchErrorException, IOException { """ Updates the specified job schedule. This method performs a full replace of all the updatable properties of the job schedule. For example, if the schedule paramete...
java
public void updateJobSchedule(String jobScheduleId, Schedule schedule, JobSpecification jobSpecification) throws BatchErrorException, IOException { updateJobSchedule(jobScheduleId, schedule, jobSpecification, null, null); }
[ "public", "void", "updateJobSchedule", "(", "String", "jobScheduleId", ",", "Schedule", "schedule", ",", "JobSpecification", "jobSpecification", ")", "throws", "BatchErrorException", ",", "IOException", "{", "updateJobSchedule", "(", "jobScheduleId", ",", "schedule", ",...
Updates the specified job schedule. This method performs a full replace of all the updatable properties of the job schedule. For example, if the schedule parameter is null, then the Batch service removes the job schedule’s existing schedule and replaces it with the default schedule. @param jobScheduleId The ID of the ...
[ "Updates", "the", "specified", "job", "schedule", ".", "This", "method", "performs", "a", "full", "replace", "of", "all", "the", "updatable", "properties", "of", "the", "job", "schedule", ".", "For", "example", "if", "the", "schedule", "parameter", "is", "nu...
train
https://github.com/Azure/azure-sdk-for-java/blob/aab183ddc6686c82ec10386d5a683d2691039626/batch/data-plane/src/main/java/com/microsoft/azure/batch/JobScheduleOperations.java#L231-L233
moparisthebest/beehive
beehive-netui-core/src/main/java/org/apache/beehive/netui/pageflow/PageFlowUtils.java
PageFlowUtils.getCurrentPageFlow
public static PageFlowController getCurrentPageFlow( HttpServletRequest request, ServletContext servletContext ) { """ Get the current {@link PageFlowController}. @param request the current HttpServletRequest. @param servletContext the current ServletContext. @return the current PageFlowController from the us...
java
public static PageFlowController getCurrentPageFlow( HttpServletRequest request, ServletContext servletContext ) { ActionResolver cur = getCurrentActionResolver( request, servletContext ); if (cur != null && cur.isPageFlow()) { PageFlowController pfc = (PageFlowController) cur; ...
[ "public", "static", "PageFlowController", "getCurrentPageFlow", "(", "HttpServletRequest", "request", ",", "ServletContext", "servletContext", ")", "{", "ActionResolver", "cur", "=", "getCurrentActionResolver", "(", "request", ",", "servletContext", ")", ";", "if", "(",...
Get the current {@link PageFlowController}. @param request the current HttpServletRequest. @param servletContext the current ServletContext. @return the current PageFlowController from the user session, or <code>null</code> if there is none.
[ "Get", "the", "current", "{", "@link", "PageFlowController", "}", "." ]
train
https://github.com/moparisthebest/beehive/blob/4246a0cc40ce3c05f1a02c2da2653ac622703d77/beehive-netui-core/src/main/java/org/apache/beehive/netui/pageflow/PageFlowUtils.java#L251-L262