name
stringlengths
12
178
code_snippet
stringlengths
8
36.5k
score
float64
3.26
3.68
framework_VTooltip_getFinalTouchX
/** * Return the final X-coordinate of the tooltip based on cursor * position, size of the tooltip, size of the page and necessary * margins. * * @param offsetWidth * @return The final X-coordinate */ private int getFinalTouchX(int offsetWidth) { int x = 0; int widthNeeded = 10 + offsetWidth; int roo...
3.68
flink_CrossOperator_projectTuple19
/** * Projects a pair of crossed elements to a {@link Tuple} with the previously selected * fields. * * @return The projected data set. * @see Tuple * @see DataSet */ public <T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16, T17, T18> ProjectCross< I1, ...
3.68
framework_ListSelectElement_getValue
/** * Return value of the list select element. * * @return value of the list select element */ public String getValue() { return select.getFirstSelectedOption().getText(); }
3.68
zxing_CameraManager_openDriver
/** * Opens the camera driver and initializes the hardware parameters. * * @param holder The surface object which the camera will draw preview frames into. * @throws IOException Indicates the camera driver failed to open. */ public synchronized void openDriver(SurfaceHolder holder) throws IOException { OpenCamer...
3.68
hudi_TableCommand_descTable
/** * Describes table properties. */ @ShellMethod(key = "desc", value = "Describe Hoodie Table properties") public String descTable() { HoodieTableMetaClient client = HoodieCLI.getTableMetaClient(); TableHeader header = new TableHeader().addTableHeaderField("Property").addTableHeaderField("Value"); List<Compara...
3.68
hadoop_GangliaConf_getDmax
/** * @return the dmax */ int getDmax() { return dmax; }
3.68
flink_ApiSpecGeneratorUtils_findAdditionalFieldType
/** * Find whether the class contains dynamic fields that need to be documented. * * @param clazz class to check * @return optional that is non-empty if the class is annotated with {@link * FlinkJsonSchema.AdditionalFields} */ public static Optional<Class<?>> findAdditionalFieldType(Class<?> clazz) { fina...
3.68
hmily_EtcdClient_getInstance
/** * get instance of EtcdClient. * * @param config etcdConfig * @return etcd Client */ public static EtcdClient getInstance(final EtcdConfig config) { Client client = Client.builder().endpoints(config.getServer()).build(); EtcdClient etcdClient = new EtcdClient(); etcdClient.setClient(client); ret...
3.68
hadoop_AzureNativeFileSystemStore_getDirectorySet
/** * Take a comma-separated list of directories from a configuration variable * and transform it to a set of directories. */ private Set<String> getDirectorySet(final String configVar) throws AzureException { String[] rawDirs = sessionConfiguration.getStrings(configVar, new String[0]); Set<String> directory...
3.68
flink_MapView_contains
/** * Checks if the map view contains a value for a given key. * * @param key The key to check. * @return True if there exists a value for the given key, false otherwise. * @throws Exception Thrown if the system cannot access the map. */ public boolean contains(K key) throws Exception { return map.containsKey...
3.68
hudi_LazyIterableIterator_end
/** * Called once, after all elements are processed. */ protected void end() {}
3.68
hadoop_SelectEventStreamPublisher_response
/** * The response from the SelectObjectContent call. * @return the response object */ public SelectObjectContentResponse response() { return response; }
3.68
zxing_PDF417ScanningDecoder_createDecoderResultFromAmbiguousValues
/** * This method deals with the fact, that the decoding process doesn't always yield a single most likely value. The * current error correction implementation doesn't deal with erasures very well, so it's better to provide a value * for these ambiguous codewords instead of treating it as an erasure. The problem is ...
3.68
hudi_HoodieRowDataCreation_create
/** * Creates a {@link AbstractHoodieRowData} instance based on the given configuration. */ public static AbstractHoodieRowData create( String commitTime, String commitSeqNumber, String recordKey, String partitionPath, String fileName, RowData row, boolean withOperation, boolean withMe...
3.68
flink_Execution_setInitialState
/** * Sets the initial state for the execution. The serialized state is then shipped via the {@link * TaskDeploymentDescriptor} to the TaskManagers. * * @param taskRestore information to restore the state */ public void setInitialState(JobManagerTaskRestore taskRestore) { this.taskRestore = taskRestore; }
3.68
flink_ResolvedSchema_getColumns
/** Returns all {@link Column}s of this schema. */ public List<Column> getColumns() { return columns; }
3.68
hbase_WALSplitUtil_archive
/** * Moves processed logs to a oldLogDir after successful processing Moves corrupted logs (any log * that couldn't be successfully parsed to corruptDir (.corrupt) for later investigation */ static void archive(final Path wal, final boolean corrupt, final Path oldWALDir, final FileSystem walFS, final Configuration...
3.68
flink_CopyOnWriteSkipListStateMap_doPhysicalRemove
/** * Removes the node physically, and free all space used by the key and value. * * @param node node to remove. * @param prevNode previous node at the level 0. * @param nextNode next node at the level 0. */ private void doPhysicalRemove(long node, long prevNode, long nextNode) { // free space used by key and...
3.68
flink_DataStream_getExecutionEnvironment
/** * Returns the {@link StreamExecutionEnvironment} that was used to create this {@link * DataStream}. * * @return The Execution Environment */ public StreamExecutionEnvironment getExecutionEnvironment() { return environment; }
3.68
hbase_BackupAdminImpl_cleanupBackupDir
/** * Clean up the data at target directory * @throws IOException if cleaning up the backup directory fails */ private void cleanupBackupDir(BackupInfo backupInfo, TableName table, Configuration conf) throws IOException { try { // clean up the data at target directory String targetDir = backupInfo.getBac...
3.68
pulsar_SchemasImpl_convertSchemaDataToStringLegacy
// the util function exists for backward compatibility concern static String convertSchemaDataToStringLegacy(SchemaInfo schemaInfo) throws IOException { byte[] schemaData = schemaInfo.getSchema(); if (null == schemaInfo.getSchema()) { return ""; } if (schemaInfo.getType() == SchemaType.KEY_VALU...
3.68
dubbo_AbstractConfig_convert
/** * @param parameters the raw parameters * @param prefix the prefix * @return the parameters whose raw key will replace "-" to "." * @revised 2.7.8 "private" to be "protected" */ protected static Map<String, String> convert(Map<String, String> parameters, String prefix) { if (parameters == null || parame...
3.68
flink_PekkoUtils_getRemoteConfig
/** * Creates a Pekko config for a remote actor system listening on port on the network interface * identified by bindAddress. * * @param configuration instance containing the user provided configuration values * @param bindAddress of the network interface to bind on * @param port to bind to or if 0 then Pekko pi...
3.68
open-banking-gateway_DatasafeConfigurer_psuDatasafeServices
/** * PSU/FinTech user Datasafe storage. * @param psuReadStorePass Datasafe password to open keystore. * @param serde Serialization/Deserialization handler * @return PSU/FinTech user Datasafe storage */ @Bean public PsuSecureStorage psuDatasafeServices( @Value(ENCRYPTION_DATASAFE_READ_KEYSTORE_PREFIX + ".p...
3.68
hbase_AccessController_checkForReservedTagPresence
// Checks whether incoming cells contain any tag with type as ACL_TAG_TYPE. This tag // type is reserved and should not be explicitly set by user. private void checkForReservedTagPresence(User user, Mutation m) throws IOException { // No need to check if we're not going to throw if (!authorizationEnabled) { m.s...
3.68
hmily_HmilyConsistentHashLoadBalance_refresh
/** * Refresh local invoker. * * @param invokers invokers */ @Override public void refresh(final Collection<Invoker<T>> invokers) { LOGGER.info(config.getSimpleObjectName() + " try to refresh ConsistentHashLoadBalance's invoker cache, size=" + (invokers == null || invokers.isEmpty() ? 0 : invokers.size())); ...
3.68
graphhopper_GraphHopper_close
/** * Releases all associated resources like memory or files. But it does not remove them. To * remove the files created in graphhopperLocation you have to call clean(). */ public void close() { if (baseGraph != null) baseGraph.close(); if (properties != null) properties.close(); chGraph...
3.68
graphhopper_VectorTile_setFeatures
/** * <pre> * The actual features in this tile. * </pre> * * <code>repeated .vector_tile.Tile.Feature features = 2;</code> */ public Builder setFeatures( int index, vector_tile.VectorTile.Tile.Feature.Builder builderForValue) { if (featuresBuilder_ == null) { ensureFeaturesIsMutable(); features_.set...
3.68
hadoop_AbfsConfiguration_getEnum
/** * Returns the account-specific enum value if it exists, then * looks for an account-agnostic value. * @param name Account-agnostic configuration key * @param defaultValue Value returned if none is configured * @param <T> Enum type * @return enum value if one exists, else null */ public <T extends Enum<T>> T ...
3.68
open-banking-gateway_FintechUserAuthSessionTuple_toDatasafePathWithoutParent
/** * Computes current tuples' Datasafe storage path. * @return Datasafe path corresponding to current tuple */ public String toDatasafePathWithoutParent() { return this.authSessionId.toString(); }
3.68
framework_VAbstractCalendarPanel_onTabOut
/** * True should be returned if the panel will not be used after this event. * * @param event * dom event * @return {@code true} if the panel will not be used after this event, * {@code false} otherwise */ protected boolean onTabOut(DomEvent<?> event) { if (focusOutListener != null) { ...
3.68
hbase_HRegion_replayWALEntry
/** * Replay remote wal entry sent by primary replica. * <p/> * Should only call this method on secondary replicas. */ void replayWALEntry(WALEntry entry, CellScanner cells) throws IOException { long timeout = -1L; Optional<RpcCall> call = RpcServer.getCurrentCall(); if (call.isPresent()) { long deadline ...
3.68
hbase_HFileLink_getReferencedRegionName
/** * Get the Region name of the referenced link * @param fileName HFileLink file name * @return the name of the referenced Region */ public static String getReferencedRegionName(final String fileName) { Matcher m = REF_OR_HFILE_LINK_PATTERN.matcher(fileName); if (!m.matches()) { throw new IllegalArgumentEx...
3.68
hadoop_AMRMTokenSecretManager_getMasterKey
// If nextMasterKey is not Null, then return nextMasterKey // otherwise return currentMasterKey @VisibleForTesting public MasterKeyData getMasterKey() { this.readLock.lock(); try { return nextMasterKey == null ? currentMasterKey : nextMasterKey; } finally { this.readLock.unlock(); } }
3.68
morf_AbstractSqlDialectTest_verifyPostInsertStatementsInsertingUnderAutonumLimit
/** * Verify on the expected SQL statements to be run after insert for the test database table. * @param sqlScriptExecutor The script executor to use * @param connection The connection to use */ @SuppressWarnings("unused") protected void verifyPostInsertStatementsInsertingUnderAutonumLimit(SqlScriptExecutor sqlScri...
3.68
graphhopper_LocationIndex_query
/** * This method explores the LocationIndex with the specified Visitor. It visits only the stored edges (and only once) * and limited by the queryBBox. Also (a few) more edges slightly outside of queryBBox could be * returned that you can avoid via doing an explicit BBox check of the coordinates. */ default void q...
3.68
hbase_HFileWriterImpl_newBlock
/** * Ready a new block for writing. */ protected void newBlock() throws IOException { // This is where the next block begins. blockWriter.startWriting(BlockType.DATA); firstCellInBlock = null; if (lastCell != null) { lastCellOfPreviousBlock = lastCell; } }
3.68
rocketmq-connect_Serdes_Short
/** * A serde for nullable {@code Short} type. */ static public Serde<Short> Short() { return new ShortSerde(); }
3.68
querydsl_StringExpression_concat
/** * Create a {@code concat(this, str)} expression * * <p>Get the concatenation of this and str</p> * * @param str string to append * @return this + str */ public StringExpression concat(String str) { return append(str); }
3.68
flink_ChangelogKeyedStateBackend_initMaterialization
/** * Initialize state materialization so that materialized data can be persisted durably and * included into the checkpoint. * * <p>This method is not thread safe. It should be called either under a lock or through task * mailbox executor. * * @return a tuple of - future snapshot result from the underlying stat...
3.68
morf_SchemaUtils_toUpperCase
/** * Convert all the strings in a list to upper case. * * @param listOfStrings A list of strings * @return A new list of strings, with each string converted to upper case */ public static List<String> toUpperCase(List<String> listOfStrings) { return listOfStrings.stream().map(String::toUpperCase).collect(Collec...
3.68
framework_FlyweightCell_setColSpan
/** * Set the colspan attribute for the element of the cell. * * @param numberOfCells * spanned cell count, must be at least 1 */ public void setColSpan(final int numberOfCells) { if (numberOfCells < 1) { throw new IllegalArgumentException( "Number of cells should be more tha...
3.68
hbase_DoubleArrayCost_applyCostsChange
/** * We do not want to introduce a getCosts method to let upper layer get the cost array directly, * so here we introduce this method to take a {@link Consumer} as parameter, where we will pass * the actual cost array in, so you can change the element of the cost array in the * {@link Consumer} implementation. * ...
3.68
hudi_HoodieRecordPayload_getMetadata
/** * This method can be used to extract some metadata from HoodieRecordPayload. The metadata is passed to {@code WriteStatus.markSuccess()} and * {@code WriteStatus.markFailure()} in order to compute some aggregate metrics using the metadata in the context of a write success or failure. * @return the metadata in th...
3.68
dubbo_NacosRegistry_notifySubscriber
/** * Notify the Enabled {@link Instance instances} to subscriber. * * @param url {@link URL} * @param listener {@link NotifyListener} * @param instances all {@link Instance instances} */ private void notifySubscriber( URL url, String serviceName, NacosAggregateListener listener, Collection<Instanc...
3.68
zilla_ManyToOneRingBuffer_consumerPosition
/** * {@inheritDoc} */ public long consumerPosition() { return buffer.getLongVolatile(headPositionIndex); }
3.68
flink_FileSystemCheckpointStorage_getCheckpointPath
/** * Gets the base directory where all the checkpoints are stored. The job-specific checkpoint * directory is created inside this directory. * * @return The base directory for checkpoints. */ @Nonnull public Path getCheckpointPath() { // we know that this can never be null by the way of constructor checks ...
3.68
flink_LongMaximum_add
/** Consider using {@link #add(long)} instead for primitive long values */ @Override public void add(Long value) { this.max = Math.max(this.max, value); }
3.68
flink_RocksDBProperty_getConfigKey
/** * @return key for enabling metric using {@link org.apache.flink.configuration.Configuration}. */ public String getConfigKey() { return String.format(CONFIG_KEY_FORMAT, property); }
3.68
framework_ColorPickerTestUI_getStream
/* Must implement this method that returns the resource as a stream. */ @Override public InputStream getStream() { /* Create an image and draw something on it. */ BufferedImage image = new BufferedImage(270, 270, BufferedImage.TYPE_INT_RGB); Graphics drawable = image.getGraphics(); drawable...
3.68
hbase_KeyOnlyFilter_toByteArray
/** Returns The filter serialized using pb */ @Override public byte[] toByteArray() { FilterProtos.KeyOnlyFilter.Builder builder = FilterProtos.KeyOnlyFilter.newBuilder(); builder.setLenAsVal(this.lenAsVal); return builder.build().toByteArray(); }
3.68
flink_InternalWindowProcessFunction_isWindowLate
/** * Returns {@code true} if the watermark is after the end timestamp plus the allowed lateness of * the given window. */ protected boolean isWindowLate(W window) { return (windowAssigner.isEventTime() && (toEpochMillsForTimer(cleanupTime(window), ctx.getShiftTimeZone()) <= ctx.c...
3.68
hudi_BaseTableMetadata_getAllPartitionPaths
/** * Return the list of partitions in the dataset. * <p> * If the Metadata Table is enabled, the listing is retrieved from the stored metadata. Otherwise, the list of * partitions is retrieved directly from the underlying {@code FileSystem}. * <p> * On any errors retrieving the listing from the metadata, default...
3.68
flink_UserDefinedFunctionHelper_validateImplementationMethods
/** * Validates the implementation methods such as {@link #SCALAR_EVAL} or {@link * #AGGREGATE_ACCUMULATE} depending on the {@link UserDefinedFunction} subclass. * * <p>This method must be kept in sync with the code generation requirements and the individual * docs of each function. */ private static void validat...
3.68
flink_ProcessPythonEnvironmentManager_getBootLog
/** Returns the boot log of the Python Environment. */ public String getBootLog() throws Exception { File bootLogFile = new File(resource.baseDirectory + File.separator + "flink-python-udf-boot.log"); String msg = "Failed to create stage bundle factory!"; if (bootLogFile.exists()) { byte...
3.68
flink_TypeInferenceExtractor_forAggregateFunction
/** Extracts a type inference from a {@link AggregateFunction}. */ public static TypeInference forAggregateFunction( DataTypeFactory typeFactory, Class<? extends AggregateFunction<?, ?>> function) { final FunctionMappingExtractor mappingExtractor = new FunctionMappingExtractor( ...
3.68
hudi_InternalSchemaUtils_pruneInternalSchemaByID
/** * Create project internalSchema. * support nested project. * * @param schema a internal schema. * @param fieldIds project col field_ids. * @return a project internalSchema. */ public static InternalSchema pruneInternalSchemaByID(InternalSchema schema, List<Integer> fieldIds, List<Integer> topParentFieldIds) ...
3.68
morf_AbstractSqlDialectTest_expectedSqlForMathOperations11
/** * @return expected SQL for math operation 11 */ protected String expectedSqlForMathOperations11() { return "(a / 100 + 1) / b + 100"; }
3.68
dubbo_ServiceDeployer_getExtensions
/** * get extensions by type * * @param extensionClass * @param <T> * @return */ // TODO add javax.annotation.Priority sort public <T> List<T> getExtensions(Class<T> extensionClass) { ArrayList<T> exts = new ArrayList<>(); if (extensions.isEmpty()) { return exts; } for (Object extension...
3.68
hudi_AvroInternalSchemaConverter_fixNullOrdering
/** * Converting from avro -> internal schema -> avro * causes null to always be first in unions. * if we compare a schema that has not been converted to internal schema * at any stage, the difference in ordering can cause issues. To resolve this, * we order null to be first for any avro schema that enters into hu...
3.68
hbase_HRegion_getRegionWALFileSystem
/** Returns the WAL {@link HRegionFileSystem} used by this region */ HRegionWALFileSystem getRegionWALFileSystem() throws IOException { return new HRegionWALFileSystem(conf, getWalFileSystem(), CommonFSUtils.getWALTableDir(conf, htableDescriptor.getTableName()), fs.getRegionInfo()); }
3.68
flink_PrioritizedDeque_size
/** Returns the number of priority and non-priority elements. */ public int size() { return deque.size(); }
3.68
pulsar_ManagedLedgerConfig_setMetadataEnsembleSize
/** * @param metadataEnsembleSize * the metadataEnsembleSize to set */ public ManagedLedgerConfig setMetadataEnsembleSize(int metadataEnsembleSize) { this.metadataEnsembleSize = metadataEnsembleSize; return this; }
3.68
morf_AbstractSqlDialectTest_provideCustomHint
/** * This method can be overridden in specific dialects to test providing custom hints in each dialect * @return a mock CustomHint or an overridden, more specific, CustomHint */ @SuppressWarnings("deprecation") protected CustomHint provideCustomHint() { return mock(CustomHint.class); }
3.68
pulsar_AuthenticationDataKeyStoreTls_hasDataForTls
/* * TLS */ @Override public boolean hasDataForTls() { return true; }
3.68
flink_KvStateInfo_duplicate
/** * Creates a deep copy of the current {@link KvStateInfo} by duplicating all the included * serializers. * * <p>This method assumes correct implementation of the {@link TypeSerializer#duplicate()} * method of the included serializers. */ public KvStateInfo<K, N, V> duplicate() { final TypeSerializer<K> dup...
3.68
morf_SQLEntityNameValidationService_isReservedWord
/** * Method to establish if a given string is an SQL Reserved Word * * @param word the string to establish if its a SQL Reserved Word * @return true if its a SQL Reserved Word otherwise false. */ public boolean isReservedWord(String word) { return schemaValidator.isSQLReservedWord(word); }
3.68
morf_AbstractSqlDialectTest_windowFunctions
/** * The window functions to test */ private FluentIterable<AliasedField> windowFunctions(){ return FluentIterable.from(Lists.newArrayList( windowFunction(count()).build(), windowFunction(count()).partitionBy(field("field1")).build(), windowFunction(sum(field("field1"))).partitionBy(field("field2"),fie...
3.68
hbase_KeyValue_getBuffer
/** * To be used only in tests where the Cells are clearly assumed to be of type KeyValue and that we * need access to the backing array to do some test case related assertions. * @return The byte array backing this KeyValue. */ public byte[] getBuffer() { return this.bytes; }
3.68
framework_ScrollbarBundle_setScrollPosByDelta
/** * Modifies the scroll position of this scrollbar by a number of pixels. * <p> * <em>Note:</em> Even though {@code double} values are used, they are * currently only used as integers as large {@code int} (or small but fast * {@code long}). This means, all values are truncated to zero decimal * places. * * @p...
3.68
hadoop_BlockStorageMovementNeeded_decrementPendingWorkCount
/** * Decrement the pending work count for directory one track info is * completed. */ public synchronized void decrementPendingWorkCount() { this.pendingWorkCount--; }
3.68
hadoop_TypedBytesInput_readList
/** * Reads the list following a <code>Type.LIST</code> code. * @return the obtained list * @throws IOException */ @SuppressWarnings("unchecked") public List readList() throws IOException { List list = new ArrayList(); Object obj = read(); while (obj != null) { list.add(obj); obj = read(); } retur...
3.68
hadoop_ActiveAuditManagerS3A_modifyHttpResponse
/** * Forward to the inner span. * {@inheritDoc} */ @Override public SdkHttpResponse modifyHttpResponse(Context.ModifyHttpResponse context, ExecutionAttributes executionAttributes) { return span.modifyHttpResponse(context, executionAttributes); }
3.68
hudi_HoodieMergedLogRecordReader_scan
/** * Scans delta-log files processing blocks */ public final void scan() { scan(false); }
3.68
hbase_ExecutorService_getName
/** * Returns the executor name inferred from the type and the servername on which this is running. */ public String getName() { return getExecutorType().getExecutorName(servername); }
3.68
hbase_MasterObserver_postCreateNamespace
/** * Called after the createNamespace operation has been requested. * @param ctx the environment to interact with the framework and master * @param ns the NamespaceDescriptor for the table */ default void postCreateNamespace(final ObserverContext<MasterCoprocessorEnvironment> ctx, NamespaceDescriptor ns) throws...
3.68
hbase_HeterogeneousRegionCountCostFunction_prepare
/** * Called once per LB invocation to give the cost function to initialize it's state, and perform * any costly calculation. */ @Override void prepare(final BalancerClusterState cluster) { this.cluster = cluster; this.loadRules(); }
3.68
flink_BinarySegmentUtils_getBytes
/** Maybe not copied, if want copy, please use copyTo. */ public static byte[] getBytes(MemorySegment[] segments, int baseOffset, int sizeInBytes) { // avoid copy if `base` is `byte[]` if (segments.length == 1) { byte[] heapMemory = segments[0].getHeapMemory(); if (baseOffset == 0 && heapMemory ...
3.68
hadoop_LocalityMulticastAMRMProxyPolicy_splitIndividualAny
/** * Return a projection of this ANY {@link ResourceRequest} that belongs to * this sub-cluster. This is done based on the "count" of the containers that * require locality in each sublcuster (if any) or based on the "weights" and * headroom. */ private void splitIndividualAny(ResourceRequest originalResourceRequ...
3.68
dubbo_AbstractStateRouter_setNextRouter
/** * Next Router node state is maintained by AbstractStateRouter and this method is not allow to override. * If a specified router wants to control the behaviour of continue route or not, * please override {@link AbstractStateRouter#supportContinueRoute()} */ @Override public final void setNextRouter(StateRouter<T...
3.68
framework_MenuBarConnector_updateFromUIDL
/** * This method must be implemented to update the client-side component from * UIDL data received from server. * * This method is called when the page is loaded for the first time, and * every time UI changes in the component are received from the server. */ @Override public void updateFromUIDL(UIDL uidl, Appli...
3.68
framework_ScrollbarBundle_recalculateMaxScrollPos
/** * Calculates and sets maximum scroll position based on the current scroll * size and the scrollbar's length. */ public void recalculateMaxScrollPos() { double scrollSize = getScrollSize(); double offsetSize = getOffsetSize(); maxScrollPos = Math.max(0, scrollSize - offsetSize); // make sure that...
3.68
hbase_CellFlatMap_pollFirstEntry
// The following 2 methods (pollFirstEntry, pollLastEntry) are unsupported because these are // updating methods. @Override public Entry<Cell, Cell> pollFirstEntry() { throw new UnsupportedOperationException(); }
3.68
flink_FromClasspathEntryClassInformationProvider_getJobClassName
/** * Returns the job class name if it could be derived from the specified classpath or was * explicitly specified. * * @return The job class name or an empty {@code Optional} if none was specified and it couldn't * be derived from the classpath. */ @Override public Optional<String> getJobClassName() { re...
3.68
flink_UnresolvedDataType_toDataType
/** * Converts this instance to a resolved {@link DataType} possibly enriched with additional * nullability and conversion class information. */ public DataType toDataType(DataTypeFactory factory) { DataType resolvedDataType = resolutionFactory.apply(factory); if (isNullable == Boolean.TRUE) { resolv...
3.68
framework_AriaHelper_setVisibleForAssistiveDevicesOnly
/** * Allows to move an element out of the visible area of the browser window. * * This makes it possible to have additional information for an assistive * device, that is not in the way for visual users. * * @param element * Element to move out of sight * @param assistiveOnly * {@code tr...
3.68
hadoop_NMClientAsync_onContainerRestart
/** * Callback for container restart. * * @param containerId the Id of the container to restart. */ public void onContainerRestart(ContainerId containerId) {}
3.68
dubbo_RouterChain_setInvokers
/** * Notify router chain of the initial addresses from registry at the first time. * Notify whenever addresses in registry change. */ public synchronized void setInvokers(BitList<Invoker<T>> invokers, Runnable switchAction) { try { // Lock to prevent directory continue list lock.writeLock().lock...
3.68
hbase_CatalogReplicaLoadBalanceSelectorFactory_createSelector
/** * Create a CatalogReplicaLoadBalanceReplicaSelector based on input config. * @param replicaSelectorClass Selector classname. * @param tableName System table name. * @param conn {@link AsyncConnectionImpl} * @return {@link CatalogReplicaLoadBalanceSelector} */ public static CatalogRe...
3.68
hadoop_SQLDelegationTokenSecretManager_storeToken
/** * Persists a TokenIdentifier and its corresponding TokenInformation into * the SQL database. The TokenIdentifier is expected to be unique and any * duplicate token attempts will result in an IOException. * @param ident TokenIdentifier to persist. * @param tokenInfo DelegationTokenInformation associated with th...
3.68
pulsar_AdditionalServletUtils_getAdditionalServletDefinition
/** * Retrieve the additional servlet definition from the provided nar package. * * @param narPath the path to the additional servlet NAR package * @return the additional servlet definition * @throws IOException when fail to load the additional servlet or get the definition */ public AdditionalServletDefinition g...
3.68
flink_HyperLogLogPlusPlus_distance
/** * Use square of the difference between the current estimate and the estimate at the given index * as distance metric. */ private double distance(double e, double[] estimates, int i) { double diff = e - estimates[i]; return diff * diff; }
3.68
hbase_ZKWatcher_filterMetaReplicaNodes
/** * @param nodes Input list of znodes * @return Filtered list of znodes from nodes that belong to meta replica(s). */ private List<String> filterMetaReplicaNodes(List<String> nodes) { if (nodes == null || nodes.isEmpty()) { return new ArrayList<>(); } List<String> metaReplicaNodes = new ArrayList<>(2); ...
3.68
flink_AbstractHeapState_getStateTable
/** This should only be used for testing. */ @VisibleForTesting public StateTable<K, N, SV> getStateTable() { return stateTable; }
3.68
hbase_RegionScannerImpl_resetFilters
/** * Reset both the filter and the old filter. * @throws IOException in case a filter raises an I/O exception. */ protected final void resetFilters() throws IOException { if (filter != null) { filter.reset(); } }
3.68
hadoop_AclEntryType_toStringStable
/** * Returns a string representation guaranteed to be stable across versions to * satisfy backward compatibility requirements, such as for shell command * output or serialization. * * @return stable, backward compatible string representation */ public String toStringStable() { // The base implementation uses t...
3.68
hadoop_ServiceRecord_addExternalEndpoint
/** * Add an external endpoint * @param endpoint endpoint to set */ public void addExternalEndpoint(Endpoint endpoint) { Preconditions.checkArgument(endpoint != null); endpoint.validate(); external.add(endpoint); }
3.68
pulsar_ManagedCursorContainer_cursorUpdated
/** * Signal that a cursor position has been updated and that the container must re-order the cursor heap * tracking the slowest reader. * Only those cursors are tracked and can be updated which were added to the container with the * {@link #add(ManagedCursor, Position)} method that specified the initial position i...
3.68
flink_ShuffleMaster_registerJob
/** * Registers the target job together with the corresponding {@link JobShuffleContext} to this * shuffle master. Through the shuffle context, one can obtain some basic information like job * ID, job configuration. It enables ShuffleMaster to notify JobMaster about lost result * partitions, so that JobMaster can i...
3.68
morf_DatabaseMetaDataProvider_dataTypeFromSqlType
/** * Converts a given SQL data type to a {@link DataType}. * * @param typeCode JDBC data type. * @param typeName JDBC type name. * @param width JDBC column size. * @return Morf data type. */ protected DataType dataTypeFromSqlType(int typeCode, String typeName, int width) { switch (typeCode) { case Types.T...
3.68