idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
494,891 | protected String arrayToString(Object o) {<NEW_LINE>int len = Array.getLength(o);<NEW_LINE>Class c = o.getClass().getComponentType();<NEW_LINE>String res = "[ ";<NEW_LINE>for (int i = 0; i < len; i++) {<NEW_LINE>if (c == byte.class)<NEW_LINE>res += Array.getByte(o, i);<NEW_LINE>if (c == boolean.class)<NEW_LINE>res += <... | Array.getBoolean(o, i); |
1,221,645 | public void onBindViewHolder(@NonNull final RecyclerView.ViewHolder holder, int position) {<NEW_LINE>if (holder instanceof HeaderViewHolder) {<NEW_LINE>Integer dateHeader = (Integer) getItem(position);<NEW_LINE>bindHeaderItem((HeaderViewHolder) holder, dateHeader, position);<NEW_LINE>} else if (holder instanceof TrackV... | !viewHolder.compoundButton.isChecked(); |
296,094 | public static void waitForRPDiscoveryToBeReady(TestSettings testSettings) throws Exception {<NEW_LINE>String thisMethod = "waitForRPDiscoveryToBeReady";<NEW_LINE>int maxAttempts = 5;<NEW_LINE>int tryNum = 1;<NEW_LINE>while (tryNum <= maxAttempts) {<NEW_LINE>WebConversation wc = new WebConversation();<NEW_LINE>WebReques... | response = wc.getResponse(request); |
1,688,570 | public int robotSim(int[] commands, int[][] obstacles) {<NEW_LINE>Set<String> set = new HashSet<String>();<NEW_LINE>for (int[] o : obstacles) set.add(o[0] + " " + o[1]);<NEW_LINE>int max = 0, x = 0, y = 0, dir = 0, dirs[][] = { { 0, 1 }, { 1, 0 }, { 0, -1 }, { -1, 0 } };<NEW_LINE>for (int c : commands) {<NEW_LINE>if (c... | == 0 ? 3 : dir - 1; |
619,663 | private void sendOnSnapshotError(String appName, int listenerId, Exception exception) {<NEW_LINE>WritableMap body = Arguments.createMap();<NEW_LINE>WritableMap error = Arguments.createMap();<NEW_LINE>if (exception instanceof FirebaseFirestoreException) {<NEW_LINE>UniversalFirebaseFirestoreException firestoreException =... | "message", firestoreException.getMessage()); |
461,573 | private int findMatch() {<NEW_LINE>int matched = 0;<NEW_LINE>int bankId = 0;<NEW_LINE>if (account != null) {<NEW_LINE>bankId = account.getC_Bank_ID();<NEW_LINE>}<NEW_LINE>List<MBankStatementMatcher> matchersList = MBankStatementMatcher.getMatchersList(Env.getCtx(), bankId);<NEW_LINE>if (matchersList == null) {<NEW_LINE... | setC_BPartner_ID(info.getC_BPartner_ID()); |
281,699 | void registerSingleType(DataType type) {<NEW_LINE>// built-in dynamic: Created on the fly<NEW_LINE>if (type instanceof TensorDataType)<NEW_LINE>return;<NEW_LINE>if (type instanceof TemporaryDataType) {<NEW_LINE>throw new IllegalArgumentException("TemporaryDataType no longer supported: " + type);<NEW_LINE>}<NEW_LINE>if ... | get(type.getId()); |
1,456,366 | protected void postProcess(BeanDefinitionBuilder builder, Element element, ParserContext parserContext) {<NEW_LINE>List<Element> mappingElements = DomUtils.getChildElementsByTagName(element, "mapping");<NEW_LINE>if (!CollectionUtils.isEmpty(mappingElements)) {<NEW_LINE>ManagedMap<String, String> channelMappings = new M... | , mappingElement.getAttribute("channel")); |
772,881 | final InitiateLayerUploadResult executeInitiateLayerUpload(InitiateLayerUploadRequest initiateLayerUploadRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(initiateLayerUploadRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | invoke(request, responseHandler, executionContext); |
31,271 | protected SrtpCryptoAttribute selectSdesCryptoSuite(boolean isInitiator, SDesControl sDesControl, MediaDescription mediaDescription) {<NEW_LINE>@SuppressWarnings("unchecked")<NEW_LINE>Vector<Attribute> attrs = mediaDescription.getAttributes(true);<NEW_LINE>Vector<SrtpCryptoAttribute> peerAttributes = new Vector<SrtpCry... | a = attrs.get(i); |
1,624,165 | private static Properties loadProperties() {<NEW_LINE>Properties saffronProperties = new Properties();<NEW_LINE>// Read properties from the file "saffron.properties", if it exists in classpath<NEW_LINE>try (InputStream stream = CalciteSystemProperty.class.getClassLoader().getResourceAsStream("saffron.properties")) {<NE... | throw new RuntimeException("while reading from saffron.properties file", e); |
1,055,835 | public PluginDescriptor find(Path pluginPath) {<NEW_LINE>for (PluginDescriptorFinder finder : finders) {<NEW_LINE>if (finder.isApplicable(pluginPath)) {<NEW_LINE>log.debug("'{}' is applicable for plugin '{}'", finder, pluginPath);<NEW_LINE>try {<NEW_LINE>PluginDescriptor pluginDescriptor = finder.find(pluginPath);<NEW_... | debug(e.getMessage()); |
1,041,835 | public void writeValue(int ex) {<NEW_LINE>double x = xyGraph.primaryXAxis.getPositionValue(ex, false);<NEW_LINE>int index = (int) x;<NEW_LINE>if (index < 0) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Sample sample = (Sample) trace.getDataProvider().getSample(index);<NEW_LINE>if (sample != null) {<NEW_LINE>double y = sample... | "Verdana", 10, SWT.BOLD); |
840,805 | public final // F49213<NEW_LINE>void formatTo(IncidentStream is) {<NEW_LINE>// -----------------------------------------------------------------------<NEW_LINE>// Indicate the start of the dump, and include the identity<NEW_LINE>// of InjectionProcessor, so this can easily be matched to a trace.<NEW_LINE>// -----------... | is.writeLine("", "All Bindings : "); |
917,290 | private Node withIpAssigned(Node node) {<NEW_LINE>if (!node.type().isHost()) {<NEW_LINE>return node.with(node.ipConfig().withPrimary(nameResolver.resolveAll(node.hostname())));<NEW_LINE>}<NEW_LINE>int hostIndex = Integer.parseInt(node.hostname().replaceAll("^[a-z]+|-\\d+$", ""));<NEW_LINE>Set<String> addresses = Set.of... | pool().withIpAddresses(ipAddressPool); |
1,016,214 | void assign(TaskRequest request) {<NEW_LINE>final TaskRequest.AssignedResources assignedResources = request.getAssignedResources();<NEW_LINE>if (assignedResources != null) {<NEW_LINE>final List<ConsumeResult> consumedNamedResources = assignedResources.getConsumedNamedResources();<NEW_LINE>if (consumedNamedResources != ... | int index = consumeResult.getIndex(); |
1,697,903 | public void afterPropertiesSet() {<NEW_LINE>Configuration<?> configuration;<NEW_LINE>if (this.providerClass != null) {<NEW_LINE>ProviderSpecificBootstrap bootstrap = Validation.byProvider(this.providerClass);<NEW_LINE>if (this.validationProviderResolver != null) {<NEW_LINE>bootstrap = bootstrap.providerResolver(this.va... | this.applicationContext.getAutowireCapableBeanFactory()); |
622,109 | protected JRFillCommonReturnValue addReturnValue(JRFillCommonReturnValue returnValue, List<JRFillCommonReturnValue> returnValueList, JRFillObjectFactory factory, BaseReportFiller filler) {<NEW_LINE>CalculationEnum calculation = returnValue.getCalculation();<NEW_LINE>switch(calculation) {<NEW_LINE>case AVERAGE:<NEW_LINE... | returnValue, "_VARIANCE", CalculationEnum.VARIANCE); |
415,429 | public IToken evaluate(ICharacterScanner scanner, boolean resume) {<NEW_LINE>// Should we try to match the first char first?<NEW_LINE>if (firstChar != Character.MIN_VALUE) {<NEW_LINE>int readChar = scanner.read();<NEW_LINE>scanner.unread();<NEW_LINE>if (readChar == ICharacterScanner.EOF) {<NEW_LINE>return Token.EOF;<NE... | () - match.length(); |
1,812,886 | // Not public<NEW_LINE>Collection<LifecycleQueryInstalledChaincodesProposalResponse> lifecycleQueryInstalledChaincodes(LifecycleQueryInstalledChaincodesRequest lifecycleQueryInstalledChaincodesRequest, Collection<Peer> peers) throws InvalidArgumentException, ProposalException {<NEW_LINE>logger.trace("LifecycleQueryInst... | qProposal, context, LifecycleQueryInstalledChaincodesProposalResponse.class); |
1,703,246 | public PutServiceQuotaIncreaseRequestIntoTemplateResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>PutServiceQuotaIncreaseRequestIntoTemplateResult putServiceQuotaIncreaseRequestIntoTemplateResult = new PutServiceQuotaIncreaseRequestIntoTemplateResult();<NEW_LINE>int originalDepth = context... | String currentParentElement = context.getCurrentParentElement(); |
184,357 | protected void textCharImpl(char ch, float x, float y) {<NEW_LINE>// , float z) {<NEW_LINE>PFont.Glyph glyph = textFont.getGlyph(ch);<NEW_LINE>if (glyph != null) {<NEW_LINE>if (textMode == MODEL) {<NEW_LINE>float floatSize = textFont.getSize();<NEW_LINE>float high = glyph.height / floatSize;<NEW_LINE>float wide = glyph... | float y1 = y - topExtent * textSize; |
1,237,619 | public static void main(String[] args) throws FileNotFoundException, IOException {<NEW_LINE>if (args.length < 1) {<NEW_LINE>System.out.println("Syntax: <in.mkv>\n" + "\tWhere:\n" + "\t<in.mkv>\tThe file to decode");<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>System.out.println("Read file: " + args[0]);<NEW_LINE>FileInputStre... | System.out.println(" - null (no metadata)"); |
1,675,228 | public HtmlResponse create(final CreateForm form) {<NEW_LINE>verifyCrudMode(form.crudMode, CrudMode.CREATE);<NEW_LINE>validate(form, messages -> {<NEW_LINE>}, this::asEditHtml);<NEW_LINE>validateFields(form, v -> throwValidationError<MASK><NEW_LINE>verifyToken(this::asEditHtml);<NEW_LINE>getDoc(form).ifPresent(entity -... | (v, this::asEditHtml)); |
824,190 | public List<ArchiveYearVO> convertToYearArchives(List<Post> posts) {<NEW_LINE>Map<Integer, List<Post>> yearPostMap = new HashMap<>(8);<NEW_LINE>posts.forEach(post -> {<NEW_LINE>Calendar calendar = DateUtils.<MASK><NEW_LINE>yearPostMap.computeIfAbsent(calendar.get(Calendar.YEAR), year -> new LinkedList<>()).add(post);<N... | convertTo(post.getCreateTime()); |
1,320,722 | public void configure() {<NEW_LINE>errorHandler(noErrorHandler());<NEW_LINE>from("{{" + ExternalSystemCamelConstants.MF_UPSERT_BPARTNER_LOCATION_V2_CAMEL_URI + "}}").routeId(ROUTE_ID).streamCaching().log("Route invoked!").process(exchange -> {<NEW_LINE>final var lookupRequest = exchange.getIn().getBody();<NEW_LINE>if (... | ().getName())); |
714,775 | private void createBugDialog(@NonNull MapActivity mapActivity, final boolean offline, String text, int titleTextId, int posButtonTextId, final Action action, final OpenStreetNote bug, OsmNotesPoint point) {<NEW_LINE>if (mapActivity.isFinishing()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (offline) {<NEW_LINE>mapActivit... | new OsmPoint[] { notesPoint }); |
1,724,816 | public void validate(final Processor<FullData, FullData> processor, final ProcessingReport report, final MessageBundle bundle, final FullData data) throws ProcessingException {<NEW_LINE>final JsonNode instance = data<MASK><NEW_LINE>final NodeType type = NodeType.getNodeType(instance);<NEW_LINE>if (types.contains(type))... | .getInstance().getNode(); |
1,267,053 | final GetFederationTokenResult executeGetFederationToken(GetFederationTokenRequest getFederationTokenRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getFederationTokenRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetri... | endClientExecution(awsRequestMetrics, request, response); |
284,422 | public OStorage fullSync(String dbName, String backupPath, OrientDBConfig config) {<NEW_LINE>final ODatabaseDocumentEmbedded embedded;<NEW_LINE>OAbstractPaginatedStorage storage = null;<NEW_LINE>synchronized (this) {<NEW_LINE>try {<NEW_LINE>storage = storages.get(dbName);<NEW_LINE>if (storage != null) {<NEW_LINE>OComma... | + dbName + "'"), e); |
1,318,843 | public void marshall(ReplicaSettingsUpdate replicaSettingsUpdate, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (replicaSettingsUpdate == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(replicaSettingsUpdate... | replicaSettingsUpdate.getReplicaGlobalSecondaryIndexSettingsUpdate(), REPLICAGLOBALSECONDARYINDEXSETTINGSUPDATE_BINDING); |
1,007,546 | public Stream<LongResult> neighborsAtHopCount(@Name("node") Node node, @Name(value = "types", defaultValue = "") String types, @Name(value = "distance", defaultValue = "1") Long distance) {<NEW_LINE>if (distance < 1)<NEW_LINE>return Stream.empty();<NEW_LINE>if (types == null || types.isEmpty())<NEW_LINE>return Stream.e... | [i] = new Roaring64NavigableMap(); |
781,949 | private static void listenForRenderTreeActivations(@NotNull ToolWindow toolWindow) {<NEW_LINE>final ContentManager contentManager = toolWindow.getContentManager();<NEW_LINE>// TODO: Don't switch to ContentManagerListener until 2020.1.<NEW_LINE>contentManager.addContentManagerListener(new ContentManagerAdapter() {<NEW_L... | .getContent().getTabName(); |
1,578,742 | public void marshall(ReservationPurchaseRecommendationDetail reservationPurchaseRecommendationDetail, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (reservationPurchaseRecommendationDetail == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_... | reservationPurchaseRecommendationDetail.getEstimatedBreakEvenInMonths(), ESTIMATEDBREAKEVENINMONTHS_BINDING); |
233,677 | public void marshall(ApplicationSummary applicationSummary, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (applicationSummary == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(applicationSummary.getApplicat... | applicationSummary.getSpdxLicenseId(), SPDXLICENSEID_BINDING); |
1,061,521 | final CreateBatchPredictionJobResult executeCreateBatchPredictionJob(CreateBatchPredictionJobRequest createBatchPredictionJobRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createBatchPredictionJobRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetri... | addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig); |
305,250 | private HttpHeaders toNettyHttpHeaders() {<NEW_LINE>HttpHeaders headers = new DefaultHttpHeaders(this.configuration.validateHeaders());<NEW_LINE>try {<NEW_LINE>Map<String, List<String>> cookieHeaders = this.configuration.cookieManager().get(finalUri, new HashMap<>());<NEW_LINE>List<String> cookies = new ArrayList<>(coo... | .join("; ", cookies)); |
928,355 | public void validateOkToDeleteAndExpunge(Slice<Long> thePids) {<NEW_LINE>if (!myDaoConfig.isEnforceReferentialIntegrityOnDelete()) {<NEW_LINE>ourLog.info("Referential integrity on delete disabled. Skipping referential integrity check.");<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>List<ResourceLink> conflictResourceLinks = C... | ), myDaoConfig.getExpungeThreadCount()); |
301,617 | private boolean quickCheckin(CheckinHandler checkinHandler, TaskMonitor monitor) throws IOException, CancelledException {<NEW_LINE>if (!(versionedFolderItem instanceof DatabaseItem)) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>monitor.checkCanceled();<NEW_LINE>monitor.setMessage("Initiating Check In for " + name);<NEW... | String comment = checkinHandler.getComment(); |
817,731 | private void extractParamNamesWithIndexes() {<NEW_LINE>List<String> nameList = new ArrayList<String>();<NEW_LINE>List<Integer> idxList = new ArrayList<Integer>();<NEW_LINE>Annotation[][] params = method.getParameterAnnotations();<NEW_LINE>for (int i = 0; i < params.length; i++) {<NEW_LINE>for (Annotation a : params[i])... | ] = idxList.get(i); |
432,538 | private void doSwitchStatementsLineBreaks(List<Statement> statements) {<NEW_LINE>boolean arrowMode = statements.stream().anyMatch(s -> s instanceof SwitchCase && ((SwitchCase<MASK><NEW_LINE>Statement previous = null;<NEW_LINE>for (Statement statement : statements) {<NEW_LINE>// will add break in visit(Block) if necessa... | ) s).isSwitchLabeledRule()); |
1,677,011 | private final ExprNode processSetOfAll(TreeNode treeNode, TreeNode[] children, ModuleNode cm) throws AbortException {<NEW_LINE>ExprNode[<MASK><NEW_LINE>int length = (children.length - 3) / 2;<NEW_LINE>FormalParamNode[][] odna = new FormalParamNode[length][0];<NEW_LINE>boolean[] tuples = new boolean[length];<NEW_LINE>Ex... | ] ops = new ExprNode[1]; |
351,063 | final AssignInstanceResult executeAssignInstance(AssignInstanceRequest assignInstanceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(assignInstanceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.... | HandlerContextKey.SIGNING_REGION, getSigningRegion()); |
463,943 | final DescribeAcceleratorOfferingsResult executeDescribeAcceleratorOfferings(DescribeAcceleratorOfferingsRequest describeAcceleratorOfferingsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeAcceleratorOfferingsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContex... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "DescribeAcceleratorOfferings"); |
1,045,462 | public CompletableFuture<TxnSegments> createTransaction(final Stream stream, final long lease) {<NEW_LINE>Exceptions.checkNotClosed(closed.get(), this);<NEW_LINE>Preconditions.checkNotNull(stream, "stream");<NEW_LINE>final long requestId = requestIdGenerator.get();<NEW_LINE>long traceId = LoggerHelpers.traceEnter(log, ... | "createTransaction", stream, lease, requestId); |
307,905 | public void actionPerformed(final ActionEvent ae) {<NEW_LINE>SHTMLEditorPane editorPane = panel.getSHTMLEditorPane();<NEW_LINE>final Element linkElement = editorPane.getCurrentLinkElement();<NEW_LINE>final boolean foundLink = (linkElement != null);<NEW_LINE>final String linkAsString;<NEW_LINE>if (foundLink) {<NEW_LINE>... | link.toString(), null); |
1,740,707 | protected void drawFilter() {<NEW_LINE>if (shouldLoad) {<NEW_LINE>releaseTexture();<NEW_LINE>streamObjectTextureId = textureLoader.load(streamObject.getBitmaps());<NEW_LINE>shouldLoad = false;<NEW_LINE>}<NEW_LINE>GLES20.glUseProgram(program);<NEW_LINE>squareVertex.position(SQUARE_VERTEX_DATA_POS_OFFSET);<NEW_LINE>GLES2... | false, 2 * FLOAT_SIZE_BYTES, squareVertexObject); |
1,009,139 | public boolean apply(Game game, Ability source) {<NEW_LINE>// In the case that the enchantment is blinked<NEW_LINE>Permanent enchantment = (Permanent) game.getLastKnownInformation(source.getSourceId(), Zone.BATTLEFIELD);<NEW_LINE>if (enchantment == null) {<NEW_LINE>// It was not blinked, use the standard method<NEW_LIN... | add(source.getControllerId()); |
387,219 | public void updateDataList() {<NEW_LINE>if (dataTable == null) {<NEW_LINE>if (tc.isDebugEnabled())<NEW_LINE>Tr.debug(tc, "PmiAbstractModule.updateDataList: module data is not initialized");<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>dataList.clear();<NEW_LINE>Iterator members = dataTable.values().iterator();<NEW_LINE>while (... | (SpdData) members.next(); |
536,006 | // ===================================================================================<NEW_LINE>// Basic Override<NEW_LINE>// ==============<NEW_LINE>@Override<NEW_LINE>protected String doBuildColumnString(String dm) {<NEW_LINE>StringBuilder sb = new StringBuilder();<NEW_LINE>sb.append(dm).append(accessType);<NEW_LINE>... | (dm).append(responseTime); |
248,657 | public static void response(ShardingService shardingService, String stmt) {<NEW_LINE>ShowTablesStmtInfo info;<NEW_LINE>try {<NEW_LINE>info = new ShowTablesStmtInfo(stmt);<NEW_LINE>} catch (Exception e) {<NEW_LINE>shardingService.writeErrMessage(ErrorCode.ER_PARSE_ERROR, e.toString());<NEW_LINE>return;<NEW_LINE>}<NEW_LI... | responseDirect(shardingService, cSchema, info); |
1,122,051 | private Mono<PagedResponse<GuestUsagesResourceInner>> listByResourceGroupSinglePageAsync(String resourceGroupName, Context context) {<NEW_LINE>if (this.client.getEndpoint() == null) {<NEW_LINE>return Mono.error(new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));<NEW_LIN... | error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.")); |
102,321 | private static FailedToBuildExtensionException wrap(ExtensionFactory extensionFactory, Throwable e) {<NEW_LINE>StringBuilder message = new StringBuilder("Failed to build kernel extension ").append(extensionFactory);<NEW_LINE>if (e instanceof LinkageError || e instanceof ReflectiveOperationException) {<NEW_LINE>if (e in... | message.toString(), e); |
465,172 | private static void tryAssertion18(RegressionEnvironment env, String stmtText, String outputLimit, AtomicInteger milestone) {<NEW_LINE>sendTimer(env, 0);<NEW_LINE>env.compileDeploy(stmtText).addListener("s0");<NEW_LINE>String[] fields = new String[] { "symbol", "sum(price)" };<NEW_LINE>ResultAssertTestResult expected =... | , { "YAH", 6d } }); |
1,394,933 | public File runFilter(final File file, Map<String, String[]> parameters) {<NEW_LINE>final String[] widthParam = parameters.get(getPrefix() + "w");<NEW_LINE>int width = widthParam != null ? Integer.parseInt(widthParam[0]) : 0;<NEW_LINE>final String[] heightParam = parameters.<MASK><NEW_LINE>int height = heightParam != n... | get(getPrefix() + "h"); |
213,499 | public static ListProductQuotaDimensionsResponse unmarshall(ListProductQuotaDimensionsResponse listProductQuotaDimensionsResponse, UnmarshallerContext _ctx) {<NEW_LINE>listProductQuotaDimensionsResponse.setRequestId(_ctx.stringValue("ListProductQuotaDimensionsResponse.RequestId"));<NEW_LINE>listProductQuotaDimensionsRe... | = new ArrayList<DimensionValueDetailItem>(); |
121,051 | final StopReplicationTaskResult executeStopReplicationTask(StopReplicationTaskRequest stopReplicationTaskRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(stopReplicationTaskRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | false), new StopReplicationTaskResultJsonUnmarshaller()); |
367,976 | private void applyOptions() {<NEW_LINE>Lines lines = getDocumentLines();<NEW_LINE>if (lines != null) {<NEW_LINE><MASK><NEW_LINE>lines.setDefColor(IOColors.OutputType.OUTPUT, opts.getColorStandard());<NEW_LINE>lines.setDefColor(IOColors.OutputType.ERROR, opts.getColorError());<NEW_LINE>lines.setDefColor(IOColors.OutputT... | OutputOptions opts = io.getOptions(); |
866,129 | public void handleEvent(Event event) {<NEW_LINE>try {<NEW_LINE>String url_str = feedUrl.getText();<NEW_LINE>URL url = new URL(url_str);<NEW_LINE>Map user_data = new HashMap();<NEW_LINE>user_data.put(SubscriptionManagerUI.SUB_EDIT_MODE_KEY, Boolean.TRUE);<NEW_LINE><MASK><NEW_LINE>String subs_name = subsName.getText().tr... | boolean anonymous = anonCheck.getSelection(); |
1,305,387 | public static <T> Class<T> classForName(String name, ClassLoader... loaders) throws ClassNotFoundException {<NEW_LINE>try {<NEW_LINE>if (Thread.currentThread().getContextClassLoader() != null) {<NEW_LINE>return (Class<T>) Class.forName(name, true, Thread.currentThread().getContextClassLoader());<NEW_LINE>} else {<NEW_L... | >) Class.forName(name); |
284,643 | private KeyNamePair[] retrieveChangedPeriods() {<NEW_LINE>final String sql = // standard period<NEW_LINE>"SELECT DISTINCT p.C_Period_ID, p.Name FROM C_Period p " + "INNER JOIN C_Year y ON (y.C_Year_ID=p.C_Year_ID) " + "INNER JOIN PA_ReportCube c ON (c.C_Calendar_ID = y.C_Calendar_ID) " + "INNER JOIN Fact_Acct fact ON (... | currentTimeMillis() - startMillis) / 1000; |
743,844 | int newPath_(int geom) {<NEW_LINE>if (m_path_index_list == null) {<NEW_LINE>m_path_index_list = new StridedIndexTypeCollection(8);<NEW_LINE>m_vertex_index_list = new StridedIndexTypeCollection(5);<NEW_LINE>m_path_areas = new AttributeStreamOfDbl(0);<NEW_LINE>m_path_lengths = new AttributeStreamOfDbl(0);<NEW_LINE>}<NEW_... | pindex = m_path_index_list.elementToIndex(index); |
613,947 | public Request<ReportInstanceStatusRequest> marshall(ReportInstanceStatusRequest reportInstanceStatusRequest) {<NEW_LINE>if (reportInstanceStatusRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<ReportInstanceStatusRequest> request = new De... | , StringUtils.fromString(reportInstanceStatusRequestInstancesListValue)); |
1,398,341 | public Object apply(final ActionContext ctx, final Object caller, final Object[] sources) throws FrameworkException {<NEW_LINE>// use String here because the actual type of the query is not known yet<NEW_LINE>String sortKey = "name";<NEW_LINE>boolean sortDescending = false;<NEW_LINE>try {<NEW_LINE>assertArrayHasMinLeng... | return new SortPredicate(sortKey, sortDescending); |
1,284,967 | public static RowBaseIterator showInstances() {<NEW_LINE>MycatRouterConfig routerConfig = MetaClusterCurrent.wrapper(MycatRouterConfig.class);<NEW_LINE>ReplicaSelectorManager replicaSelectorRuntime = MetaClusterCurrent.wrapper(ReplicaSelectorManager.class);<NEW_LINE>ResultSetBuilder resultSetBuilder = ResultSetBuilder.... | int SESSION_COUNT = instance.getSessionCounter(); |
1,568,243 | private void residualInter(MBlock mBlock, Frame[][] refs, boolean leftAvailable, boolean topAvailable, int mbX, int mbY, int mbAddr) {<NEW_LINE>if (mBlock.cbpLuma() > 0 || mBlock.cbpChroma() > 0) {<NEW_LINE>s.qp = (s.qp + mBlock.mbQPDelta + 52) % 52;<NEW_LINE>}<NEW_LINE>di.mbQps[0][mbAddr] = s.qp;<NEW_LINE>residualLuma... | tr8x8Used[mbAddr] = mBlock.transform8x8Used; |
1,592,283 | final DescribeDomainChangeProgressResult executeDescribeDomainChangeProgress(DescribeDomainChangeProgressRequest describeDomainChangeProgressRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeDomainChangeProgressRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContex... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
934,349 | private void copyAndFloatView() {<NEW_LINE>Dimension size = getSize();<NEW_LINE>Point loc = getLocation();<NEW_LINE><MASK><NEW_LINE>final View view = createView(plugin);<NEW_LINE>final JDialog dlg;<NEW_LINE>Preferences appPrefs = PreferencesManager.getInstance().getApplicationPreferences(ProtegeApplication.ID);<NEW_LIN... | SwingUtilities.convertPointToScreen(loc, this); |
603,711 | public static void main(String[] args) throws UnsupportedAudioFileException, IOException {<NEW_LINE>AudioInputStream inputAudio = AudioSystem.getAudioInputStream(new File(args[0]));<NEW_LINE>int samplingRate = (int) inputAudio.getFormat().getSampleRate();<NEW_LINE><MASK><NEW_LINE>double[] x = signal.getAllData();<NEW_L... | AudioDoubleDataSource signal = new AudioDoubleDataSource(inputAudio); |
1,212,890 | public static void main(String[] args) {<NEW_LINE>final ConfigBuilder configBuilder = new ConfigBuilder();<NEW_LINE>if (args.length > 0) {<NEW_LINE>configBuilder.withMasterUrl(args[0]);<NEW_LINE>logger.info("Using master with URL: {}", args[0]);<NEW_LINE>}<NEW_LINE>try (KubernetesClient client = new KubernetesClientBui... | data.put("tls.key", "YmJi"); |
1,834,853 | public void process(String command, String[] args, PrintStream out) throws CommandException {<NEW_LINE>if (args.length == 0) {<NEW_LINE>out.println(USAGE);<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>File file = new File(args[0]);<NEW_LINE>if (!file.exists() || !file.isFile()) {<NEW_LINE>out.println("The specified command fil... | commands = parseCmdFile(file, charset); |
962,324 | private void createActions() {<NEW_LINE>int subMenuGroup = 1;<NEW_LINE>DockingAction openAction = new ActionBuilder("Open File", getName()).menuPath(ToolConstants.MENU_FILE, "&Open...").menuGroup(OPEN_GROUP, Integer.toString(subMenuGroup++)).keyBinding("ctrl O").enabledWhen(c -> !locked).onAction(c -> open()).buildAndI... | saveAllAction.addToWindowWhen(ProgramActionContext.class); |
1,321,964 | public ListInstanceAttributesResult listInstanceAttributes(ListInstanceAttributesRequest listInstanceAttributesRequest) throws AmazonServiceException, AmazonClientException {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listInstanceAttributesRequest);<NEW_LINE><MASK><NEW_LINE>awsRequestMetrics.st... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
3,162 | private void spawnRobot(double x, double y, boolean isReverse, boolean isLoop) {<NEW_LINE>var text = addText(isReverse ? "Reverse" : "Play", x + 120, y + 30);<NEW_LINE>text.fontProperty().unbind();<NEW_LINE>text.setFont(Font.font(18));<NEW_LINE>var animChannel = new AnimationChannel(image("robot_death.png"), 7, 275, 27... | var animTexture = new AnimatedTexture(animChannel); |
1,064,736 | public void call(FullAccessIntArrPointer dst, int stride, ReadOnlyIntArrPointer above, ReadOnlyIntArrPointer left) {<NEW_LINE>PositionableIntArrPointer pLeft = PositionableIntArrPointer.makePositionable(left);<NEW_LINE>PositionableIntArrPointer pAbove = PositionableIntArrPointer.makePositionable(above);<NEW_LINE>final ... | X, I))))); |
1,818,193 | private List<IInvoiceCandAggregate> createQualityDiscountAggregates(final IInvoiceCandAggregate invoiceCandAggregate) {<NEW_LINE>final List<IInvoiceCandAggregate> <MASK><NEW_LINE>//<NEW_LINE>// Check if we have to create quality discount aggregates.<NEW_LINE>// Create those aggregates if needed and add them to our fina... | discountAggregates = new ArrayList<>(); |
1,656,595 | public StreamObserver<UploadSnapshotPRequest> receiveSnapshotFromFollower(StreamObserver<UploadSnapshotPResponse> responseStreamObserver) {<NEW_LINE>String followerIp = ClientIpAddressInjector.getIpAddress();<NEW_LINE>LOG.info("Received upload snapshot request from follower {}", followerIp);<NEW_LINE>SnapshotDownloader... | error("Unexpected exception downloading snapshot from follower {}.", followerIp, e); |
1,589,344 | private void createNavigationBar(Composite parent) {<NEW_LINE>toolBarManager = new ToolBarManager(SWT.FLAT);<NEW_LINE>toolBarManager.add(backAction);<NEW_LINE>toolBarManager.add(forwardAction);<NEW_LINE>toolBarManager.add(stopAction);<NEW_LINE>toolBarManager.add(refreshAction);<NEW_LINE>ToolBar toolbar = toolBarManager... | , false).create()); |
1,800,854 | final UpdateInputSecurityGroupResult executeUpdateInputSecurityGroup(UpdateInputSecurityGroupRequest updateInputSecurityGroupRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(updateInputSecurityGroupRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetri... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
2,556 | public void urlVariableNamesExistInParameters(ExecutableElement element, Set<String> variableNames, ElementValidation valid) {<NEW_LINE>List<? extends VariableElement> parameters = element.getParameters();<NEW_LINE>Set<String> parametersName = new HashSet<>();<NEW_LINE>for (VariableElement parameter : parameters) {<NEW... | valid.addError("%s annotated method has an url variable which name could not be found in the method parameters: " + variableName); |
1,475,207 | public boolean onCreateOptionsMenu(Menu menu) {<NEW_LINE>logDebug("onCreateOptionsMenu");<NEW_LINE>// Inflate the menu items for use in the action bar<NEW_LINE>MenuInflater inflater = getMenuInflater();<NEW_LINE>inflater.inflate(R.menu.file_explorer_action, menu);<NEW_LINE>searchMenuItem = menu.findItem(R.id.cab_menu_s... | (R.string.hint_action_search)); |
1,600,471 | public CodegenExpression codegen(EnumForgeCodegenParams premade, CodegenMethodScope codegenMethodScope, CodegenClassScope codegenClassScope) {<NEW_LINE>ExprForgeCodegenSymbol scope = new ExprForgeCodegenSymbol(false, null);<NEW_LINE>CodegenMethod methodNode = codegenMethodScope.makeChildWithScope(returnTypeOfMethod(), ... | ), premade.getExprCtx()); |
1,779,453 | @Produces(MediaType.APPLICATION_JSON)<NEW_LINE>@Operation(summary = "Return the reduced configuration", responses = { @ApiResponse(responseCode = "200", description = "OK") })<NEW_LINE>public Response putFullConfigApi(@Context UriInfo uri, @PathParam("username") @Parameter(description = "username") String username, Str... | .config)).build(); |
137,280 | // ------------------------------------------------------------------------<NEW_LINE>// XXX: QueryPart API<NEW_LINE>// ------------------------------------------------------------------------<NEW_LINE>@Override<NEW_LINE>public final void accept(Context<?> ctx) {<NEW_LINE>WithImpl w = with;<NEW_LINE>ctx.scopeStart().dat... | data().remove(DATA_DML_TARGET_TABLE); |
1,711,596 | public CommandLineRunner commandLineRunner(ServletContext servletContext) {<NEW_LINE>return (args) -> {<NEW_LINE>File temp = new File(System.getProperty("java.io.tmpdir"));<NEW_LINE>URL resourceUrl = servletContext.getResource("webjars/jquery/3.5.0/jquery.js");<NEW_LINE>JarURLConnection connection = (JarURLConnection) ... | out.println(">>>>> jar file " + jarName); |
337,915 | public Page download(Request request, Task task) {<NEW_LINE>checkInit();<NEW_LINE>WebDriver webDriver;<NEW_LINE>try {<NEW_LINE>webDriver = webDriverPool.get();<NEW_LINE>} catch (InterruptedException e) {<NEW_LINE>logger.warn("interrupted", e);<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>logger.info("downloading page " + ... | Site site = task.getSite(); |
903,473 | BodyInserters.FormInserter<String> populateTokenRequestBody(OAuth2AuthorizationCodeGrantRequest grantRequest, BodyInserters.FormInserter<String> body) {<NEW_LINE><MASK><NEW_LINE>OAuth2AuthorizationExchange authorizationExchange = grantRequest.getAuthorizationExchange();<NEW_LINE>OAuth2AuthorizationResponse authorizatio... | super.populateTokenRequestBody(grantRequest, body); |
1,487,017 | void reload(ClusterState state, String reason) {<NEW_LINE>boolean hasValidWatcherTemplates = WatcherIndexTemplateRegistry.validate(state);<NEW_LINE>if (hasValidWatcherTemplates == false) {<NEW_LINE>logger.warn("missing watcher index templates");<NEW_LINE>}<NEW_LINE>// this method contains the only async code block, bei... | info("reloading watcher, reason [{}], cancelled [{}] queued tasks", reason, cancelledTaskCount); |
327,303 | private void logProviderInfo(String providerName, ClassLoader loader) {<NEW_LINE>try {<NEW_LINE>if (PROVIDER_ECLIPSELINK.equals(providerName)) {<NEW_LINE>// org.eclipse.persistence.Version.getVersion(): 2.6.4.v20160829-44060b6<NEW_LINE>Class<?> Version = loadClass(loader, "org.eclipse.persistence.Version");<NEW_LINE>St... | tc, "JPA_THIRD_PARTY_PROV_INFO_CWWJP0053I", "Hibernate", version); |
1,237,833 | private static void processAppleRunTime(@NotNull final AppleRunTimeMakernoteDirectory directory, @NotNull final byte[] bplist) throws IOException {<NEW_LINE>final BplistReader.PropertyListResults results = BplistReader.parse(bplist);<NEW_LINE>final Set<Map.Entry<Byte, Byte>> entrySet = results.getEntrySet();<NEW_LINE>i... | ) values.get("timescale")); |
205,407 | void showProfileOrTrip(String data) {<NEW_LINE>Uri uri = Uri.parse(data);<NEW_LINE>String userId = uri.getQueryParameter(SHARE_PROFILE_USER_ID_QUERY);<NEW_LINE>String myId = mSharedPreferences.getString(USER_ID, null);<NEW_LINE>Log.v("user id", userId + " " + myId);<NEW_LINE>if (userId != null) {<NEW_LINE>int id = Inte... | ProfileActivity.getStartIntent(MainActivity.this); |
1,536,317 | protected static void generateCodeForArgument(MethodVisitor mv, CodeFlow cf, SpelNodeImpl argument, String paramDesc) {<NEW_LINE>cf.enterCompilationScope();<NEW_LINE>argument.generateCode(mv, cf);<NEW_LINE>String lastDesc = cf.lastDescriptor();<NEW_LINE>Assert.state(lastDesc != null, "No last descriptor");<NEW_LINE>boo... | CodeFlow.insertCheckCast(mv, paramDesc); |
642,970 | public Map<String, Map<String, AttributeAdapter>> attributeAdaptersForFunction() {<NEW_LINE>Map<String, Map<String, AttributeAdapter>> ret = new HashMap<>();<NEW_LINE>Map<String, AttributeAdapter> tfMappings = new LinkedHashMap<>();<NEW_LINE>val fields = DifferentialFunctionClassHolder.getInstance().getFieldsForFunctio... | fields.get("dataFormat"))); |
345,836 | private void insertSessionAttributes(JdbcSession session, List<String> attributeNames) {<NEW_LINE>Assert.notEmpty(attributeNames, "attributeNames must not be null or empty");<NEW_LINE>try (LobCreator lobCreator = this.lobHandler.getLobCreator()) {<NEW_LINE>if (attributeNames.size() > 1) {<NEW_LINE>try {<NEW_LINE>this.j... | ps.setString(2, attributeName); |
1,704,206 | private List<DalGroup> sortGroups(List<DalGroup> groups, String userNo) throws SQLException {<NEW_LINE>List<DalGroup> result = new ArrayList<DalGroup>(groups.size());<NEW_LINE>LoginUser user = BeanGetter.getDaoOfLoginUser().getUserByNo(userNo);<NEW_LINE>List<UserGroup> joinedGroups = BeanGetter.getDalUserGroupDao().get... | DalGroup group = ite.next(); |
281,539 | public static DynamicThreadPoolExecutor buildDynamicPool(ThreadPoolInitParam initParam) {<NEW_LINE>Assert.notNull(initParam);<NEW_LINE>DynamicThreadPoolExecutor dynamicThreadPoolExecutor;<NEW_LINE>try {<NEW_LINE>dynamicThreadPoolExecutor = new DynamicThreadPoolExecutor(initParam.getCorePoolNum(), initParam.getMaxPoolNu... | .getThreadPoolId()), ex); |
1,622,655 | public void init(Connection conn, String schemaName, String triggerName, String tableName, boolean before, int type) throws SQLException {<NEW_LINE>// get the columns for the table<NEW_LINE>ResultSet rs = conn.getMetaData().getColumns(null, schemaName, tableName, null);<NEW_LINE>// build the insert into history table S... | columnName = rs.getString("COLUMN_NAME"); |
1,286 | public void register(final SimpleCommandMap commandMap, final Map<String, Command> knownCommands, @Nullable final Set<String> aliases) {<NEW_LINE>synchronized (commandMap) {<NEW_LINE>overriddenAliases.clear();<NEW_LINE>overridden = knownCommands.put(label, bukkitCommand);<NEW_LINE>if (aliases != null)<NEW_LINE>aliases.... | commandMap.register("skript", bukkitCommand); |
653,716 | public EditorFont createFont() {<NEW_LINE>if (!completedConstruction) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>com.codename1.ui.Font systemFont = com.codename1.ui.Font.createSystemFont(FONT_FACE_VALUES[systemFontFace.getSelectedIndex()], FONT_STYLE_VALUES[systemFontStyle.getSelectedIndex()], FONT_SIZE_VALUES[systemF... | ], charset.getText()); |
1,193,001 | public InternalAggregation doReduce(List<InternalAggregation> aggregations, ReduceContext reduceContext) {<NEW_LINE>long[] docCounts = new long[buckets.size()];<NEW_LINE>InternalAggregations[][] aggs = new InternalAggregations[buckets.size()][];<NEW_LINE>for (int i = 0; i < aggs.length; ++i) {<NEW_LINE>aggs[i] = new In... | ][i] = bucket.aggregations; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.