name
stringlengths
12
178
code_snippet
stringlengths
8
36.5k
score
float64
3.26
3.68
framework_RichTextArea_setValue
/** * Sets the value of this object. If the new value is not equal to * {@code getValue()}, fires a {@link ValueChangeEvent}. Throws * {@code NullPointerException} if the value is null. * * @param value * the new value, not {@code null} * @throws NullPointerException * if {@code value} is...
3.68
graphhopper_VectorTile_getTagsCount
/** * <pre> * Tags of this feature are encoded as repeated pairs of * integers. * A detailed description of tags is located in sections * 4.2 and 4.4 of the specification * </pre> * * <code>repeated uint32 tags = 2 [packed = true];</code> */ public int getTagsCount() { return tags_.size(); }
3.68
hbase_ScannerContext_setSizeLimitScope
/** * @param scope The scope in which the size limit will be enforced */ void setSizeLimitScope(LimitScope scope) { limits.setSizeScope(scope); }
3.68
hbase_AccessControlUtil_revoke
/** * A utility used to revoke a user's namespace permissions. * <p> * It's also called by the shell, in case you want to find references. * @param controller RpcController * @param protocol the AccessControlService protocol proxy * @param userShortName the short name of the user to revoke permissions * ...
3.68
hbase_MultiTableSnapshotInputFormatImpl_getSplits
/** * Return the list of splits extracted from the scans/snapshots pushed to conf by * {@link #setInput(Configuration, Map, Path)} * @param conf Configuration to determine splits from * @return Return the list of splits extracted from the scans/snapshots pushed to conf */ public List<TableSnapshotInputFormatImpl.I...
3.68
hadoop_ReservationListRequest_newInstance
/** * The {@link ReservationListRequest} will use the reservationId to search for * reservations to list if it is provided. Otherwise, it will select active * reservations within the startTime and endTime (inclusive). * * @param queue Required. Cannot be null or empty. Refers to the reservable * queu...
3.68
flink_SlotManagerUtils_generateDefaultSlotResourceProfile
/** * This must be consist with {@link * org.apache.flink.runtime.taskexecutor.TaskExecutorResourceUtils#generateDefaultSlotResourceProfile}. */ public static ResourceProfile generateDefaultSlotResourceProfile( ResourceProfile resourceProfile, int numSlotsPerWorker) { final ResourceProfile.Builder resour...
3.68
hbase_OrderedBytes_encodeNumericSmall
/** * <p> * Encode the small magnitude floating point number {@code val} using the key encoding. The caller * guarantees that 1.0 > abs(val) > 0.0. * </p> * <p> * A floating point value is encoded as an integer exponent {@code E} and a mantissa {@code M}. * The original value is equal to {@code (M * 100^E)}. {@c...
3.68
flink_StateBootstrapTransformation_getMaxParallelism
/** @return The max parallelism for this operator. */ int getMaxParallelism(int globalMaxParallelism) { return operatorMaxParallelism.orElse(globalMaxParallelism); }
3.68
flink_ExceptionUtils_isDirectOutOfMemoryError
/** * Checks whether the given exception indicates a JVM direct out-of-memory error. * * @param t The exception to check. * @return True, if the exception is the direct {@link OutOfMemoryError}, false otherwise. */ public static boolean isDirectOutOfMemoryError(@Nullable Throwable t) { return isOutOfMemoryErro...
3.68
hbase_HRegion_onConfigurationChange
/** * {@inheritDoc} */ @Override public void onConfigurationChange(Configuration conf) { this.storeHotnessProtector.update(conf); // update coprocessorHost if the configuration has changed. if ( CoprocessorConfigurationUtil.checkConfigurationChange(getReadOnlyConfiguration(), conf, CoprocessorHost.REG...
3.68
flink_RocksDBNativeMetricOptions_enableBlockCacheCapacity
/** Returns block cache capacity. */ public void enableBlockCacheCapacity() { this.properties.add(RocksDBProperty.BlockCacheCapacity.getRocksDBProperty()); }
3.68
hbase_MasterObserver_postListSnapshot
/** * Called after listSnapshots request has been processed. * @param ctx the environment to interact with the framework and master * @param snapshot the SnapshotDescriptor of the snapshot to list */ default void postListSnapshot(final ObserverContext<MasterCoprocessorEnvironment> ctx, final SnapshotDescript...
3.68
flink_ExecutionConfig_getRegisteredKryoTypes
/** Returns the registered Kryo types. */ public LinkedHashSet<Class<?>> getRegisteredKryoTypes() { if (isForceKryoEnabled()) { // if we force kryo, we must also return all the types that // were previously only registered as POJO LinkedHashSet<Class<?>> result = new LinkedHashSet<>(); ...
3.68
flink_CheckpointedInputGate_getCheckpointStartDelayNanos
/** * @return the time that elapsed, in nanoseconds, between the creation of the latest checkpoint * and the time when it's first {@link CheckpointBarrier} was received by this {@link * InputGate}. */ @VisibleForTesting long getCheckpointStartDelayNanos() { return barrierHandler.getCheckpointStartDelayN...
3.68
framework_AbstractMedia_setHtmlContentAllowed
/** * Set whether the alternative text ({@link #setAltText(String)}) is * rendered as HTML or not. * * @param htmlContentAllowed */ public void setHtmlContentAllowed(boolean htmlContentAllowed) { getState().htmlContentAllowed = htmlContentAllowed; }
3.68
flink_PythonEnvironmentManagerUtils_pipInstallRequirements
/** * Installs the 3rd party libraries listed in the user-provided requirements file. An optional * requirements cached directory can be provided to support offline installation. In order not * to populate the public environment, the libraries will be installed to the specified * directory, and added to the PYTHONP...
3.68
hbase_AbstractWALProvider_getSyncReplicationPeerIdFromWALName
/** * <p> * Returns the peer id if the wal file name is in the special group for a sync replication peer. * </p> * <p> * The prefix format is &lt;factoryId&gt;-&lt;ts&gt;-&lt;peerId&gt;. * </p> */ public static Optional<String> getSyncReplicationPeerIdFromWALName(String name) { if (!name.endsWith(ReplicationUt...
3.68
hadoop_SharedKeyCredentials_getCanonicalizedResource
/** * Gets the canonicalized resource string for a Blob or Queue service request under the Shared Key Lite * authentication scheme. * * @param address the resource URI. * @param accountName the account name for the request. * @return the canonicalized resource string. */ private static String getCanonicalize...
3.68
hbase_Compactor_postCompactScannerOpen
/** * Calls coprocessor, if any, to create scanners - after normal scanner creation. * @param request Compaction request. * @param scanType Scan type. * @param scanner The default scanner created for compaction. * @return Scanner scanner to use (usually the default); null if compaction should not proceed. */ pr...
3.68
framework_StaticSection_setStyleName
/** * Sets a custom style name for this cell. * * @param styleName * the style name to set or null to not use any style name */ public void setStyleName(String styleName) { cellState.styleName = styleName; row.section.markAsDirty(); }
3.68
hadoop_AbstractS3ACommitter_recoverTask
/** * Task recovery considered Unsupported: Warn and fail. * @param taskContext Context of the task whose output is being recovered * @throws IOException always. */ @Override public void recoverTask(TaskAttemptContext taskContext) throws IOException { LOG.warn("Cannot recover task {}", taskContext.getTaskAttemptI...
3.68
hadoop_ReencryptionHandler_processFileInode
/** * Process an Inode for re-encryption. Add to current batch if it's a file, * no-op otherwise. * * @param inode * the inode * @return true if inode is added to currentBatch and should be * re-encrypted. false otherwise: could be inode is not a file, or * inode's edek's key version is...
3.68
hadoop_NFS3Request_readHandle
/** * Deserialize a handle from an XDR object */ static FileHandle readHandle(XDR xdr) throws IOException { FileHandle handle = new FileHandle(); if (!handle.deserialize(xdr)) { throw new IOException("can't deserialize file handle"); } return handle; }
3.68
dubbo_AbstractConditionMatcher_doPatternMatch
// range, equal or other methods protected boolean doPatternMatch( String pattern, String value, URL url, Invocation invocation, boolean isWhenCondition) { for (ValuePattern valueMatcher : valueMatchers) { if (valueMatcher.shouldMatch(pattern)) { return valueMatcher.match(pattern, value,...
3.68
pulsar_SchemaDefinitionImpl_getProperties
/** * Get schema class. * * @return schema class */ public Map<String, String> getProperties() { return Collections.unmodifiableMap(properties); }
3.68
morf_MergingDatabaseDataSetConsumer_table
/** * @see DataSetConsumer#table(Table, Iterable) */ @Override public void table(Table table, Iterable<Record> records) { TableLoader.builder() .withConnection(connection) .withSqlScriptExecutor(sqlExecutor) .withDialect(sqlDialect) .explicitCommit(true) .merge(true) .insertingWithPresetAuto...
3.68
flink_ChannelStatePersister_parseEvent
/** * Parses the buffer as an event and returns the {@link CheckpointBarrier} if the event is * indeed a barrier or returns null in all other cases. */ @Nullable protected AbstractEvent parseEvent(Buffer buffer) throws IOException { if (buffer.isBuffer()) { return null; } else { AbstractEvent...
3.68
hbase_ScannerModel_hasEndRow
/** Returns true if an end row was specified */ public boolean hasEndRow() { return !Bytes.equals(endRow, HConstants.EMPTY_END_ROW); }
3.68
flink_MetricStore_addAll
/** * Add metric dumps to the store. * * @param metricDumps to add. */ synchronized void addAll(List<MetricDump> metricDumps) { for (MetricDump metric : metricDumps) { add(metric); } }
3.68
flink_ExternalPythonKeyedCoProcessOperator_processTimer
/** * It is responsible to send timer data to python worker when a registered timer is fired. The * input data is a Row containing 4 fields: TimerFlag 0 for proc time, 1 for event time; * Timestamp of the fired timer; Current watermark and the key of the timer. * * @param timeDomain The type of the timer. * @para...
3.68
querydsl_BooleanBuilder_andNot
/** * Create the insertion of this and the negation of the given predicate * * @param right predicate to be negated * @return the current object */ public BooleanBuilder andNot(Predicate right) { return and(right.not()); }
3.68
dubbo_DynamicConfiguration_publishConfig
/** * Publish Config mapped to the given key and the given group. * * @param key the key to represent a configuration * @param group the group where the key belongs to * @param content the content of configuration * @return <code>true</code> if success, or <code>false</code> * @throws UnsupportedOperationE...
3.68
framework_ApplicationConnection_updateComponent
/** * Method provided for backwards compatibility. Duties previously done by * this method is now handled by the state change event handler in * AbstractComponentConnector. The only function this method has is to * return true if the UIDL is a "cached" update. * * @param component * @param uidl * @param manageC...
3.68
framework_Window_setPositionY
/** * Sets the distance of Window top border in pixels from top border of the * containing (main window). Has effect only if in {@link WindowMode#NORMAL} * mode. * * @param positionY * the Distance of Window top border in pixels from top border of * the containing (main window). or -1 if un...
3.68
pulsar_KerberosName_getServiceName
/** * Get the first component of the name. * @return the first section of the Kerberos principal name */ public String getServiceName() { return serviceName; }
3.68
hbase_RegionModeStrategy_selectModeFieldsAndAddCountField
/** * Form new record list with records formed by only fields provided through fieldInfo and add a * count field for each record with value 1 We are doing two operation of selecting and adding new * field because of saving some CPU cycles on rebuilding the record again * @param fieldInfos List of FieldInfos require...
3.68
dubbo_Bytes_bytes2float
/** * to int. * * @param b byte array. * @param off offset. * @return int. */ public static float bytes2float(byte[] b, int off) { int i = ((b[off + 3] & 0xFF) << 0) + ((b[off + 2] & 0xFF) << 8) + ((b[off + 1] & 0xFF) << 16) + ((b[off + 0]) << 24); return Float.intBit...
3.68
flink_FlinkRexBuilder_makeZeroLiteral
/** * Creates a literal of the default value for the given type. * * <p>This value is: * * <ul> * <li>0 for numeric types; * <li>FALSE for BOOLEAN; * <li>The epoch for TIMESTAMP and DATE; * <li>Midnight for TIME; * <li>The empty string for string types (CHAR, BINARY, VARCHAR, VARBINARY). * </ul> *...
3.68
hadoop_BlockBlobInputStream_resetStreamBuffer
/** * Reset the internal stream buffer but do not release the memory. * The buffer can be reused to avoid frequent memory allocations of * a large buffer. */ private void resetStreamBuffer() { streamBufferPosition = 0; streamBufferLength = 0; }
3.68
hbase_TableSchemaModel___setIsMeta
/** * @param value desired value of IS_META attribute */ public void __setIsMeta(boolean value) { attrs.put(IS_META, Boolean.toString(value)); }
3.68
hudi_SparkUtil_getDefaultConf
/** * Get the default spark configuration. * * @param appName - Spark application name * @param sparkMaster - Spark master node name * @return Spark configuration */ public static SparkConf getDefaultConf(final String appName, final Option<String> sparkMaster) { final Properties properties = System.getPrope...
3.68
hmily_SchemaCache_getInstance
/** * Gets instance. * * @return the instance */ protected static SchemaCache getInstance() { return SchemaCacheHolder.cache; }
3.68
pulsar_AuthenticationProviderSasl_getAuthState
// return authState if it is in cache. private AuthenticationState getAuthState(HttpServletRequest request) { String id = request.getHeader(SASL_STATE_SERVER); if (id == null) { return null; } try { return authStates.getIfPresent(Long.parseLong(id)); } catch (NumberFormatException e...
3.68
dubbo_RpcContext_getLocalAddress
/** * get local address. * * @return local address */ public InetSocketAddress getLocalAddress() { return newRpcContext.getLocalAddress(); }
3.68
hadoop_CacheDirectiveStats_setFilesCached
/** * Sets the files cached by this directive. * * @param filesCached The number of files cached. * @return This builder, for call chaining. */ public Builder setFilesCached(long filesCached) { this.filesCached = filesCached; return this; }
3.68
hadoop_TaskAttemptsInfo_getTaskAttempts
// XmlElementRef annotation should be used to identify the exact type of a list element // otherwise metadata will be added to XML attributes, // it can lead to incorrect JSON marshaling @XmlElementRef public List<TaskAttemptInfo> getTaskAttempts() { return taskAttempts; }
3.68
dubbo_RestRPCInvocationUtil_createBaseRpcInvocation
/** * build RpcInvocation * * @param request * @param restMethodMetadata * @return */ public static RpcInvocation createBaseRpcInvocation(RequestFacade request, RestMethodMetadata restMethodMetadata) { RpcInvocation rpcInvocation = new RpcInvocation(); rpcInvocation.setParameterTypes(restMethodMetadata.g...
3.68
flink_DataStreamAllroundTestJobFactory_createEventSource
/** * @deprecated This method relies on the {@link * org.apache.flink.streaming.api.functions.source.SourceFunction} API, which is due to be * removed. Use the new {@link org.apache.flink.api.connector.source.Source} API instead. */ @Deprecated static SourceFunction<Event> createEventSource(ParameterTool pt...
3.68
flink_KeyGroupRangeAssignment_computeOperatorIndexForKeyGroup
/** * Computes the index of the operator to which a key-group belongs under the given parallelism * and maximum parallelism. * * <p>IMPORTANT: maxParallelism must be <= Short.MAX_VALUE + 1 to avoid rounding problems in * this method. If we ever want to go beyond this boundary, this method must perform arithmetic ...
3.68
AreaShop_WorldEditSelection_getLength
/** * Get Z-size. * * @return length */ public int getLength() { return maximum.getBlockZ() - minimum.getBlockZ() + 1; }
3.68
flink_KubernetesUtils_createJobGraphStateHandleStore
/** * Create a {@link KubernetesStateHandleStore} which storing {@link JobGraph}. * * @param configuration configuration to build a RetrievableStateStorageHelper * @param flinkKubeClient flink kubernetes client * @param configMapName ConfigMap name * @param lockIdentity lock identity to check the leadership * @r...
3.68
hbase_MetricsSink_getStartTimestamp
/** * Gets the time stamp from when the Sink was initialized. */ public long getStartTimestamp() { return this.startTimestamp; }
3.68
hadoop_ContainerContext_getUser
/** * Get user of the container being initialized or stopped. * * @return the user */ public String getUser() { return user; }
3.68
graphhopper_GraphHopper_setUrbanDensityCalculation
/** * Configures the urban density classification. Each edge will be classified as 'rural','residential' or 'city', {@link UrbanDensity} * * @param residentialAreaRadius in meters. The higher this value the longer the calculation will take and the bigger the area for * which t...
3.68
hbase_NamespaceDescriptor_removeConfiguration
/** * Remove a config setting represented by the key from the {@link #configuration} map */ public void removeConfiguration(final String key) { configuration.remove(key); }
3.68
querydsl_DateTimeExpression_week
/** * Create a week expression * * @return week */ public NumberExpression<Integer> week() { if (week == null) { week = Expressions.numberOperation(Integer.class, Ops.DateTimeOps.WEEK, mixin); } return week; }
3.68
framework_VTabsheet_selectTab
/** * Selects the indicated tab, deselects the previously selected tab, and * updates the style names, tabulator indices, and the * {@code aria-selected} roles to match. Also recalculates the tab * caption widths in case the addition or removal of the selection style * changed them, and schedules a scroll for movi...
3.68
hudi_HoodieTableMetadataUtil_createIndexInitTimestamp
/** * Create the timestamp for an index initialization operation on the metadata table. * <p> * Since many MDT partitions can be initialized one after other the offset parameter controls generating a * unique timestamp. */ public static String createIndexInitTimestamp(String timestamp, int offset) { return Strin...
3.68
flink_MasterHooks_reset
/** * Resets the master hooks. * * @param hooks The hooks to reset * @throws FlinkException Thrown, if the hooks throw an exception. */ public static void reset( final Collection<MasterTriggerRestoreHook<?>> hooks, @SuppressWarnings("unused") final Logger log) throws FlinkException { f...
3.68
flink_TimestampData_fromEpochMillis
/** * Creates an instance of {@link TimestampData} from milliseconds and a nanos-of-millisecond. * * @param milliseconds the number of milliseconds since {@code 1970-01-01 00:00:00}; a negative * number is the number of milliseconds before {@code 1970-01-01 00:00:00} * @param nanosOfMillisecond the nanoseconds...
3.68
querydsl_SQLMergeClause_executeWithKeys
/** * Execute the clause and return the generated keys as a ResultSet * * @return result set with generated keys */ public ResultSet executeWithKeys() { context = startContext(connection(), metadata, entity); try { if (configuration.getTemplates().isNativeMerge()) { PreparedStatement stm...
3.68
hadoop_NamenodeStatusReport_getScheduledReplicationBlocks
/** * Blocks scheduled for replication. * * @return - num of blocks scheduled for replication */ public long getScheduledReplicationBlocks() { return this.scheduledReplicationBlocks; }
3.68
dubbo_AbstractConfigManager_isNeedValidation
/** * The component configuration that does not affect the main process does not need to be verified. * * @param config * @param <T> * @return */ protected <T extends AbstractConfig> boolean isNeedValidation(T config) { if (config instanceof MetadataReportConfig) { return false; } return true;...
3.68
hbase_ByteBufferUtils_putShort
/** * Put a short value out to the given ByteBuffer's current position in big-endian format. This * also advances the position in buffer by short size. * @param buffer the ByteBuffer to write to * @param val short to write out */ public static void putShort(ByteBuffer buffer, short val) { ConverterHolder.BEST...
3.68
hadoop_DockerClientConfigHandler_getCredentialsFromTokensByteBuffer
/** * Convert the Token ByteBuffer to the appropriate Credentials object. * * @param tokens the Tokens from the ContainerLaunchContext. * @return the Credentials object populated from the Tokens. * @throws IOException io error occur. */ public static Credentials getCredentialsFromTokensByteBuffer( ByteBuffer ...
3.68
rocketmq-connect_ColumnDefinition_isCurrency
/** * Indicates whether the column is a cash value. * * @return <code>true</code> if so; <code>false</code> otherwise */ public boolean isCurrency() { return currency; }
3.68
hudi_OptionsResolver_isConsistentHashingBucketIndexType
/** * Returns whether the table index is consistent bucket index. */ public static boolean isConsistentHashingBucketIndexType(Configuration conf) { return isBucketIndexType(conf) && getBucketEngineType(conf).equals(HoodieIndex.BucketIndexEngineType.CONSISTENT_HASHING); }
3.68
framework_TypeDataStore_getProperties
/** * @param type * @return * @throws NoDataException * * @deprecated As of 7.0.1, use {@link #getPropertiesAsArray(Type)} instead * for improved performance */ @Deprecated public static Collection<Property> getProperties(Type type) throws NoDataException { JsArrayObject<Property> propert...
3.68
hbase_HMaster_executeRegionPlansWithThrottling
/** * Execute region plans with throttling * @param plans to execute * @return succeeded plans */ public List<RegionPlan> executeRegionPlansWithThrottling(List<RegionPlan> plans) { List<RegionPlan> successRegionPlans = new ArrayList<>(); int maxRegionsInTransition = getMaxRegionsInTransition(); long balanceSt...
3.68
flink_MapView_getMap
/** Returns the entire view's content as an instance of {@link Map}. */ public Map<K, V> getMap() { return map; }
3.68
hadoop_SQLDelegationTokenSecretManager_incrementCurrentKeyId
/** * Obtains the next available delegation key id that can be allocated to a DelegationKey. * Delegation key id need to be reserved using the shared delegationKeyIdCounter, * which handles keyId allocation concurrently with other secret managers. * @return Next available delegation key id. */ @Override public int...
3.68
pulsar_MessageDeduplication_replayCursor
/** * Read all the entries published from the cursor position until the most recent and update the highest sequence id * from each producer. * * @param future future to trigger when the replay is complete */ private void replayCursor(CompletableFuture<Void> future) { managedCursor.asyncReadEntries(100, new Rea...
3.68
hudi_BaseHoodieTableServiceClient_inlineScheduleCompaction
/** * Schedules compaction inline. * * @param extraMetadata extra metadata to be used. * @return compaction instant if scheduled. */ protected Option<String> inlineScheduleCompaction(Option<Map<String, String>> extraMetadata) { return scheduleCompaction(extraMetadata); }
3.68
hadoop_LongLong_shiftRight
/** Shift right operation (>>). */ long shiftRight(int n) { return (d1 << (BITS_PER_LONG - n)) + (d0 >>> n); }
3.68
flink_AsyncSnapshotCallable_toAsyncSnapshotFutureTask
/** * Creates a future task from this and registers it with the given {@link CloseableRegistry}. * The task is unregistered again in {@link FutureTask#done()}. */ public AsyncSnapshotTask toAsyncSnapshotFutureTask(@Nonnull CloseableRegistry taskRegistry) throws IOException { return new AsyncSnapshotTask(...
3.68
flink_Plan_getJobName
/** * Gets the name of this job. * * @return The name of the job. */ public String getJobName() { return this.jobName; }
3.68
hbase_Union3_decodeC
/** * Read an instance of the third type parameter from buffer {@code src}. */ public C decodeC(PositionedByteRange src) { return (C) decode(src); }
3.68
hbase_BloomFilterFactory_getErrorRate
/** Returns the Bloom filter error rate in the given configuration */ public static float getErrorRate(Configuration conf) { return conf.getFloat(IO_STOREFILE_BLOOM_ERROR_RATE, (float) 0.01); }
3.68
flink_ScalaCsvOutputFormat_setAllowNullValues
/** * Configures the format to either allow null values (writing an empty field), or to throw an * exception when encountering a null field. * * <p>By default, null values are allowed. * * @param allowNulls Flag to indicate whether the output format should accept null values. */ public void setAllowNullValues(bo...
3.68
hbase_RowFilter_areSerializedFieldsEqual
/** * Returns true if and only if the fields of the filter that are serialized are equal to the * corresponding fields in other. Used for testing. */ @Override boolean areSerializedFieldsEqual(Filter o) { if (o == this) { return true; } if (!(o instanceof RowFilter)) { return false; } return super....
3.68
hadoop_BlockMovementStatus_getStatusCode
/** * @return the status code. */ int getStatusCode() { return code; }
3.68
hbase_HRegion_replayFlushInStores
/** * Replays the given flush descriptor by opening the flush files in stores and dropping the * memstore snapshots if requested. * @deprecated Since 3.0.0, will be removed in 4.0.0. Only for keep compatibility for old region * replica implementation. */ @Deprecated private void replayFlushInStores(Flu...
3.68
hbase_ReplicationSourceManager_postLogRoll
// public because of we call it in TestReplicationEmptyWALRecovery public void postLogRoll(Path newLog) throws IOException { String logName = newLog.getName(); String logPrefix = AbstractFSWALProvider.getWALPrefixFromWALName(logName); // synchronized on latestPaths to avoid the new open source miss the new log ...
3.68
hbase_HbckTableInfo_handleRegionStartKeyNotEmpty
/** * This is a special case hole -- when the first region of a table is missing from META, HBase * doesn't acknowledge the existance of the table. */ @Override public void handleRegionStartKeyNotEmpty(HbckRegionInfo next) throws IOException { errors.reportError(HbckErrorReporter.ERROR_CODE.FIRST_REGION_STARTKEY_N...
3.68
shardingsphere-elasticjob_LeaderService_isLeaderUntilBlock
/** * Judge current server is leader or not. * * <p> * If leader is electing, this method will block until leader elected success. * </p> * * @return current server is leader or not */ public boolean isLeaderUntilBlock() { while (!hasLeader() && serverService.hasAvailableServers()) { log.info("Lea...
3.68
hbase_ProcedureEvent_wake
/** * Wakes up the suspended procedures by pushing them back into scheduler queues and sets the event * as ready. See {@link #wakeInternal(AbstractProcedureScheduler)} for why this is not * synchronized. */ public void wake(AbstractProcedureScheduler procedureScheduler) { procedureScheduler.wakeEvents(new Procedu...
3.68
hbase_Get_familySet
/** * Method for retrieving the keys in the familyMap * @return keys in the current familyMap */ public Set<byte[]> familySet() { return this.familyMap.keySet(); }
3.68
hbase_ExplicitColumnTracker_done
/** * Done when there are no more columns to match against. */ @Override public boolean done() { return this.index >= columns.length; }
3.68
hadoop_AbfsOutputStreamStatisticsImpl_writeCurrentBuffer
/** * {@inheritDoc} * * Records the number of times AbfsOutputStream writes the buffer to the * service via the AbfsClient and appends the buffer to the service. */ @Override public void writeCurrentBuffer() { writeCurrentBufferOps.incrementAndGet(); }
3.68
hadoop_FederationApplicationHomeSubClusterStoreInputValidator_checkApplicationHomeSubCluster
/** * Validate if the ApplicationHomeSubCluster info are present or not. * * @param applicationHomeSubCluster the information of the application to be * verified * @throws FederationStateStoreInvalidInputException if the SubCluster Info * are invalid */ private static void checkApplicationHome...
3.68
druid_MySqlStatementParser_parseDeclare
/** * parse declare statement */ public SQLStatement parseDeclare() { Lexer.SavePoint savePoint = lexer.markOut(); lexer.nextToken(); if (lexer.token() == Token.CONTINUE) { lexer.reset(savePoint); return this.parseDeclareHandler(); } lexer.nextToken(); if (lexer.token() == T...
3.68
flink_MethodlessRouter_anyMatched
/** Checks if there's any matching route. */ public boolean anyMatched(String[] requestPathTokens) { Map<String, String> pathParams = new HashMap<>(); for (PathPattern pattern : routes.keySet()) { if (pattern.match(requestPathTokens, pathParams)) { return true; } // Reset fo...
3.68
framework_TableElement_getCell
/** * Function to find a Table cell. Looking for a cell that is currently not * visible will throw NoSuchElementException * * @param row * 0 based row index * @param column * 0 based column index * @return TestBenchElement containing wanted cell. * @throws NoSuchElementException * ...
3.68
hadoop_RouterQuotaUsage_verifyStoragespaceQuota
/** * Verify if storage space quota is violated once quota is set. Relevant * method {@link DirectoryWithQuotaFeature#verifyStoragespaceQuota}. * @throws DSQuotaExceededException If the quota is exceeded. */ public void verifyStoragespaceQuota() throws DSQuotaExceededException { long spaceQuota = getSpaceQuota();...
3.68
framework_AbsoluteLayout_getCSSString
/** * Converts the internal values into a valid CSS string. * * @return A valid CSS string */ public String getCSSString() { String s = ""; if (topValue != null) { s += "top:" + topValue + topUnits.getSymbol() + ";"; } if (rightValue != null) { s += "right:" + rightValue + rightUnits...
3.68
flink_HiveCatalog_retrieveFlinkProperties
/** Filter out Hive-created properties, and return Flink-created properties. */ private static Map<String, String> retrieveFlinkProperties( Map<String, String> hiveTableParams) { return hiveTableParams.entrySet().stream() .filter(e -> e.getKey().startsWith(FLINK_PROPERTY_PREFIX)) .co...
3.68
hbase_TableRegionModel_setName
/** * @param name region printable name */ public void setName(String name) { String split[] = name.split(","); this.table = split[0]; this.startKey = Bytes.toBytes(split[1]); String tail = split[2]; split = tail.split("\\."); id = Long.parseLong(split[0]); }
3.68
flink_IOUtils_readFully
/** * Reads len bytes in a loop. * * @param in The InputStream to read from * @param buf The buffer to fill * @param off offset from the buffer * @param len the length of bytes to read * @throws IOException if it could not read requested number of bytes for any reason (including * EOF) */ public static voi...
3.68
flink_ListElement_list
/** * Creates a list with blocks of text. For example: * * <pre>{@code * .list( * text("this is first element of list"), * text("this is second element of list with a %s", link("https://link")) * ) * }</pre> * * @param elements list of this list entries * @return list representation */ public static ListE...
3.68