name stringlengths 12 178 | code_snippet stringlengths 8 36.5k | score float64 3.26 3.68 |
|---|---|---|
morf_AbstractSqlDialectTest_testRenameTableStatements | /**
* Tests that the syntax is correct for renaming a table.
*/
@SuppressWarnings("unchecked")
@Test
public void testRenameTableStatements() {
Table fromTable = metadata.getTable(TEST_TABLE);
Table renamed = table("Renamed")
.columns(
idColumn(),
versionColumn(),
column(STRING_FIELD, DataType.STRIN... | 3.68 |
framework_EventRouter_getListeners | /**
* Returns all listeners that match or extend the given event type.
*
* @param eventType
* The type of event to return listeners for.
* @return A collection with all registered listeners. Empty if no listeners
* are found.
*/
public Collection<?> getListeners(Class<?> eventType) {
List<... | 3.68 |
flink_DataStreamUtils_collectWithClient | /**
* Starts the execution of the program and returns an iterator to read the result of the given
* data stream, plus a {@link JobClient} to interact with the application execution.
*
* @deprecated Please use {@link DataStream#executeAndCollect()}.
*/
@Deprecated
public static <OUT> ClientAndIterator<OUT> collectW... | 3.68 |
hadoop_AbfsLease_free | /**
* Cancel future and free the lease. If an exception occurs while releasing the lease, the error
* will be logged. If the lease cannot be released, AzureBlobFileSystem breakLease will need to
* be called before another client will be able to write to the file.
*/
public void free() {
if (leaseFreed) {
retu... | 3.68 |
hadoop_DatanodeVolumeInfo_getStorageType | /**
* get storage type.
*/
public StorageType getStorageType() {
return storageType;
} | 3.68 |
framework_DateCellDayEvent_getDatesWidth | /* Returns total width of all date cells. */
private int getDatesWidth() {
if (weekGrid.width == -1) {
// Undefined width. Needs to be calculated by the known cell
// widths.
int count = weekGrid.content.getWidgetCount() - 1;
return count * getDateCellWidth();
}
return weekG... | 3.68 |
hibernate-validator_Mod10CheckValidator_isCheckDigitValid | /**
* Validate check digit using Mod10
*
* @param digits The digits over which to calculate the checksum
* @param checkDigit the check digit
*
* @return {@code true} if the mod 10 result matches the check digit, {@code false} otherwise
*/
@Override
public boolean isCheckDigitValid(List<Integer> digits, char chec... | 3.68 |
framework_LocaleService_getState | /**
* Returns the state for this service
* <p>
* The state is transmitted inside the UI state rather than as an individual
* entity.
* </p>
*
* @since 7.1
* @param markAsDirty
* true to mark the state as dirty
* @return a LocaleServiceState object that can be read in any case and
* modifie... | 3.68 |
hadoop_XDR_writeMessageUdp | /**
* Write an XDR message to a UDP ChannelBuffer.
* @param response XDR response
* @return UDP buffer
*/
public static ByteBuf writeMessageUdp(XDR response) {
Preconditions.checkState(response.state == XDR.State.READING);
// TODO: Investigate whether making a copy of the buffer is necessary.
return Unpooled.... | 3.68 |
flink_MemoryUtils_allocateUnsafe | /**
* Allocates unsafe native memory.
*
* @param size size of the unsafe memory to allocate.
* @return address of the allocated unsafe memory
*/
static long allocateUnsafe(long size) {
return UNSAFE.allocateMemory(Math.max(1L, size));
} | 3.68 |
framework_FieldGroup_isModified | /**
* Checks if any bound field has been modified.
*
* @return true if at least one field has been modified, false otherwise
*/
public boolean isModified() {
for (Field<?> field : getFields()) {
if (field.isModified()) {
return true;
}
}
return false;
} | 3.68 |
framework_AbstractInMemoryContainer_removeFilters | /**
* Remove all container filters for a given property identifier and
* re-filter the view. This also removes filters applying to multiple
* properties including the one identified by propertyId.
*
* This can be used to implement
* {@link Filterable#removeContainerFilters(Object)}.
*
* @param propertyId
* @re... | 3.68 |
hbase_AuthUtil_loginClientAsService | /**
* For kerberized cluster, return login user (from kinit or from keytab). Principal should be the
* following format: name/fully.qualified.domain.name@REALM. For non-kerberized cluster, return
* system user.
* <p>
* NOT recommend to use to method unless you're sure what you're doing, it is for canary only.
* P... | 3.68 |
hbase_ReplicationStorageFactory_getReplicationPeerStorage | /**
* Create a new {@link ReplicationPeerStorage}.
*/
public static ReplicationPeerStorage getReplicationPeerStorage(FileSystem fs, ZKWatcher zk,
Configuration conf) {
Class<? extends ReplicationPeerStorage> clazz = getReplicationPeerStorageClass(conf);
for (Constructor<?> c : clazz.getConstructors()) {
if ... | 3.68 |
flink_WindowedStateTransformation_process | /**
* Applies the given window function to each window. The window function is called for each
* evaluation of the window for each key individually. The output of the window function is
* interpreted as a regular non-windowed stream.
*
* <p>Note that this function requires that all data in the windows is buffered ... | 3.68 |
hbase_MasterObserver_preBalance | /**
* Called prior to requesting rebalancing of the cluster regions, though after the initial checks
* for regions in transition and the balance switch flag.
* @param ctx the environment to interact with the framework and master
* @param request the request used to trigger the balancer
*/
default void preBalan... | 3.68 |
hbase_TableMapReduceUtil_limitNumReduceTasks | /**
* Ensures that the given number of reduce tasks for the given job configuration does not exceed
* the number of regions for the given table.
* @param table The table to get the region count for.
* @param job The current job to adjust.
* @throws IOException When retrieving the table details fails.
*/
public ... | 3.68 |
framework_Link_setTargetHeight | /**
* Sets the target window height.
*
* @param targetHeight
* the targetHeight to set.
*/
public void setTargetHeight(int targetHeight) {
getState().targetHeight = targetHeight;
} | 3.68 |
flink_SupportsFilterPushDown_of | /**
* Constructs a filter push-down result.
*
* <p>See the documentation of {@link SupportsFilterPushDown} for more information.
*
* @param acceptedFilters filters that are consumed by the source but may be applied on a
* best effort basis
* @param remainingFilters filters that a subsequent filter operation ... | 3.68 |
hbase_MasterObserver_postCompletedDeleteTableAction | /**
* Called after {@link org.apache.hadoop.hbase.master.HMaster} deletes a table. Called as part of
* delete table procedure and it is async to the delete RPC call.
* @param ctx the environment to interact with the framework and master
* @param tableName the name of the table
*/
default void postCompletedDe... | 3.68 |
Activiti_SpringAsyncExecutor_setRejectedJobsHandler | /**
* Required spring injected {@link SpringRejectedJobsHandler} implementation that will be used when jobs were rejected by the task executor.
*
* @param rejectedJobsHandler
*/
public void setRejectedJobsHandler(SpringRejectedJobsHandler rejectedJobsHandler) {
this.rejectedJobsHandler = rejectedJobsHandler;
} | 3.68 |
hmily_LogUtil_info | /**
* Info.
*
* @param logger the logger
* @param supplier the supplier
*/
public static void info(final Logger logger, final Supplier<Object> supplier) {
if (logger.isInfoEnabled()) {
logger.info(Objects.toString(supplier.get()));
}
} | 3.68 |
hadoop_StagingCommitter_deleteDestinationPaths | /**
* Delete the working paths of a job.
* <ol>
* <li>{@code $dest/__temporary}</li>
* <li>the local working directory for staged files</li>
* </ol>
* Does not attempt to clean up the work of the wrapped committer.
* @param context job context
* @throws IOException IO failure
*/
protected void deleteDestin... | 3.68 |
flink_BinarySegmentUtils_setFloat | /**
* set float from segments.
*
* @param segments target segments.
* @param offset value offset.
*/
public static void setFloat(MemorySegment[] segments, int offset, float value) {
if (inFirstSegment(segments, offset, 4)) {
segments[0].putFloat(offset, value);
} else {
setFloatMultiSegment... | 3.68 |
flink_ByteParser_parseField | /**
* Static utility to parse a field of type byte from a byte sequence that represents text
* characters (such as when read from a file stream).
*
* @param bytes The bytes containing the text data that should be parsed.
* @param startPos The offset to start the parsing.
* @param length The length of the byte seq... | 3.68 |
hadoop_ExitUtil_terminateCalled | /**
* @return true if terminate has been called.
*/
public static boolean terminateCalled() {
// Either we set this member or we actually called System#exit
return FIRST_EXIT_EXCEPTION.get() != null;
} | 3.68 |
hbase_RegionStates_getRegionStates | /** Returns A snapshot of region state nodes for all the regions. */
public ArrayList<RegionState> getRegionStates() {
final ArrayList<RegionState> regions = new ArrayList<>(regionsMap.size());
for (RegionStateNode node : regionsMap.values()) {
regions.add(node.toRegionState());
}
return regions;
} | 3.68 |
hbase_OrderedBytes_isNull | /**
* Return true when the next encoded value in {@code src} is null, false otherwise.
*/
public static boolean isNull(PositionedByteRange src) {
return NULL == (-1 == Integer.signum(src.peek()) ? DESCENDING : ASCENDING).apply(src.peek());
} | 3.68 |
hbase_HBaseTestingUtility_getRSForFirstRegionInTable | /**
* Tool to get the reference to the region server object that holds the region of the specified
* user table.
* @param tableName user table to lookup in hbase:meta
* @return region server that holds it, null if the row doesn't exist
*/
public HRegionServer getRSForFirstRegionInTable(TableName tableName)
throw... | 3.68 |
dubbo_ApolloDynamicConfiguration_addListener | /**
* Since all governance rules will lay under dubbo group, this method now always uses the default dubboConfig and
* ignores the group parameter.
*/
@Override
public void addListener(String key, String group, ConfigurationListener listener) {
ApolloListener apolloListener = listeners.computeIfAbsent(group + ke... | 3.68 |
hbase_Encryption_pbkdf128 | /**
* Return a 128 bit key derived from the concatenation of the supplied arguments using
* PBKDF2WithHmacSHA1 at 10,000 iterations.
*/
public static byte[] pbkdf128(byte[]... args) {
StringBuilder sb = new StringBuilder();
for (byte[] b : args) {
sb.append(Arrays.toString(b));
}
return generateSecretKey... | 3.68 |
hadoop_InputWriter_initialize | /**
* Initializes the InputWriter. This method has to be called before calling
* any of the other methods.
*/
public void initialize(PipeMapRed pipeMapRed) throws IOException {
// nothing here yet, but that might change in the future
} | 3.68 |
hbase_BloomFilterMetrics_getEligibleRequestsCount | /**
* Returns Current value for requests which could have used bloom filters but wasn't defined or
* loaded.
*/
public long getEligibleRequestsCount() {
return eligibleRequests.sum();
} | 3.68 |
hbase_FavoredNodeAssignmentHelper_getFavoredNodesList | /**
* Convert PB bytes to ServerName.
* @param favoredNodes The PB'ed bytes of favored nodes
* @return the array of {@link ServerName} for the byte array of favored nodes.
*/
public static ServerName[] getFavoredNodesList(byte[] favoredNodes) throws IOException {
FavoredNodes f = FavoredNodes.parseFrom(favoredNod... | 3.68 |
flink_Tuple8_of | /**
* Creates a new tuple and assigns the given values to the tuple's fields. This is more
* convenient than using the constructor, because the compiler can infer the generic type
* arguments implicitly. For example: {@code Tuple3.of(n, x, s)} instead of {@code new
* Tuple3<Integer, Double, String>(n, x, s)}
*/
pu... | 3.68 |
hadoop_XFrameOptionsFilter_getFilterParams | /**
* Constructs a mapping of configuration properties to be used for filter
* initialization. The mapping includes all properties that start with the
* specified configuration prefix. Property names in the mapping are trimmed
* to remove the configuration prefix.
*
* @param conf configuration to read
* @param... | 3.68 |
dubbo_MethodConfig_constructMethodConfig | /**
* TODO remove constructMethodConfig
*
* @param methods
* @return
*/
@Deprecated
public static List<MethodConfig> constructMethodConfig(Method[] methods) {
if (methods != null && methods.length != 0) {
List<MethodConfig> methodConfigs = new ArrayList<>(methods.length);
for (int i = 0; i < me... | 3.68 |
flink_ExecutionEnvironment_createInput | /**
* Generic method to create an input DataSet with in {@link InputFormat}. The {@link DataSet}
* will not be immediately created - instead, this method returns a {@link DataSet} that will be
* lazily created from the input format once the program is executed.
*
* <p>The {@link DataSet} is typed to the given Type... | 3.68 |
hbase_HFileBlockIndex_getEntryBySubEntry | /**
* Finds the entry corresponding to the deeper-level index block containing the given
* deeper-level entry (a "sub-entry"), assuming a global 0-based ordering of sub-entries.
* <p>
* <i> Implementation note. </i> We are looking for i such that numSubEntriesAt[i - 1] <= k <
* numSubEntriesAt[i], because a deeper... | 3.68 |
morf_AliasedField_in | /**
* @param values The values for comparison
* @return The resulting {@link Criterion}.
*/
public Criterion in(Iterable<? extends Object> values) {
return Criterion.in(this, values);
} | 3.68 |
Activiti_BpmnDeploymentHelper_verifyProcessDefinitionsDoNotShareKeys | /**
* Verifies that no two process definitions share the same key, to prevent database unique
* index violation.
*
* @throws ActivitiException if any two processes have the same key
*/
public void verifyProcessDefinitionsDoNotShareKeys(
Collection<ProcessDefinitionEntity> processDefinitions) {
Set<String> ke... | 3.68 |
hbase_CacheableDeserializerIdManager_getDeserializer | /**
* Get the cacheable deserializer registered at the given identifier Id.
* @see #registerDeserializer(CacheableDeserializer)
*/
public static CacheableDeserializer<Cacheable> getDeserializer(int id) {
return registeredDeserializers.get(id);
} | 3.68 |
flink_LongParser_parseField | /**
* Static utility to parse a field of type long from a byte sequence that represents text
* characters (such as when read from a file stream).
*
* @param bytes The bytes containing the text data that should be parsed.
* @param startPos The offset to start the parsing.
* @param length The length of the byte seq... | 3.68 |
hbase_ParseFilter_checkForSkip | /**
* Checks if the current index of filter string we are on is the beginning of the keyword 'SKIP'
* <p>
* @param filterStringAsByteArray filter string given by the user
* @param indexOfSkip index at which an 'S' was read
* @return true if the keyword 'SKIP' is at the current index
*/
public static b... | 3.68 |
hbase_SaslClientAuthenticationProviders_getInstance | /**
* Returns a singleton instance of {@link SaslClientAuthenticationProviders}.
*/
public static synchronized SaslClientAuthenticationProviders getInstance(Configuration conf) {
SaslClientAuthenticationProviders providers = providersRef.get();
if (providers == null) {
providers = instantiate(conf);
provi... | 3.68 |
flink_Pool_tryPollEntry | /** Tries to get the next cached entry. If the pool is empty, this method returns null. */
@Nullable
public T tryPollEntry() {
return pool.poll();
} | 3.68 |
graphhopper_HeadingResolver_getEdgesWithDifferentHeading | /**
* Returns a list of edge IDs of edges adjacent to the given base node that do *not* have the same or a similar
* heading as the given heading. If for example the tolerance is 45 degrees this method returns all edges for which
* the absolute difference to the given heading is greater than 45 degrees. The heading ... | 3.68 |
framework_TreeGridElement_isRowExpanded | /**
* Returns whether the row at the given index is expanded or not.
*
* @param rowIndex
* 0-based row index
* @param hierarchyColumnIndex
* 0-based index of the hierarchy column
* @return {@code true} if expanded, {@code false} if collapsed
*/
public boolean isRowExpanded(int rowIndex, in... | 3.68 |
hadoop_SCMController_overview | /**
* It is referenced in SCMWebServer.SCMWebApp.setup()
*/
@SuppressWarnings("unused")
public void overview() {
render(SCMOverviewPage.class);
} | 3.68 |
streampipes_NumWordsRulesClassifier_getInstance | /**
* Returns the singleton instance for RulebasedBoilerpipeClassifier.
*/
public static NumWordsRulesClassifier getInstance() {
return INSTANCE;
} | 3.68 |
hadoop_HistoryServerStateStoreService_serviceInit | /**
* Initialize the state storage
*
* @param conf the configuration
* @throws IOException
*/
@Override
public void serviceInit(Configuration conf) throws IOException {
initStorage(conf);
} | 3.68 |
querydsl_JTSGeometryExpression_crosses | /**
* Returns 1 (TRUE) if this geometric object “spatially crosses’ anotherGeometry.
*
* @param geometry other geometry
* @return true, if crosses
*/
public BooleanExpression crosses(Expression<? extends Geometry> geometry) {
return Expressions.booleanOperation(SpatialOps.CROSSES, mixin, geometry);
} | 3.68 |
hudi_HoodieReaderContext_generateMetadataForRecord | /**
* Generates metadata of the record. Only fetches record key that is necessary for merging.
*
* @param record The record.
* @param schema The Avro schema of the record.
* @return A mapping containing the metadata.
*/
public Map<String, Object> generateMetadataForRecord(T record, Schema schema) {
Map<String, ... | 3.68 |
flink_InputChannel_getCurrentBackoff | /** Returns the current backoff in ms. */
protected int getCurrentBackoff() {
return currentBackoff <= 0 ? 0 : currentBackoff;
} | 3.68 |
hadoop_RouterRMAdminService_finalize | /**
* Shutdown the chain of interceptors when the object is destroyed.
*/
@Override
protected void finalize() {
rootInterceptor.shutdown();
} | 3.68 |
hadoop_SlowPeerReports_equals | /**
* Return true if the two objects represent the same set slow peer
* entries. Primarily for unit testing convenience.
*/
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (!(o instanceof SlowPeerReports)) {
return false;
}
SlowPeerReports that = (SlowPeerReports) o... | 3.68 |
streampipes_MqttClient_createMqttClient | /**
* Create new MQTT client
*/
public void createMqttClient() {
this.mqtt = new MQTT();
this.uri = MqttUtils.makeMqttServerUri(options.getProtocol(), options.getHost(), options.getPort());
try {
/**
* Sets the url for connecting to the MQTT broker, e.g. {@code: tcp://localhost:1883}.
*/
mqtt.... | 3.68 |
flink_SharedReference_applySync | /**
* Executes the code on the referenced object in a synchronized fashion. Note that this method
* is prone to deadlock if multiple references are accessed in a synchronized fashion in a
* nested call-chain.
*/
default <R> R applySync(Function<T, R> function) {
T object = get();
synchronized (object) {
... | 3.68 |
hibernate-validator_AnnotationApiHelper_isClass | /**
* Test if the given {@link TypeMirror} represents a class or not.
*/
public boolean isClass(TypeMirror typeMirror) {
return TypeKind.DECLARED.equals( typeMirror.getKind() ) && ( (DeclaredType) typeMirror ).asElement().getKind().isClass();
} | 3.68 |
hbase_CanaryTool_newMonitor | /**
* A Factory method for {@link Monitor}. Makes a RegionServerMonitor, or a ZooKeeperMonitor, or a
* RegionMonitor.
* @return a Monitor instance
*/
private Monitor newMonitor(final Connection connection, String[] monitorTargets) {
Monitor monitor;
boolean useRegExp = conf.getBoolean(HBASE_CANARY_USE_REGEX, fa... | 3.68 |
flink_StreamTableSinkFactory_createStreamTableSink | /**
* Creates and configures a {@link StreamTableSink} using the given properties.
*
* @param properties normalized properties describing a table sink.
* @return the configured table sink.
* @deprecated {@link Context} contains more information, and already contains table schema too.
* Please use {@link #crea... | 3.68 |
hadoop_BaseNMTokenSecretManager_createNMToken | /**
* Helper function for creating NMTokens.
*
* @param applicationAttemptId application AttemptId.
* @param nodeId node Id.
* @param applicationSubmitter application Submitter.
* @return NMToken.
*/
public Token createNMToken(ApplicationAttemptId applicationAttemptId,
NodeId nodeId, String applicationSubmit... | 3.68 |
hadoop_StreamXmlRecordReader_nextState | /* also updates firstMatchStart_; */
int nextState(int state, int input, int bufPos) {
switch (state) {
case CDATA_UNK:
case CDATA_OUT:
switch (input) {
case CDATA_BEGIN:
return CDATA_IN;
case CDATA_END:
if (state == CDATA_OUT) {
// System.out.println("buggy XML " + bufPos);
... | 3.68 |
framework_RendererCellReference_getElement | /**
* Returns the element of the cell. Can be either a <code>TD</code> element
* or a <code>TH</code> element.
*
* @return the element of the cell
*/
@Override
public TableCellElement getElement() {
return cell.getElement();
} | 3.68 |
hadoop_SelectBinding_isSelectEnabled | /**
* Static probe for select being enabled.
* @param conf configuration
* @return true iff select is enabled.
*/
public static boolean isSelectEnabled(Configuration conf) {
return conf.getBoolean(FS_S3A_SELECT_ENABLED, true);
} | 3.68 |
hbase_SizeCachedByteBufferKeyValue_getSerializedSize | /**
* Override by just returning the length for saving cost of method dispatching. If not, it will
* call {@link ExtendedCell#getSerializedSize()} firstly, then forward to
* {@link SizeCachedKeyValue#getSerializedSize(boolean)}. (See HBASE-21657)
*/
@Override
public int getSerializedSize() {
return this.length;
} | 3.68 |
hadoop_AbfsClient_getDirectoryQueryParameter | /**
* Get the directory query parameter used by the List Paths REST API and used
* as the path in the continuation token. If the input path is null or the
* root path "/", empty string is returned. If the input path begins with '/',
* the return value is the substring beginning at offset 1. Otherwise, the
* inpu... | 3.68 |
dubbo_RpcServiceContext_getRemoteHost | /**
* get remote host.
*
* @return remote host
*/
@Override
public String getRemoteHost() {
return remoteAddress == null
? null
: remoteAddress.getAddress() == null
? remoteAddress.getHostName()
: NetUtils.filterLocalHost(remoteAddress.getAddress()... | 3.68 |
pulsar_ProducerImpl_recoverChecksumError | /**
* Checks message checksum to retry if message was corrupted while sending to broker. Recomputes checksum of the
* message header-payload again.
* <ul>
* <li><b>if matches with existing checksum</b>: it means message was corrupt while sending to broker. So, resend
* message</li>
* <li><b>if doesn't match with ... | 3.68 |
flink_UserDefinedFunctionHelper_getReturnTypeOfTableFunction | /**
* Tries to infer the TypeInformation of an AggregateFunction's accumulator type.
*
* @param tableFunction The TableFunction for which the accumulator type is inferred.
* @param scalaType The implicitly inferred type of the accumulator type.
* @return The inferred accumulator type of the AggregateFunction.
*/
... | 3.68 |
framework_MultiSelectionModelConnector_createSelectionModel | /**
* Creates an instance of MultiSelectionModel. Method provided overriding
* features of the selection model without copying all logic.
*
* @since 8.1
*
* @return selection model instance, not {@code null}
*/
protected MultiSelectionModel createSelectionModel() {
return new MultiSelectionModel();
} | 3.68 |
querydsl_AbstractSQLQuery_forShare | /**
* FOR SHARE causes the rows retrieved by the SELECT statement to be locked as though for update.
*
* Supported by MySQL, PostgreSQL, SQLServer.
*
* @param fallbackToForUpdate
* if the FOR SHARE is not supported and this parameter is <code>true</code>, the
* {@link #forUpdate()} functionalit... | 3.68 |
framework_HierarchyMapper_isExpanded | /**
* Returns whether the given item is expanded.
*
* @param item
* the item to test
* @return {@code true} if item is expanded; {@code false} if not
*/
public boolean isExpanded(T item) {
if (item == null) {
// Root nodes are always visible.
return true;
}
return expandedIt... | 3.68 |
hmily_ConfigLoader_getOriginal | /**
* Gets original.
*
* @return the original
*/
public ConfigLoader<Config> getOriginal() {
return original;
} | 3.68 |
flink_StateTableByKeyGroupReaders_readerForVersion | /**
* Creates a new StateTableByKeyGroupReader that inserts de-serialized mappings into the given
* table, using the de-serialization algorithm that matches the given version.
*
* @param <K> type of key.
* @param <N> type of namespace.
* @param <S> type of state.
* @param stateTable the {@link StateTable} into w... | 3.68 |
dubbo_StandardMetadataServiceURLBuilder_build | /**
* Build the {@link URL urls} from {@link ServiceInstance#getMetadata() the metadata} of {@link ServiceInstance}
*
* @param serviceInstance {@link ServiceInstance}
* @return the not-null {@link List}
*/
@Override
public List<URL> build(ServiceInstance serviceInstance) {
Map<String, String> paramsMap = getMe... | 3.68 |
hbase_AbstractFSWAL_tellListenersAboutPostLogRoll | /**
* Tell listeners about post log roll.
*/
private void tellListenersAboutPostLogRoll(final Path oldPath, final Path newPath)
throws IOException {
if (!this.listeners.isEmpty()) {
for (WALActionsListener i : this.listeners) {
i.postLogRoll(oldPath, newPath);
}
}
coprocessorHost.postWALRoll(ol... | 3.68 |
streampipes_AbstractProcessingElementBuilder_supportedFormats | /**
* Assigns supported transport formats to the pipeline elements that can be handled at runtime (e.g.,
* JSON or XMl).
*
* @param formats A list of supported {@link org.apache.streampipes.model.grounding.TransportFormat}s. Use
* {@link org.apache.streampipes.sdk.helpers.SupportedFormats} to assign... | 3.68 |
morf_OracleDialect_dropPrimaryKeyConstraint | /**
* ALTER TABLE ABC.DEF DROP PRIMARY KEY DROP INDEX
*/
private String dropPrimaryKeyConstraint(String tableName) {
// Drop the associated unique index at the same time
return "ALTER TABLE " + schemaNamePrefix() + tableName + " DROP PRIMARY KEY DROP INDEX";
} | 3.68 |
dubbo_ProviderConfig_getDispather | /**
* typo, switch to use {@link #getDispatcher()}
*
* @deprecated {@link #getDispatcher()}
*/
@Deprecated
@Parameter(excluded = true, attribute = false)
public String getDispather() {
return getDispatcher();
} | 3.68 |
hbase_ScannerContext_getKeepProgress | /**
* @return true if the progress tracked so far in this instance will be considered during an
* invocation of {@link InternalScanner#next(java.util.List)} or
* {@link RegionScanner#next(java.util.List)}. false when the progress tracked so far
* should not be considered and should instead b... | 3.68 |
hudi_AvroSchemaConverter_convertToSchema | /**
* Converts Flink SQL {@link LogicalType} (can be nested) into an Avro schema.
*
* <p>The "{rowName}." is used as the nested row type name prefix in order to generate the right
* schema. Nested record type that only differs with type name is still compatible.
*
* @param logicalType logical type
* @param rowNa... | 3.68 |
hadoop_DockerContainerDeletionTask_convertDeletionTaskToProto | /**
* Convert the DockerContainerDeletionTask to the Protobuf representation for
* storing in the state store and recovery.
*
* @return the protobuf representation of the DockerContainerDeletionTask.
*/
public DeletionServiceDeleteTaskProto convertDeletionTaskToProto() {
DeletionServiceDeleteTaskProto.Builder bu... | 3.68 |
morf_DataValueLookupBuilderImpl_set | /**
* Sets the value of a specified column. Resizes or allocates the array as required.
*/
private DataValueLookupBuilder set(String columnName, Object value) {
CaseInsensitiveString key = CaseInsensitiveString.of(columnName);
// No data yet - initialise
if (metadata == null) {
metadata = DataValueLookupM... | 3.68 |
hmily_HmilyXaResource_forget | /**
* Forget.
*
* @throws XAException the xa exception
*/
public void forget() throws XAException {
this.forget(this.xid);
} | 3.68 |
hadoop_VolumeStates_addVolumeIfAbsent | /**
* Add volume if it is not yet added.
* If a new volume is added with a same {@link VolumeId}
* with a existing volume, existing volume will be returned.
* @param volume volume to add
* @return volume added or existing volume
*/
public Volume addVolumeIfAbsent(Volume volume) {
if (volume.getVolumeId() != nul... | 3.68 |
rocketmq-connect_RocketMQSourceValueConverter_convertKafkaValue | /**
* convert value
*
* @param targetSchema
* @param originalValue
* @return
*/
private Object convertKafkaValue(Schema targetSchema, Object originalValue) {
if (targetSchema == null) {
if (originalValue == null) {
return null;
}
return originalValue;
}
switch (tar... | 3.68 |
hadoop_ClusterMetrics_getReservedReduceSlots | /**
* Get the number of reserved reduce slots in the cluster.
*
* @return reserved reduce slot count
*/
public int getReservedReduceSlots() {
return reservedReduceSlots;
} | 3.68 |
pulsar_ResourceGroup_rgFillResourceUsage | // Transport manager mandated op.
public void rgFillResourceUsage(ResourceUsage resourceUsage) {
NetworkUsage p;
resourceUsage.setOwner(this.getID());
p = resourceUsage.setPublish();
this.setUsageInMonitoredEntity(ResourceGroupMonitoringClass.Publish, p);
p = resourceUsage.setDispatch();
this.... | 3.68 |
morf_AbstractSqlDialectTest_testInsertWithNullDefaults | /**
* Test that an Insert statement is generated with a null value
*/
@Test
public void testInsertWithNullDefaults() {
InsertStatement stmt = new InsertStatement().into(new TableReference(TEST_TABLE))
.from(new TableReference(OTHER_TABLE)).withDefaults(
new NullFieldLiteral().as(DATE_FIELD),
n... | 3.68 |
flink_MemorySegment_getCharBigEndian | /**
* Reads a character value (16 bit, 2 bytes) from the given position, in big-endian byte order.
* This method's speed depends on the system's native byte order, and it is possibly slower than
* {@link #getChar(int)}. For most cases (such as transient storage in memory or serialization
* for I/O and network), it ... | 3.68 |
hbase_HBaseTestingUtility_getBaseTestDirOnTestFS | /**
* @return Where to write test data on the test filesystem; Returns working directory for the test
* filesystem by default
* @see #setupDataTestDirOnTestFS()
* @see #getTestFileSystem()
*/
private Path getBaseTestDirOnTestFS() throws IOException {
FileSystem fs = getTestFileSystem();
return new Path... | 3.68 |
hbase_HFileBlockIndex_getRootBlockOffset | /**
* @param i from 0 to {@link #getRootBlockCount() - 1}
*/
public long getRootBlockOffset(int i) {
return blockOffsets[i];
} | 3.68 |
morf_SpreadsheetDataSetProducer_createRecord | /**
* Creates a record from a set of cells from a worksheet.
*
* @param id ID of the row
* @param columnHeadingsMap Map of column headings to their index
* @param translationColumn Column containing translations
* @param cells The cells to process
* @return the created record
*/
private Record createRecord(fina... | 3.68 |
hadoop_FSTreeTraverser_resolvePaths | /**
* Resolve the cursor of traverse to an inode.
* <p>
* The parent of the lowest level startAfter is returned. If somewhere in the
* middle of startAfters changed, the parent of the lowest unchanged level is
* returned.
*
* @param startId
* Id of the start inode.
* @param startAfters
* the... | 3.68 |
graphhopper_Entity_writeDateField | /**
* Writes date as YYYYMMDD
*/
protected void writeDateField (LocalDate d) throws IOException {
writeStringField(d.format(DateTimeFormatter.BASIC_ISO_DATE));
} | 3.68 |
pulsar_AuthenticationDataProvider_getTlsCertificateFilePath | /**
* @return a client certificate file path
*/
default String getTlsCertificateFilePath() {
return null;
} | 3.68 |
open-banking-gateway_FintechConsentSpecSecureStorage_toInboxForAuth | /**
* Sends FinTech user keys to FinTech public key storage.
* @param authSession Authorization session associated with this user
* @param data FinTech users' private keys and other
*/
@SneakyThrows
public void toInboxForAuth(AuthSession authSession, FinTechUserInboxData data) {
try (OutputStream os = datasafeS... | 3.68 |
zxing_MinimalEncoder_getNumberOfC40Words | /** @return the number of words in which the string starting at from can be encoded in c40 or text mode.
* The number of characters encoded is returned in characterLength.
* The number of characters encoded is also minimal in the sense that the algorithm stops as soon
* as a character encoding fills a C40 word co... | 3.68 |
hbase_CellComparator_compareRows | /**
* Lexicographically compare two rows
* @param row ByteBuffer that wraps a row; will read from current position and will reading all
* remaining; will not disturb the ByteBuffer internal state.
* @return greater than 0 if leftCell is bigger, less than 0 if rightCell is bigger, 0 if both
* cel... | 3.68 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.