name stringlengths 12 178 | code_snippet stringlengths 8 36.5k | score float64 3.26 3.68 |
|---|---|---|
streampipes_TerminatingBlocksFinder_startsWithNumber | /**
* Checks whether the given text t starts with a sequence of digits, followed by one of the given
* strings.
*
* @param t The text to examine
* @param len The length of the text to examine
* @param str Any strings that may follow the digits.
* @return true if at least one combination matches
*/
private stati... | 3.68 |
hadoop_PendingSet_getJobId | /** @return Job ID, if known. */
public String getJobId() {
return jobId;
} | 3.68 |
hbase_HFileCleaner_checkAndUpdateConfigurations | /**
* Check new configuration and update settings if value changed
* @param conf The new configuration
* @return true if any configuration for HFileCleaner changes, false if no change
*/
private boolean checkAndUpdateConfigurations(Configuration conf) {
boolean updated = false;
int throttlePoint =
conf.getI... | 3.68 |
flink_SqlLikeUtils_ilike | /** SQL {@code ILIKE} function with escape. */
public static boolean ilike(String s, String patternStr, String escape) {
final String regex = sqlToRegexLike(patternStr, escape);
Pattern pattern = Pattern.compile(regex, Pattern.CASE_INSENSITIVE);
Matcher matcher = pattern.matcher(s);
return matcher.match... | 3.68 |
morf_AbstractSqlDialectTest_testSimpleUpdate | /**
* Tests that a simple update with field literal works.
*/
@Test
public void testSimpleUpdate() {
UpdateStatement stmt = new UpdateStatement(new TableReference(TEST_TABLE)).set(new FieldLiteral("A1001001").as(STRING_FIELD));
String value = varCharCast("'A1001001'");
String expectedSql = "UPDATE " + tableName... | 3.68 |
AreaShop_FileManager_loadRegionFiles | /**
* Load all region files.
*/
public void loadRegionFiles() {
regions.clear();
final File file = new File(regionsPath);
if(!file.exists()) {
if(!file.mkdirs()) {
AreaShop.warn("Could not create region files directory: " + file.getAbsolutePath());
return;
}
plugin.setReady(true);
} else if(file.isDir... | 3.68 |
hadoop_ResourceUsage_getAMUsed | /*
* AM-Used
*/
public Resource getAMUsed() {
return getAMUsed(NL);
} | 3.68 |
flink_OpaqueMemoryResource_getSize | /** Gets the size, in bytes. */
public long getSize() {
return size;
} | 3.68 |
flink_JoinOperator_projectTuple11 | /**
* Projects a pair of joined elements to a {@link Tuple} with the previously selected
* fields. Requires the classes of the fields of the resulting tuples.
*
* @return The projected data set.
* @see Tuple
* @see DataSet
*/
public <T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>
ProjectJoin<I1, I2, Tuple1... | 3.68 |
hbase_Bytes_readAsVLong | /**
* Reads a zero-compressed encoded long from input buffer and returns it.
* @param buffer Binary array
* @param offset Offset into array at which vint begins.
* @return deserialized long from buffer.
*/
public static long readAsVLong(final byte[] buffer, final int offset) {
byte firstByte = buffer[offset];
... | 3.68 |
dubbo_PathUtil_resolvePathVariable | /**
* generate real path from rawPath according to argInfo and method args
*
* @param rawPath
* @param argInfos
* @param args
* @return
*/
public static String resolvePathVariable(String rawPath, List<ArgInfo> argInfos, List<Object> args) {
String[] split = rawPath.split(SEPARATOR);
List<String> strin... | 3.68 |
hbase_ReplicationSink_stopReplicationSinkServices | /**
* stop the thread pool executor. It is called when the regionserver is stopped.
*/
public void stopReplicationSinkServices() {
try {
if (this.sharedConn != null) {
synchronized (sharedConnLock) {
if (this.sharedConn != null) {
this.sharedConn.close();
this.sharedConn = null... | 3.68 |
morf_UpdateStatement_getTable | /**
* Gets the table being inserted into
*
* @return the table being inserted into
*/
public TableReference getTable() {
return table;
} | 3.68 |
hadoop_Nfs3Constant_fromValue | /**
* Convert to NFS procedure.
* @param value specify the index of NFS procedure
* @return the procedure corresponding to the value.
*/
public static NFSPROC3 fromValue(int value) {
if (value < 0 || value >= values().length) {
return null;
}
return values()[value];
} | 3.68 |
flink_CommonTestUtils_setEnv | // This code is taken slightly modified from: http://stackoverflow.com/a/7201825/568695
// it changes the environment variables of this JVM. Use only for testing purposes!
@SuppressWarnings("unchecked")
public static void setEnv(Map<String, String> newenv, boolean clearExisting) {
try {
Map<String, String> ... | 3.68 |
morf_UpdateStatement_shallowCopy | /**
* Performs a shallow copy to a builder, allowing a duplicate
* to be created and modified.
*
* @return A builder, initialised as a duplicate of this statement.
*/
@Override
public UpdateStatementBuilder shallowCopy() {
return new UpdateStatementBuilder(this);
} | 3.68 |
flink_DefaultRollingPolicy_getInactivityInterval | /**
* Returns time duration of allowed inactivity after which a part file will have to roll.
*
* @return Time duration in milliseconds
*/
public long getInactivityInterval() {
return inactivityInterval;
} | 3.68 |
flink_PekkoUtils_getAddressFromRpcURL | /**
* Extracts the {@link Address} from the given pekko URL.
*
* @param rpcURL to extract the {@link Address} from
* @throws MalformedURLException if the {@link Address} could not be parsed from the given pekko
* URL
* @return Extracted {@link Address} from the given rpc URL
*/
@SuppressWarnings("RedundantTh... | 3.68 |
dubbo_Environment_reset | /**
* Reset environment.
* For test only.
*/
public void reset() {
destroy();
initialize();
} | 3.68 |
hudi_SixToFiveDowngradeHandler_runCompaction | /**
* Utility method to run compaction for MOR table as part of downgrade step.
*/
private void runCompaction(HoodieTable table, HoodieEngineContext context, HoodieWriteConfig config,
SupportsUpgradeDowngrade upgradeDowngradeHelper) {
try {
if (table.getMetaClient().getTableType() == ... | 3.68 |
hbase_LruAdaptiveBlockCache_getStats | /**
* Get counter statistics for this cache.
* <p>
* Includes: total accesses, hits, misses, evicted blocks, and runs of the eviction processes.
*/
@Override
public CacheStats getStats() {
return this.stats;
} | 3.68 |
flink_ListStateDescriptor_getElementSerializer | /**
* Gets the serializer for the elements contained in the list.
*
* @return The serializer for the elements in the list.
*/
public TypeSerializer<T> getElementSerializer() {
// call getSerializer() here to get the initialization check and proper error message
final TypeSerializer<List<T>> rawSerializer = ... | 3.68 |
hadoop_ReadStatistics_getBlockType | /**
* @return block type of the input stream. If block type != CONTIGUOUS,
* it is reading erasure coded data.
*/
public synchronized BlockType getBlockType() {
return blockType;
} | 3.68 |
hbase_ByteBuff_read | // static helper methods
public static int read(ReadableByteChannel channel, ByteBuffer buf, long offset,
ChannelReader reader) throws IOException {
if (buf.remaining() <= NIO_BUFFER_LIMIT) {
return reader.read(channel, buf, offset);
}
int originalLimit = buf.limit();
int initialRemaining = buf.remaining(... | 3.68 |
pulsar_OwnershipCache_updateBundleState | /**
* Update bundle state in a local cache.
*
* @param bundle
* @throws Exception
*/
public CompletableFuture<Void> updateBundleState(NamespaceBundle bundle, boolean isActive) {
// Disable owned instance in local cache
CompletableFuture<OwnedBundle> f = ownedBundlesCache.getIfPresent(bundle);
if (f != ... | 3.68 |
graphhopper_NavigateResponseConverter_getThenVoiceInstructionpart | /**
* For close turns, it is important to announce the next turn in the earlier instruction.
* e.g.: instruction i+1= turn right, instruction i+2=turn left, with instruction i+1 distance < VOICE_INSTRUCTION_MERGE_TRESHHOLD
* The voice instruction should be like "turn right, then turn left"
* <p>
* For instruction ... | 3.68 |
pulsar_PulsarClientImpl_getConnection | /**
* Only for test.
*/
@VisibleForTesting
public CompletableFuture<ClientCnx> getConnection(final String topic) {
TopicName topicName = TopicName.get(topic);
return lookup.getBroker(topicName)
.thenCompose(pair -> getConnection(pair.getLeft(), pair.getRight(), cnxPool.genRandomKeyToSelectCon()));... | 3.68 |
flink_RemoteInputChannel_getAndResetUnannouncedCredit | /**
* Gets the unannounced credit and resets it to <tt>0</tt> atomically.
*
* @return Credit which was not announced to the sender yet.
*/
public int getAndResetUnannouncedCredit() {
return unannouncedCredit.getAndSet(0);
} | 3.68 |
framework_Page_showNotification | /**
* Shows a notification message.
*
* @see Notification
*
* @param notification
* The notification message to show
*
* @deprecated As of 7.0, use Notification.show(Page) instead.
*/
@Deprecated
public void showNotification(Notification notification) {
notification.show(this);
} | 3.68 |
hudi_HoodieFlinkWriteClient_getOrCreateWriteHandle | /**
* Get or create a new write handle in order to reuse the file handles.
*
* @param record The first record in the bucket
* @param config Write config
* @param instantTime The instant time
* @param table The table
* @param recordItr Record iterator
* @param overwrite Whether this is an ove... | 3.68 |
hadoop_AzureBlobFileSystem_setOwner | /**
* Set owner of a path (i.e. a file or a directory).
* The parameters owner and group cannot both be null.
*
* @param path The path
* @param owner If it is null, the original username remains unchanged.
* @param group If it is null, the original groupname remains unchanged.
*/
@Override
public void setOwner(... | 3.68 |
hadoop_StoreContext_createThrottledExecutor | /**
* Create a new executor with the capacity defined in
* {@link #executorCapacity}.
* @return a new executor for exclusive use by the caller.
*/
public ExecutorService createThrottledExecutor() {
return createThrottledExecutor(executorCapacity);
} | 3.68 |
framework_LayoutManager_getPaddingLeft | /**
* Gets the left padding of the given element, provided that it has been
* measured. These elements are guaranteed to be measured:
* <ul>
* <li>ManagedLayouts and their child Connectors
* <li>Elements for which there is at least one ElementResizeListener
* <li>Elements for which at least one ManagedLayout has ... | 3.68 |
flink_FactoryUtil_createCatalogStoreFactoryHelper | /**
* Creates a utility that helps validating options for a {@link CatalogStoreFactory}.
*
* <p>Note: This utility checks for left-over options in the final step.
*/
public static CatalogStoreFactoryHelper createCatalogStoreFactoryHelper(
CatalogStoreFactory factory, CatalogStoreFactory.Context context) {
... | 3.68 |
hbase_StorageClusterStatusModel_getMaxHeapSizeMB | /** Returns the maximum heap size, in MB */
@XmlAttribute
public int getMaxHeapSizeMB() {
return maxHeapSizeMB;
} | 3.68 |
MagicPlugin_SpellResult_isFailure | /**
* Determine if this result is a failure or not.
*
* <p>Note that a spell result can be neither failure nor
* success.
*
* @return True if this cast was a failure.
*/
public boolean isFailure() {
return failure;
} | 3.68 |
hadoop_AbstractManagedParentQueue_removeChildQueue | /**
* Remove the specified child queue.
* @param childQueueName name of the child queue to be removed
* @return child queue.
* @throws SchedulerDynamicEditException when removeChildQueue fails.
*/
public CSQueue removeChildQueue(String childQueueName)
throws SchedulerDynamicEditException {
CSQueue childQueue... | 3.68 |
hadoop_RequestFactoryImpl_getBucket | /**
* Get the target bucket.
* @return the bucket.
*/
protected String getBucket() {
return bucket;
} | 3.68 |
hbase_CatalogFamilyFormat_getServerNameColumn | /**
* Returns the column qualifier for serialized region state
* @param replicaId the replicaId of the region
* @return a byte[] for sn column qualifier
*/
public static byte[] getServerNameColumn(int replicaId) {
return replicaId == 0
? HConstants.SERVERNAME_QUALIFIER
: Bytes.toBytes(HConstants.SERVERNAM... | 3.68 |
framework_AbstractJavaScriptExtension_addFunction | /**
* Register a {@link JavaScriptFunction} that can be called from the
* JavaScript using the provided name. A JavaScript function with the
* provided name will be added to the connector wrapper object (initially
* available as <code>this</code>). Calling that JavaScript function will
* cause the call method in t... | 3.68 |
flink_MapView_entries | /**
* Returns all entries of the map view.
*
* @return An iterable of all the key-value pairs in the map view.
* @throws Exception Thrown if the system cannot access the map.
*/
public Iterable<Map.Entry<K, V>> entries() throws Exception {
return map.entrySet();
} | 3.68 |
framework_InMemoryDataProviderHelpers_propertyComparator | /**
* Creates a comparator for the return type of the given
* {@link ValueProvider}, sorted in the direction specified by the given
* {@link SortDirection}.
*
* @param valueProvider
* the value provider to use
* @param sortDirection
* the sort direction to use
* @return the created compar... | 3.68 |
hadoop_YarnRegistryViewForProviders_deleteChildren | /**
* Delete the children of a path -but not the path itself.
* It is not an error if the path does not exist
* @param path path to delete
* @param recursive flag to request recursive deletes
* @throws IOException IO problems
*/
public void deleteChildren(String path, boolean recursive) throws IOException {
Lis... | 3.68 |
framework_UIDL_getFloatVariable | /**
* Gets the value of the named variable.
*
* @param name
* the name of the variable
* @return the value of the variable
*/
public float getFloatVariable(String name) {
return (float) var().getRawNumber(name);
} | 3.68 |
framework_UIConnector_scrollIntoView | /**
* Tries to scroll the viewport so that the given connector is in view.
*
* @param componentConnector
* The connector which should be visible
*
*/
public void scrollIntoView(final ComponentConnector componentConnector) {
if (componentConnector == null) {
return;
}
Scheduler.get(... | 3.68 |
querydsl_BeanPath_createSet | /**
* Create a new Set typed path
*
* @param <A>
* @param property property name
* @param type property type
* @return property path
*/
@SuppressWarnings("unchecked")
protected <A, E extends SimpleExpression<? super A>> SetPath<A, E> createSet(String property, Class<? super A> type, Class<? super E> queryType, P... | 3.68 |
morf_UpdateStatement_getWhereCriterion | /**
* Gets the where criteria.
*
* @return the where criteria
*/
public Criterion getWhereCriterion() {
return whereCriterion;
} | 3.68 |
hbase_StorageClusterStatusModel_getRegion | /**
* @param index the index
* @return the region name
*/
public Region getRegion(int index) {
return regions.get(index);
} | 3.68 |
hadoop_RemoteEditLogManifest_checkState | /**
* Check that the logs are non-overlapping sequences of transactions,
* in sorted order. They do not need to be contiguous.
* @throws IllegalStateException if incorrect
*/
private void checkState() {
Preconditions.checkNotNull(logs);
RemoteEditLog prev = null;
for (RemoteEditLog log : logs) {
if (pre... | 3.68 |
flink_MurmurHashUtil_fmix | // Finalization mix - force all bits of a hash block to avalanche
private static int fmix(int h1, int length) {
h1 ^= length;
return fmix(h1);
} | 3.68 |
hadoop_StringValueMin_getReport | /**
* @return the string representation of the aggregated value
*/
public String getReport() {
return minVal;
} | 3.68 |
hbase_HealthReport_getHealthReport | /**
* Gets the health report of the region server.
*/
String getHealthReport() {
return healthReport;
} | 3.68 |
dubbo_MetadataParamsFilter_instanceParamsExcluded | /**
* params that need to be excluded before sending to registry center
*
* @return arrays of keys
*/
default String[] instanceParamsExcluded() {
return new String[0];
} | 3.68 |
hbase_RestoreTool_getTableInfoPath | /**
* Returns value represent path for:
* ""/$USER/SBACKUP_ROOT/backup_id/namespace/table/.hbase-snapshot/
* snapshot_1396650097621_namespace_table" this path contains .snapshotinfo, .tabledesc (0.96 and
* 0.98) this path contains .snapshotinfo, .data.manifest (trunk)
* @param tableName table name
* @return path ... | 3.68 |
framework_VCustomLayout_initImgElements | /**
* Img elements needs some special handling in custom layout. Img elements
* will get their onload events sunk. This way custom layout can notify
* parent about possible size change.
*/
private void initImgElements() {
NodeList<Element> nodeList = getElement().getElementsByTagName("IMG");
for (int i = 0;... | 3.68 |
flink_GenericDataSinkBase_getFormatWrapper | /**
* Gets the class describing this sinks output format.
*
* @return The output format class.
*/
public UserCodeWrapper<? extends OutputFormat<IN>> getFormatWrapper() {
return this.formatWrapper;
} | 3.68 |
hibernate-validator_TokenIterator_nextInterpolationTerm | /**
* @return Returns the next interpolation term
*/
public String nextInterpolationTerm() {
if ( !currentTokenAvailable ) {
throw new IllegalStateException(
"Trying to call #nextInterpolationTerm without calling #hasMoreInterpolationTerms"
);
}
currentTokenAvailable = false;
return currentToken.getTokenV... | 3.68 |
hmily_NetUtils_getLocalIp | /**
* Gets local ip.
*
* @return the local ip
*/
public static String getLocalIp() {
if (localAddress == null) {
synchronized (NetUtils.class) {
if (localAddress == null) {
try {
localAddress = InetAddress.getLocalHost().getHostAddress();
}... | 3.68 |
flink_OutputFormatBase_writeRecord | /**
* Asynchronously write a record and deal with {@link OutputFormatBase#maxConcurrentRequests}.
* To specify how a record is written, please override the {@link OutputFormatBase#send(Object)}
* method.
*/
@Override
public final void writeRecord(OUT record) throws IOException {
checkAsyncErrors();
tryAcqui... | 3.68 |
hbase_RegionPlan_getDestination | /**
* Get the destination server for the plan for this region.
* @return server info for destination
*/
public ServerName getDestination() {
return dest;
} | 3.68 |
graphhopper_RestrictionConverter_convert | /**
* OSM restriction relations specify turn restrictions between OSM ways (of course). This method converts such a
* relation into a 'graph' representation, where the turn restrictions are specified in terms of edge/node IDs instead
* of OSM IDs.
*
* @throws OSMRestrictionException if the given relation is either... | 3.68 |
streampipes_StreamRequirementsBuilder_requiredPropertyWithUnaryMapping | /**
* Sets a new property requirement and, in addition, adds a
* {@link org.apache.streampipes.model.staticproperty.MappingPropertyUnary} static property to the pipeline element
* definition.
*
* @param propertyRequirement The property requirement.
* Use {@link org.apache.streampipes.sd... | 3.68 |
hbase_CleanerChore_shouldExclude | /**
* Check if a path should not perform clear
*/
private boolean shouldExclude(FileStatus f) {
if (!f.isDirectory()) {
return false;
}
if (excludeDirs != null && !excludeDirs.isEmpty()) {
for (String dirPart : excludeDirs) {
// since we make excludeDirs end with '/',
// if a path contains()... | 3.68 |
hadoop_ReadStatistics_getTotalZeroCopyBytesRead | /**
* @return The total number of zero-copy bytes read.
*/
public synchronized long getTotalZeroCopyBytesRead() {
return totalZeroCopyBytesRead;
} | 3.68 |
framework_VaadinSession_getConverterFactory | /**
* Gets the {@code ConverterFactory} used to locate a suitable
* {@code Converter} for fields in the session.
* <p>
* Note that the this and {@link #setConverterFactory(Object))} use Object
* and not {@code ConverterFactory} in Vaadin 8 to avoid a core dependency
* on the compatibility packages.
*
* @return ... | 3.68 |
hadoop_AuthenticationHandlerUtil_matchAuthScheme | /**
* This method checks if the specified <code>authToken</code> belongs to the
* specified HTTP authentication <code>scheme</code>.
*
* @param scheme HTTP authentication scheme to be checked
* @param auth Authentication header value which is to be compared with the
* authentication scheme.
* @return tr... | 3.68 |
hbase_Result_getFamilyMap | /**
* Map of qualifiers to values.
* <p>
* Returns a Map of the form: <code>Map<qualifier,value></code>
* @param family column family to get
* @return map of qualifiers to values
*/
public NavigableMap<byte[], byte[]> getFamilyMap(byte[] family) {
if (this.familyMap == null) {
getMap();
}
if (isEm... | 3.68 |
hudi_HoodieInputFormatUtils_getTableMetaClientForBasePathUnchecked | /**
* Extract HoodieTableMetaClient from a partition path (not base path)
*/
public static HoodieTableMetaClient getTableMetaClientForBasePathUnchecked(Configuration conf, Path partitionPath) throws IOException {
Path baseDir = partitionPath;
FileSystem fs = partitionPath.getFileSystem(conf);
if (HoodiePartitio... | 3.68 |
pulsar_NarClassLoader_getServiceDefinition | /**
* Read a service definition as a String.
*/
public String getServiceDefinition(String serviceName) throws IOException {
String serviceDefPath = narWorkingDirectory + "/META-INF/services/" + serviceName;
return new String(Files.readAllBytes(Paths.get(serviceDefPath)), StandardCharsets.UTF_8);
} | 3.68 |
framework_VScrollTable_setFooterCell | /**
* Set a footer cell for a specified column index.
*
* @param index
* The index
* @param cell
* The footer cell
*/
public void setFooterCell(int index, FooterCell cell) {
if (cell.isEnabled()) {
// we're moving the cell
DOM.removeChild(tr, cell.getElement());
... | 3.68 |
framework_VTabsheetBase_setReadonly | /**
* For internal use only. May be removed or replaced in the future.
*
* @param readonly
* {@code true} if this widget should be read-only, {@code false}
* otherwise
*/
public void setReadonly(boolean readonly) {
this.readonly = readonly;
} | 3.68 |
hadoop_TimedHealthReporterService_serviceStop | /**
* Method used to terminate the health monitoring service.
*/
@Override
protected void serviceStop() throws Exception {
if (timer != null) {
timer.cancel();
}
super.serviceStop();
} | 3.68 |
hudi_CleanPlanActionExecutor_requestClean | /**
* Creates a Cleaner plan if there are files to be cleaned and stores them in instant file.
* Cleaner Plan contains absolute file paths.
*
* @param startCleanTime Cleaner Instant Time
* @return Cleaner Plan if generated
*/
protected Option<HoodieCleanerPlan> requestClean(String startCleanTime) {
final Hoodie... | 3.68 |
aws-saas-boost_RefreshingProfileDefaultCredentialsProvider_resolveCredentials | /**
* @see AwsCredentialsProvider#resolveCredentials()
*/
@Override
public AwsCredentials resolveCredentials() {
if (profileFilename == null) {
return curriedBuilder.build().resolveCredentials();
}
curriedBuilder.profileFile(ProfileFile.builder()
.type(ProfileFile.Type.CREDENTIALS)
... | 3.68 |
hbase_BackupInfo_getProgress | /**
* Get current progress
*/
public int getProgress() {
return progress;
} | 3.68 |
hadoop_S3AReadOpContext_getPrefetchBlockSize | /**
* Gets the size in bytes of a single prefetch block.
*
* @return the size in bytes of a single prefetch block.
*/
public int getPrefetchBlockSize() {
return this.prefetchBlockSize;
} | 3.68 |
framework_VCalendarPanel_onChange | /*
* (non-Javadoc) VT
*
* @see
* com.google.gwt.event.dom.client.ChangeHandler#onChange(com.google.gwt
* .event.dom.client.ChangeEvent)
*/
@Override
public void onChange(ChangeEvent event) {
/*
* Value from dropdowns gets always set for the value. Like year and
* month when resolution is month or ye... | 3.68 |
flink_StreamRecord_replace | /**
* Replace the currently stored value by the given new value and the currently stored timestamp
* with the new timestamp. This returns a StreamElement with the generic type parameter that
* matches the new value.
*
* @param value The new value to wrap in this StreamRecord
* @param timestamp The new timestamp i... | 3.68 |
hudi_FlinkMergeHandle_newFileNameWithRollover | /**
* Use the writeToken + "-" + rollNumber as the new writeToken of a mini-batch write.
*/
protected String newFileNameWithRollover(int rollNumber) {
return FSUtils.makeBaseFileName(instantTime, writeToken + "-" + rollNumber,
this.fileId, hoodieTable.getBaseFileExtension());
} | 3.68 |
framework_AbstractMultiSelect_setValue | /**
* Sets the value of this object which is a set of items to select. If the
* new value is not equal to {@code getValue()}, fires a value change event.
* May throw {@code IllegalArgumentException} if the value is not
* acceptable.
* <p>
* The method effectively selects the given items and deselects previously
... | 3.68 |
zxing_IntentResult_getContents | /**
* @return raw content of barcode
*/
public String getContents() {
return contents;
} | 3.68 |
flink_ConnectedStreams_keyBy | /**
* KeyBy operation for connected data stream. Assigns keys to the elements of input1 and input2
* using keySelector1 and keySelector2 with explicit type information for the common key type.
*
* @param keySelector1 The {@link KeySelector} used for grouping the first input
* @param keySelector2 The {@link KeySele... | 3.68 |
framework_FieldGroup_removeCommitHandler | /**
* Removes the given commit handler.
*
* @see #addCommitHandler(CommitHandler)
*
* @param commitHandler
* The commit handler to remove
*/
public void removeCommitHandler(CommitHandler commitHandler) {
commitHandlers.remove(commitHandler);
} | 3.68 |
flink_DeltaIterationBase_setSolutionSetDelta | /**
* Sets the contract of the step function that represents the solution set delta. This contract
* is considered one of the two sinks of the step function (the other one being the next
* workset).
*
* @param delta The contract representing the solution set delta.
*/
public void setSolutionSetDelta(Operator delt... | 3.68 |
flink_FileStateHandle_discardState | /**
* Discard the state by deleting the file that stores the state. If the parent directory of the
* state is empty after deleting the state file, it is also deleted.
*
* @throws Exception Thrown, if the file deletion (not the directory deletion) fails.
*/
@Override
public void discardState() throws Exception {
... | 3.68 |
hadoop_MawoConfiguration_getZKSessionTimeoutMS | /**
* Get ZooKeeper session timeout in milli seconds.
* @return value of ZooKeeper.session.timeout.ms
*/
public int getZKSessionTimeoutMS() {
return Integer.parseInt(configsMap.get(ZK_SESSION_TIMEOUT_MS));
} | 3.68 |
flink_CoGroupedStreams_window | /** Specifies the window on which the co-group operation works. */
@PublicEvolving
public <W extends Window> WithWindow<T1, T2, KEY, W> window(
WindowAssigner<? super TaggedUnion<T1, T2>, W> assigner) {
return new WithWindow<>(
input1,
input2,
keySelector1,
ke... | 3.68 |
hbase_Permission_implies | /**
* check if given action is granted
* @param action action to be checked
* @return true if granted, false otherwise
*/
public boolean implies(Action action) {
return actions.contains(action);
} | 3.68 |
framework_DataCommunicator_getDataProviderSize | /**
* Getter method for finding the size of DataProvider. Can be overridden by
* a subclass that uses a specific type of DataProvider and/or query.
*
* @return the size of data provider with current filter
*/
@SuppressWarnings({ "unchecked", "rawtypes" })
public int getDataProviderSize() {
return getDataProvid... | 3.68 |
flink_SingleInputNode_setIncomingConnection | /**
* Sets the connection through which this node receives its input.
*
* @param inConn The input connection to set.
*/
public void setIncomingConnection(DagConnection inConn) {
this.inConn = inConn;
} | 3.68 |
rocketmq-connect_AbstractConfigManagementService_processDeleteConnectorRecord | /**
* process deleted
*
* @param connectorName
* @param schemaAndValue
*/
private void processDeleteConnectorRecord(String connectorName, SchemaAndValue schemaAndValue) {
if (!connectorKeyValueStore.containsKey(connectorName)) {
return;
}
Struct value = (Struct) schemaAndValue.value();
Obje... | 3.68 |
pulsar_BaseContext_getPulsarClient | /**
* Get the pre-configured pulsar client.
*
* You can use this client to access Pulsar cluster.
* The Function will be responsible for disposing this client.
*
* @return the instance of pulsar client
*/
default PulsarClient getPulsarClient() {
throw new UnsupportedOperationException("not implemented");
} | 3.68 |
graphhopper_State_getOutgoingVirtualEdge | /**
* Returns the virtual edge that should be used by outgoing paths.
*
* @throws IllegalStateException if this State is not directed.
*/
public EdgeIteratorState getOutgoingVirtualEdge() {
if (!isDirected) {
throw new IllegalStateException(
"This method may only be called for directed G... | 3.68 |
flink_ExecutionEnvironment_readCsvFile | /**
* Creates a CSV reader to read a comma separated value (CSV) file. The reader has options to
* define parameters and field types and will eventually produce the DataSet that corresponds to
* the read and parsed CSV input.
*
* @param filePath The path of the CSV file.
* @return A CsvReader that can be used to ... | 3.68 |
hadoop_StoragePolicySatisfyManager_clearPathIds | /**
* Removes the SPS path id from the list of sps paths.
*
* @throws IOException
*/
private void clearPathIds(){
synchronized (pathsToBeTraversed) {
Iterator<Long> iterator = pathsToBeTraversed.iterator();
while (iterator.hasNext()) {
Long trackId = iterator.next();
try {
namesystem.r... | 3.68 |
querydsl_Expressions_stringTemplate | /**
* Create a new Template expression
*
* @param template template
* @param args template parameters
* @return template expression
*/
public static StringTemplate stringTemplate(Template template, List<?> args) {
return new StringTemplate(template, args);
} | 3.68 |
hadoop_FileIoProvider_listFiles | /**
* Get a listing of the given directory using
* {@link FileUtil#listFiles(File)}.
*
* @param volume target volume. null if unavailable.
* @param dir Directory to be listed.
* @return array of file objects representing the directory entries.
* @throws IOException
*/
public File[] listFiles(
@Nullable F... | 3.68 |
hudi_HoodieCombineHiveInputFormat_getNumPaths | /**
* Returns the number of Paths in the split.
*/
@Override
public int getNumPaths() {
return inputSplitShim.getNumPaths();
} | 3.68 |
framework_FocusableComplexPanel_addFocusHandler | /*
* (non-Javadoc)
*
* @see
* com.google.gwt.event.dom.client.HasFocusHandlers#addFocusHandler(com.
* google.gwt.event.dom.client.FocusHandler)
*/
@Override
public HandlerRegistration addFocusHandler(FocusHandler handler) {
return addDomHandler(handler, FocusEvent.getType());
} | 3.68 |
hmily_PropertyKey_isAvailable | /**
* Is available boolean.
*
* @param name the name
* @return the boolean
*/
public boolean isAvailable(final PropertyName name) {
return propertyName.equals(name);
} | 3.68 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.