idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
430,620 | public final void mML_COMMENT(boolean _createToken) throws RecognitionException, CharStreamException, TokenStreamException {<NEW_LINE>int _ttype;<NEW_LINE>Token _token = null;<NEW_LINE>int _begin = text.length();<NEW_LINE>_ttype = ML_COMMENT;<NEW_LINE>int _saveIndex;<NEW_LINE>mINCOMPLETE_ML_COMMENT(false);<NEW_LINE>sta... | .length() - _begin)); |
502,671 | /*<NEW_LINE>* (non-Javadoc)<NEW_LINE>* @see freeplane.io.INodeWriter#saveContent(freeplane.io.ITreeWriter,<NEW_LINE>* java.lang.Object, java.lang.String)<NEW_LINE>*/<NEW_LINE>public void writeContent(final ITreeWriter writer, final Object node, final IExtension extension) throws IOException {<NEW_LINE>DetailModel detai... | textElement = element.createElement(TEXT_ELEMENT); |
247,201 | protected EJBContextImpl createEjbInstanceAndContext() throws Exception {<NEW_LINE>JCDIService<MASK><NEW_LINE>Object instance = null;<NEW_LINE>EJBContextImpl ctx = _constructEJBContextImpl(null);<NEW_LINE>EjbInvocation ejbInv = null;<NEW_LINE>boolean success = false;<NEW_LINE>try {<NEW_LINE>ejbInv = createEjbInvocation... | .JCDIInjectionContext<?> jcdiCtx = null; |
802,446 | public InternalAggregation reduce(List<InternalAggregation> aggregations, AggregationReduceContext reduceContext) {<NEW_LINE>// We still need to reduce in case we got the same time series in 2 different indices, but we should be able to optimize<NEW_LINE>// that in the future<NEW_LINE>Map<Map<String, Object>, List<Inte... | ), keyed, getMetadata()); |
1,293,168 | public void applyAddNode(AddNodeLog addNodeLog) {<NEW_LINE>long startTime = System.currentTimeMillis();<NEW_LINE>Node newNode = addNodeLog.getNewNode();<NEW_LINE>synchronized (allNodes) {<NEW_LINE>if (logger.isDebugEnabled()) {<NEW_LINE>logger.debug("{}: adding a new node {} into {}", name, newNode, allNodes);<NEW_LINE... | .currentTimeMillis()) - startTime); |
424,144 | private void takeEstep(final double[] artifactPriors) {<NEW_LINE>for (int i = 0; i < maxDepth; i++) {<NEW_LINE>final int depth = i + 1;<NEW_LINE>refResponsibilities.setRow(i, computeResponsibilities(refAllele, refAllele, 0, 0, depth, artifactPriors, false));<NEW_LINE>}<NEW_LINE>// Compute the responsibilities of alt si... | createKey(depth, altAllele, orientation); |
258,771 | public UpdateQualificationTypeResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>UpdateQualificationTypeResult updateQualificationTypeResult = new UpdateQualificationTypeResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth... | String currentParentElement = context.getCurrentParentElement(); |
93,738 | private ResponseRef sendWidgetRequest(NodeRequestRef requestRef) throws ExternalOperationFailedException {<NEW_LINE>String url = getBaseUrl() + URLUtils.widgetUrl;<NEW_LINE>VisualisPostAction visualisPostAction = new VisualisPostAction();<NEW_LINE>visualisPostAction.setUser(requestRef.getUserName());<NEW_LINE>visualisP... | setJobContent(responseRef.toMap()); |
146,898 | public Table metacatToHiveTable(final TableDto dto) {<NEW_LINE>final Table table = new Table();<NEW_LINE>final QualifiedName name = dto.getName();<NEW_LINE>if (name != null) {<NEW_LINE>table.<MASK><NEW_LINE>table.setDbName(name.getDatabaseName());<NEW_LINE>}<NEW_LINE>final StorageDto storageDto = dto.getSerde();<NEW_LI... | setTableName(name.getTableName()); |
225,420 | private boolean doLaunch(@Nullable String url, @Nonnull List<String> command, @Nullable final WebBrowser browser, @Nullable final Project project, @Nonnull String[] additionalParameters, @Nullable Runnable launchTask) {<NEW_LINE>if (url != null && url.startsWith("jar:")) {<NEW_LINE>String files = extractFiles(url);<NEW... | Process process = commandLine.createProcess(); |
524,403 | public static AutogenEnvironmentVariablesDiff fromProto(ai.verta.modeldb.versioning.EnvironmentVariablesDiff blob) {<NEW_LINE>if (blob == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>AutogenEnvironmentVariablesDiff obj = new AutogenEnvironmentVariablesDiff();<NEW_LINE>{<NEW_LINE>Function<ai.verta.modeldb.versionin... | fromProto(blob.getC()); |
932,667 | protected void updateUninstallUpgrade() {<NEW_LINE>final int[] selected = myPackagesTable.getSelectedRows();<NEW_LINE>boolean upgradeAvailable = false;<NEW_LINE><MASK><NEW_LINE>boolean canInstall = installEnabled();<NEW_LINE>boolean canUpgrade = true;<NEW_LINE>if (myPackageManagementService != null && selected.length !... | boolean canUninstall = selected.length != 0; |
1,719,312 | public ObservableSource<? extends VectorSchemaRoot> apply(VectorSchemaRoot input) throws Throwable {<NEW_LINE>int rowCount = input.getRowCount();<NEW_LINE>VectorBatchRecord record = new VectorBatchRecord(input);<NEW_LINE>VectorSchemaRoot output = rootContext.getVectorSchemaRoot(schema, rowCount * recordSinks.length);<N... | RecordSinkFactory.INSTANCE.getRecordSinkSPI(key); |
1,766,394 | public static SecretQuestionCredentialModel createFromCredentialModel(CredentialModel credentialModel) {<NEW_LINE>try {<NEW_LINE>SecretQuestionCredentialData credentialData = JsonSerialization.readValue(credentialModel.getCredentialData(), SecretQuestionCredentialData.class);<NEW_LINE>SecretQuestionSecretData secretDat... | setUserLabel(credentialModel.getUserLabel()); |
934,816 | public void store(Item item, String alias) {<NEW_LINE>if (item.getState() instanceof UnDefType) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (!isProperlyConfigured) {<NEW_LINE>logger.warn("Configuration for influxdb not yet loaded or broken.");<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (!isConnected()) {<NEW_LINE>logger.war... | item.getStateAs(HSBType.class); |
840,630 | public BaseLastAnalysisResultVO processBiz(ToolLastAnalysisResultVO arg, boolean isLast) {<NEW_LINE>long taskId = arg.getTaskId();<NEW_LINE>String toolName = arg.getToolName();<NEW_LINE>String buildId = arg.getBuildId();<NEW_LINE>CommonStatisticEntity statisticEntity;<NEW_LINE>if (isLast) {<NEW_LINE>statisticEntity = c... | BeanUtils.copyProperties(statisticEntity, lastAnalysisResultVO); |
536,108 | public static Loop commonSuperloop(Loop first, Loop second) {<NEW_LINE>if (first == second) {<NEW_LINE>return first;<NEW_LINE>}<NEW_LINE>List<Loop> firstPath = new ArrayList<>();<NEW_LINE>List<Loop> <MASK><NEW_LINE>while (first != null) {<NEW_LINE>firstPath.add(first);<NEW_LINE>first = first.getParent();<NEW_LINE>}<NEW... | secondPath = new ArrayList<>(); |
1,147,514 | public AuthServiceResult authenticate(AuthServiceCredentials authCredentials) {<NEW_LINE>final Optional<AuthServiceBackend> activeBackend = authServiceConfig.getActiveBackend();<NEW_LINE>if (activeBackend.isPresent()) {<NEW_LINE>AuthenticationServiceUnavailableException caughtException = null;<NEW_LINE>try {<NEW_LINE>f... | authCredentials, authServiceConfig.getDefaultBackend()); |
1,069,447 | private Set<Integer> flagDuplicates(final List<Build37ExtendedIlluminaManifestRecord> records) {<NEW_LINE>// Load the cluster file to get the GenTrain scores<NEW_LINE>// load the egt first, and create a map of ilmnid to gentrain score. Save that and use it for deduplicating.<NEW_LINE>log.info("Loading the egt file for... | getAbsolutePath() + "'", e); |
1,258,032 | protected boolean processKeyValueTokens() {<NEW_LINE>List<WSSecurityEngineResult> tokenResults <MASK><NEW_LINE>for (WSSecurityEngineResult wser : signedResults) {<NEW_LINE>PublicKey publicKey = (PublicKey) wser.get(WSSecurityEngineResult.TAG_PUBLIC_KEY);<NEW_LINE>if (publicKey != null) {<NEW_LINE>tokenResults.add(wser)... | = new ArrayList<WSSecurityEngineResult>(); |
1,139,250 | public int reloadAllSegments(String tableNameWithType, boolean forceDownload) {<NEW_LINE>LOGGER.info("Sending reload message for table: {} with forceDownload: {}", tableNameWithType, forceDownload);<NEW_LINE>if (forceDownload) {<NEW_LINE>TableType tt = TableNameBuilder.getTableTypeFromTableName(tableNameWithType);<NEW_... | SegmentReloadMessage(tableNameWithType, null, forceDownload); |
1,150,640 | private static void convertDocker(org.jreleaser.model.DockerConfiguration d, DockerConfiguration docker) {<NEW_LINE>if (d instanceof org.jreleaser.model.Docker && docker instanceof Docker) {<NEW_LINE>org.jreleaser.model.Docker dd = (org.jreleaser.model.Docker) d;<NEW_LINE>Docker kk = (Docker) docker;<NEW_LINE>if (kk.is... | (docker.getBuildArgs())); |
835,176 | public static String open(String wsName, String packageName, String wsdlName) {<NEW_LINE>String title = NbBundle.<MASK><NEW_LINE>DeleteWsDialog delDialog = new DeleteWsDialog(wsName, packageName, wsdlName);<NEW_LINE>NotifyDescriptor desc = new NotifyDescriptor.Confirmation(delDialog, title, NotifyDescriptor.YES_NO_OPTI... | getMessage(DeleteWsDialog.class, "MSG_ConfirmDeleteObjectTitle"); |
152,418 | public static void execute(ManagerService service) {<NEW_LINE>ByteBuffer buffer = service.allocate();<NEW_LINE>// write header<NEW_LINE>buffer = HEADER.write(buffer, service, true);<NEW_LINE>// write fields<NEW_LINE>for (FieldPacket field : FIELDS) {<NEW_LINE>buffer = field.write(buffer, service, true);<NEW_LINE>}<NEW_... | write(buffer, service, true); |
722,083 | public void testOpenHistory() throws Exception {<NEW_LINE>Project project = env.getProject();<NEW_LINE>ProjectData projectData = project.getProjectData();<NEW_LINE>projectData.getRootFolder().createFile("WinHelloCpp.exe", program, TaskMonitorAdapter.DUMMY_MONITOR);<NEW_LINE>DomainFile df = program.getDomainFile();<NEW_... | -> invokeInstanceMethod("advancedButtonCallback", dialog)); |
308,540 | public void startMonitoring() {<NEW_LINE><MASK><NEW_LINE>log.debug("File name obtained from pathOfFileToWatch is [{}]", fileName);<NEW_LINE>if (fileName == null) {<NEW_LINE>throw new IllegalStateException("fileName is 'null'");<NEW_LINE>}<NEW_LINE>Path dirPath = pathOfFileToWatch.getParent();<NEW_LINE>log.debug("dirPat... | Path fileName = pathOfFileToWatch.getFileName(); |
1,615,825 | private static boolean optionMatches(BuildOptionDetails options, String optionName, Object expectedValue) {<NEW_LINE>Object <MASK><NEW_LINE>if (actualValue == null) {<NEW_LINE>return expectedValue == null;<NEW_LINE>// Single-value case:<NEW_LINE>} else if (!options.allowsMultipleValues(optionName)) {<NEW_LINE>return ac... | actualValue = options.getOptionValue(optionName); |
1,361,238 | static Optional<String> longestCommonPath(List<ApiDescription> apiDescriptions) {<NEW_LINE>List<String> commons = new ArrayList<>();<NEW_LINE>if (null == apiDescriptions || apiDescriptions.isEmpty()) {<NEW_LINE>return empty();<NEW_LINE>}<NEW_LINE>List<String> firstWords = urlParts(apiDescriptions.get(0));<NEW_LINE>for ... | (apiDescriptions.get(i)); |
506,860 | private Mono<PagedResponse<JitNetworkAccessPolicyInner>> listSinglePageAsync() {<NEW_LINE>if (this.client.getEndpoint() == null) {<NEW_LINE>return Mono.<MASK><NEW_LINE>}<NEW_LINE>if (this.client.getSubscriptionId() == null) {<NEW_LINE>return Mono.error(new IllegalArgumentException("Parameter this.client.getSubscription... | error(new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null.")); |
1,143,235 | protected Street readIntersectedStreet(City c, int street24X, int street24Y, List<String> additionalTagsTable) throws IOException {<NEW_LINE>int x = 0;<NEW_LINE>int y = 0;<NEW_LINE>Street s = new Street(c);<NEW_LINE>LinkedList<String> additionalTags = null;<NEW_LINE>while (true) {<NEW_LINE>int t = codedIS.readTag();<NE... | .length()), nm); |
436,886 | final ListDataSourcesResult executeListDataSources(ListDataSourcesRequest listDataSourcesRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listDataSourcesRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(F... | endClientExecution(awsRequestMetrics, request, response); |
1,062,293 | final UpdateUserPoolDomainResult executeUpdateUserPoolDomain(UpdateUserPoolDomainRequest updateUserPoolDomainRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(updateUserPoolDomainRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRe... | addHandlerContext(HandlerContextKey.SERVICE_ID, "Cognito Identity Provider"); |
857,698 | public int onBackPressed() {<NEW_LINE>logDebug("onBackPressed");<NEW_LINE>if (selectFile) {<NEW_LINE>if (((FileExplorerActivity) context).isMultiselect()) {<NEW_LINE>if (adapter.isMultipleSelect()) {<NEW_LINE>hideMultipleSelect();<NEW_LINE>}<NEW_LINE>}<NEW_LINE>}<NEW_LINE>MegaNode parentNode = megaApi.getParentNode(meg... | emptyImageView.setVisibility(View.GONE); |
939,798 | public String serialize(int numberOfSpacesToIndent, HttpRequestModifier request) {<NEW_LINE>StringBuffer output = new StringBuffer();<NEW_LINE>if (request != null) {<NEW_LINE>appendNewLineAndIndent(numberOfSpacesToIndent * INDENT_SIZE, output);<NEW_LINE>output.append("requestModifier()");<NEW_LINE>if (request.getPath()... | getCookies().getAdd()); |
1,007,964 | private static void writeInt(byte[] b, int startPos, int x, int size) {<NEW_LINE>long v = Integer.toUnsignedLong(x);<NEW_LINE>switch(size) {<NEW_LINE>case 1:<NEW_LINE>b[startPos + 0] = (byte) (x);<NEW_LINE>break;<NEW_LINE>case 2:<NEW_LINE>b[startPos + 0] = (byte) (v >> 8);<NEW_LINE>b[startPos + 1] = (byte) (v);<NEW_LIN... | byte) (v >> 16); |
1,358,946 | private int forwardMedia(data.media.Media media, FlatBufferBuilder fbb) {<NEW_LINE>int uri = fbb.createString(media.uri);<NEW_LINE>int title = media.title != null ? fbb.createString(media.title) : 0;<NEW_LINE>int format = fbb.createString(media.format);<NEW_LINE>int[] persons = new int[media.persons.size()];<NEW_LINE>f... | createString(media.copyright) : 0; |
867,492 | public Set<FileObject> extend(PhpModule phpModule) throws ExtendingException {<NEW_LINE>try {<NEW_LINE>unpackSkeleton(phpModule);<NEW_LINE>} catch (IOException ex) {<NEW_LINE>LOGGER.log(Level.INFO, "Cannot unpack Zend Application Skeleton.", ex);<NEW_LINE>throw new ExtendingException(Bundle.Zend2PhpModuleExtender_not_e... | processExecutionException(ex, Zend2OptionsPanelController.OPTIONS_SUBPATH); |
723,705 | public Sql[] generateSql(SetTableRemarksStatement statement, Database database, SqlGeneratorChain sqlGeneratorChain) {<NEW_LINE>String sql;<NEW_LINE>String remarksEscaped = database.escapeStringForDatabase(StringUtil.trimToEmpty(statement.getRemarks()));<NEW_LINE>if (database instanceof MySQLDatabase) {<NEW_LINE>sql = ... | )) + " IS '" + remarksEscaped + "'"; |
1,057,719 | public void saveXml(StringBuilder buffer, PcodeInjectLibrary injectLibrary) {<NEW_LINE>if (compatModel != null) {<NEW_LINE>buffer.append("<modelalias");<NEW_LINE>SpecXmlUtils.encodeStringAttribute(buffer, "name", name);<NEW_LINE>SpecXmlUtils.encodeStringAttribute(buffer, "parent", compatModel.name);<NEW_LINE>buffer.app... | "type", genericCallingConvention.getDeclarationName()); |
343,919 | public OutlierResult autorun(Database database) {<NEW_LINE>DBIDs ids = database.getRelation(TypeUtil.ANY).getDBIDs();<NEW_LINE>// Run the primary algorithm<NEW_LINE>Clustering<? extends SubspaceModel> clustering = clusteralg.autorun(database);<NEW_LINE>WritableDoubleDataStore score = DataStoreUtil.makeDoubleStorage(ids... | ), 0, Double.POSITIVE_INFINITY); |
75,017 | private void sendBatch(String dataStructureName, List<Integer> memberPartitions, List<MergingItem>[] entriesPerPartition, SplitBrainMergePolicy<V, MergingItem, Object> mergePolicy) {<NEW_LINE>int size = memberPartitions.size();<NEW_LINE>int[] partitions = new int[size];<NEW_LINE>int index = 0;<NEW_LINE>for (Integer par... | Arrays.copyOf(partitions, index); |
180,965 | ActionResult<Wo> execute(EffectivePerson effectivePerson, String flag, String appInfoFlag) throws Exception {<NEW_LINE>try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {<NEW_LINE>ActionResult<Wo> result = new ActionResult<>();<NEW_LINE>Wo wo = null;<NEW_LINE>Cache.CacheKey cacheKey =... | bs = new byte[] {}; |
1,507,645 | public Attribute unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>Attribute attribute = new Attribute();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (context.isStartOfDocument())<NEW_LINE>targetDepth += 1;<NEW_LINE>while (true)... | ().unmarshall(context)); |
20,348 | final ListRecordsResult executeListRecords(ListRecordsRequest listRecordsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listRecordsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTi... | endClientExecution(awsRequestMetrics, request, response); |
1,224,326 | public void zoomColumn(String columnId) {<NEW_LINE>double rightTargetSize;<NEW_LINE>ArrayList<Double> <MASK><NEW_LINE>String currentZoomedColumn = getZoomedColumn();<NEW_LINE>boolean unZooming = false;<NEW_LINE>if (StringUtil.equals(currentZoomedColumn, columnId)) {<NEW_LINE>if (widgetSizePriorToZoom_ < 0 || (leftWidge... | leftTargetSize = new ArrayList<>(); |
1,427,670 | public static void registerType(final ModelBuilder modelBuilder) {<NEW_LINE>final ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(LinkEventDefinition.class, BPMN_ELEMENT_LINK_EVENT_DEFINITION).namespaceUri(BPMN20_NS).extendsType(EventDefinition.class).instanceProvider(new ModelTypeInstanceProvider<LinkEve... | LinkEventDefinition.class).build(); |
329,891 | private List<String> checkOfflineTablesSegmentIntervals(String offlineTableName) {<NEW_LINE>TableConfig tableConfig = ZKMetadataProvider.getOfflineTableConfig(_propertyStore, offlineTableName);<NEW_LINE>List<SegmentZKMetadata> segmentsZKMetadata = ZKMetadataProvider.getSegmentsZKMetadata(_propertyStore, offlineTableNam... | long startTimeMs = segmentZKMetadata.getStartTimeMs(); |
172,574 | public int classifyPathObjects(Collection<PathObject> pathObjects) {<NEW_LINE>int counter = 0;<NEW_LINE>// PathClass classPositive = PathClassFactory.getDefaultPathClass(PathClassFactory.PathClasses.POSITIVE);<NEW_LINE>// PathClass classNegative = PathClassFactory.getDefaultPathClass(PathClassFactory.PathClasses.NEGATI... | setIntensityClassifications(pathObjects, intensityMeasurement, t1); |
40,271 | public static QueryFaceUserResponse unmarshall(QueryFaceUserResponse queryFaceUserResponse, UnmarshallerContext _ctx) {<NEW_LINE>queryFaceUserResponse.setRequestId(_ctx.stringValue("QueryFaceUserResponse.RequestId"));<NEW_LINE>queryFaceUserResponse.setSuccess(_ctx.booleanValue("QueryFaceUserResponse.Success"));<NEW_LIN... | + "].FeatureDTOList[" + j + "].ErrorMessage")); |
1,187,893 | final CreateTransitGatewayResult executeCreateTransitGateway(CreateTransitGatewayRequest createTransitGatewayRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createTransitGatewayRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRe... | awsRequestMetrics.endEvent(Field.RequestMarshallTime); |
1,043,283 | public static <T extends IBaseResource> T apply(FhirContext theCtx, T theResourceToUpdate, @Language("JSON") String thePatchBody) {<NEW_LINE>// Parse the patch<NEW_LINE>ObjectMapper mapper = new ObjectMapper();<NEW_LINE>mapper.configure(JsonParser.Feature.INCLUDE_SOURCE_IN_LOCATION, false);<NEW_LINE>JsonFactory factory... | postPatchedContent = mapper.writeValueAsString(after); |
262,158 | private void handleSignalingMessage(String message) {<NEW_LINE>log.debug("S got signaling message: " + message);<NEW_LINE>var msg = gson.fromJson(message, MessageDto.class);<NEW_LINE>switch(msg.type) {<NEW_LINE>case "login" -><NEW_LINE>{<NEW_LINE>var loginMsg = gson.fromJson(message, LoginMessageDto.class);<NEW_LINE>if... | ).addIceCandidate(candidateMessage.candidate); |
1,748,717 | protected Object stringChrAt(Object string, int byteIndex, @CachedLibrary(limit = "LIBSTRING_CACHE") RubyStringLibrary strings, @Cached GetActualEncodingNode getActualEncodingNode, @Cached BytesNode bytesNode, @Cached CalculateCharacterLengthNode calculateCharacterLengthNode, @Cached CodeRangeNode codeRangeNode, @Cache... | + c), encoding, CR_UNKNOWN); |
1,370,466 | public ContentHolder onCreateContentViewWithPos(ViewGroup parent, int position, int viewType) {<NEW_LINE>NodeHolder contentHolder = new NodeHolder();<NEW_LINE>// LogUtils.d("HippyListView", "onCreateContentViewWithPos start position " + position);<NEW_LINE>RenderNode contentViewRenderNode = mHippyContext.getRenderManag... | View view = contentViewRenderNode.createViewRecursive(); |
273,595 | public void run() {<NEW_LINE>String sessionId = session;<NEW_LINE>while (!Thread.currentThread().isInterrupted()) {<NEW_LINE>try {<NEW_LINE>LOGGER.debug("renew lock of session start:" + sessionId + " " + path);<NEW_LINE>if (!Boolean.TRUE.equals(ClusterHelper.isExist(path))) {<NEW_LINE>log("renew lock of session failu... | .MILLISECONDS.toNanos(10000)); |
1,789,700 | protected void storePorts() {<NEW_LINE>final String dasPortStr = dasPortField.getText().trim();<NEW_LINE>final String httpPortStr = httpPortField.getText().trim();<NEW_LINE>try {<NEW_LINE>int dasPort = Integer.parseInt(dasPortStr);<NEW_LINE>if (0 <= dasPort && dasPort < MAX_PORT_VALUE) {<NEW_LINE>// Update value only w... | httpPort = Integer.parseInt(httpPortStr); |
891,366 | private int calculateWraps(int width) {<NEW_LINE>myTooSmall = width < MIN_WIDTH;<NEW_LINE>if (myTooSmall) {<NEW_LINE>return -1;<NEW_LINE>}<NEW_LINE>int result = 0;<NEW_LINE>myWraps = new ArrayList();<NEW_LINE>for (int i = 0; i < myLines.length; i++) {<NEW_LINE>String aLine = myLines[i];<NEW_LINE>int lineFirstChar = 0;<... | (currFirst, currLast + 1)); |
300,579 | public void prepareWrite(final int recordCount, final int inputSize, final int idealSize) {<NEW_LINE>this.inputCount = inputSize;<NEW_LINE>this.idealCount = idealSize;<NEW_LINE>ZipInputStream zis = null;<NEW_LINE>try {<NEW_LINE>this.fos = new FileOutputStream(this.file);<NEW_LINE>this.zos = new ZipOutputStream(this.fos... | xmlOut.addAttribute("xmlns:r", "http://schemas.openxmlformats.org/officeDocument/2006/relationships"); |
1,793,843 | public <V> void addVertexProperty(HugeVertexProperty<V> prop) {<NEW_LINE>// NOTE: this method can also be used to update property<NEW_LINE>HugeVertex vertex = prop.element();<NEW_LINE>E.checkState(vertex != null, "No owner for updating property '%s'", prop.key());<NEW_LINE>// Add property in memory for new created vert... | "Can't update property '%s' for adding-state vertex", prop.key()); |
1,781,517 | public static void main(String[] args) {<NEW_LINE>BufferedImage orig = UtilImageIO.loadImageNotNull(UtilIO.pathExample("standard/man_mls.jpg"));<NEW_LINE>var bufferedOut = new BufferedImage(orig.getWidth(), orig.getHeight(), BufferedImage.TYPE_INT_RGB);<NEW_LINE>Planar<GrayF32> input = ConvertBufferedImage.convertFrom(... | showWindow(bufferedOut, "Point Based Distortion Animation", true); |
508,784 | Mono<Response<ShareFileInfo>> createWithResponse(long maxSize, ShareFileHttpHeaders httpHeaders, FileSmbProperties smbProperties, String filePermission, Map<String, String> metadata, ShareRequestConditions requestConditions, Context context) {<NEW_LINE>requestConditions = requestConditions == null ? new ShareRequestCon... | setFilePermission(filePermission, FileConstants.FILE_PERMISSION_INHERIT); |
1,510,460 | private void shareImage(int page) {<NEW_LINE>if (null == mGalleryProvider) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>File dir = AppConfig.getExternalTempDir();<NEW_LINE>if (null == dir) {<NEW_LINE>Toast.makeText(this, R.string.error_cant_create_temp_file, <MASK><NEW_LINE>return;<NEW_LINE>}<NEW_LINE>UniFile file;<NEW_LINE>... | Toast.LENGTH_SHORT).show(); |
428,311 | final DetachSecurityProfileResult executeDetachSecurityProfile(DetachSecurityProfileRequest detachSecurityProfileRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(detachSecurityProfileRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>... | HandlerContextKey.SIGNING_REGION, getSigningRegion()); |
658,611 | static TLSCertificateKeyPair fromX509CertKeyPair(X509Certificate x509Cert, KeyPair keyPair) throws IOException {<NEW_LINE>ByteArrayOutputStream baos = new ByteArrayOutputStream();<NEW_LINE>OutputStreamWriter writer = new OutputStreamWriter(baos);<NEW_LINE>JcaPEMWriter w = new JcaPEMWriter(writer);<NEW_LINE>w.writeObjec... | InputStreamReader(new ByteArrayInputStream(pemBytes)); |
1,478,604 | public void computeKilometricExpense(ActionRequest request, ActionResponse response) throws AxelorException {<NEW_LINE>ExpenseLine expenseLine = request.getContext().asType(ExpenseLine.class);<NEW_LINE>if (expenseLine.getKilometricAllowParam() == null || expenseLine.getDistance().compareTo(BigDecimal.ZERO) == 0 || expe... | ).computeKilometricExpense(expenseLine, employee); |
1,127,020 | protected void addContent(RepositoryResourceWritable res, File assetFile, String name, ArtifactMetadata metadata, String contentUrl) throws RepositoryException {<NEW_LINE>String downloadUrl = contentUrl;<NEW_LINE>String linkTypeString = null;<NEW_LINE>if (metadata != null && metadata.properties != null) {<NEW_LINE>if (... | res.setDisplayPolicy(DisplayPolicy.HIDDEN); |
167,661 | private static void addDiscountLine(MOrder order, List<OrderLinePromotionCandidate> candidates) throws Exception {<NEW_LINE>for (OrderLinePromotionCandidate candidate : candidates) {<NEW_LINE>final String rewardMode = candidate.promotionReward.getRewardMode();<NEW_LINE>if (MPromotionReward.REWARDMODE_Charge.equals(rewa... | candidate.promotionReward.getAmount()); |
354,036 | public boolean validate(@NotNull PsiClass psiClass, @NotNull PsiAnnotation psiAnnotation, @NotNull ProblemBuilder problemBuilder) {<NEW_LINE>boolean result = <MASK><NEW_LINE>if (result) {<NEW_LINE>final Project project = psiAnnotation.getProject();<NEW_LINE>final String builderClassName = getBuilderClassName(psiClass, ... | validateAnnotationOnRightType(psiClass, psiAnnotation, problemBuilder); |
494,402 | protected void postToWASReqURL(HttpServletRequest req, HttpServletResponse resp, String requestUrl, String oidcClientId) throws IOException {<NEW_LINE>String access_token = req.getParameter(Constants.ACCESS_TOKEN);<NEW_LINE>String id_token = req.getParameter(Constants.ID_TOKEN);<NEW_LINE>if (TraceComponent.isAnyTracing... | resp.setHeader("Cache-Control", "no-cache, no-store, must-revalidate, private, max-age=0"); |
61,855 | public boolean train(InstanceList trainingSet, InstanceList unlabeledSet, int numIterations) {<NEW_LINE>if (hmm.emissionEstimator == null)<NEW_LINE>hmm.reset();<NEW_LINE>converged = false;<NEW_LINE>@Var<NEW_LINE>double threshold = 0.001;<NEW_LINE>@Var<NEW_LINE>double logLikelihood = Double.NEGATIVE_INFINITY, prevLogLik... | (FeatureSequence) inst.getData(); |
1,507,775 | public void create(Feature fp) {<NEW_LINE>if (fp == null) {<NEW_LINE>throw new IllegalArgumentException("Feature cannot be null nor empty");<NEW_LINE>}<NEW_LINE>if (exist(fp.getUid())) {<NEW_LINE>throw new FeatureAlreadyExistException(fp.getUid());<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>// Create core<NEW_LINE>graphDb.exe... | Transaction tx = graphDb.beginTx(); |
25,855 | public Tuple<List<AggregationBuilder>, List<PipelineAggregationBuilder>> aggs(EvaluationParameters parameters, EvaluationFields evaluationFields) {<NEW_LINE>if (result.get() != null) {<NEW_LINE>return Tuple.tuple(List.of(), List.of());<NEW_LINE>}<NEW_LINE>// Store given {@code fields} for the purpose of generating erro... | ), List.of()); |
463,943 | final DescribeAcceleratorOfferingsResult executeDescribeAcceleratorOfferings(DescribeAcceleratorOfferingsRequest describeAcceleratorOfferingsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeAcceleratorOfferingsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContex... | invoke(request, responseHandler, executionContext); |
301,814 | protected Money distributeOrderSavingsToItems(Order order, BigDecimal totalAllItems) {<NEW_LINE>Money returnAmount = new Money(order.getCurrency());<NEW_LINE>BigDecimal orderAdjAmt = order<MASK><NEW_LINE>for (FulfillmentGroup fulfillmentGroup : order.getFulfillmentGroups()) {<NEW_LINE>for (FulfillmentGroupItem fgItem :... | .getOrderAdjustmentsValue().getAmount(); |
1,193,529 | protected boolean resolve(final ClassNode type, final boolean testModuleImports, final boolean testDefaultImports, final boolean testStaticInnerClasses) {<NEW_LINE><MASK><NEW_LINE>if (type.isResolved() || type.isPrimaryClassNode())<NEW_LINE>return true;<NEW_LINE>if (type.isArray()) {<NEW_LINE>ClassNode element = type.g... | resolveGenericsTypes(type.getGenericsTypes()); |
1,203,909 | private void loadNode30() {<NEW_LINE>UaMethodNode node = new UaMethodNode(this.context, Identifiers.ConditionType_AddComment, new QualifiedName(0, "AddComment"), new LocalizedText("en", "AddComment"), LocalizedText.NULL_VALUE, UInteger.valueOf(0), UInteger.valueOf(0), true, true);<NEW_LINE>node.addReference(new Referen... | .expanded(), false)); |
858,534 | public <V, K extends Exception> V runWithRetryOnServer(CassandraServer specifiedServer, FunctionCheckedException<CassandraClient, V, K> fn) throws K {<NEW_LINE>RetryableCassandraRequest<V, K> req = new RetryableCassandraRequest<>(specifiedServer, fn);<NEW_LINE>while (true) {<NEW_LINE>if (log.isTraceEnabled()) {<NEW_LIN... | , req.getCassandraServer())); |
975,046 | public synchronized void close() {<NEW_LINE>PROFILER.unregisterHookValue(profilerMetric + ".transmittedBytes");<NEW_LINE>PROFILER.unregisterHookValue(profilerMetric + ".receivedBytes");<NEW_LINE>PROFILER.unregisterHookValue(profilerMetric + ".flushes");<NEW_LINE>try {<NEW_LINE>if (socket != null) {<NEW_LINE>socket.clos... | debug(this, "Error during closing of input stream", e); |
328,627 | AffineTransform doCreateArrowTransform(double arrowPlacementTolerance, Shape edgeShape, Shape vertexShape) {<NEW_LINE>GeneralPath path = new GeneralPath(edgeShape);<NEW_LINE>double[<MASK><NEW_LINE>Point2D p1 = null;<NEW_LINE>Point2D p2 = null;<NEW_LINE>AffineTransform at = new AffineTransform();<NEW_LINE>// Find the li... | ] seg = new double[6]; |
157,645 | private String maybeAlignedRefSpec(Logger logger, String defaultRefSpec) {<NEW_LINE>if (providerFactory.systemProperty("bwc.checkout.align").isPresent() == false) {<NEW_LINE>return defaultRefSpec;<NEW_LINE>}<NEW_LINE>String timeOfCurrent = execInCheckoutDir(execSpec -> {<NEW_LINE>execSpec.commandLine(asList("git", "sho... | workingDir(project.getRootDir()); |
713,679 | protected AdminResult handle() {<NEW_LINE>// 1. Increase/decrease the specified proposal execution concurrency.<NEW_LINE>String ongoingConcurrencyChangeRequest = processChangeExecutionConcurrencyRequest();<NEW_LINE>// 2. Enable/disable self-healing for the specified anomaly types.<NEW_LINE>Map<AnomalyType, Boolean> sel... | concurrencyAdjusterAfter = new HashMap<>(); |
3,955 | public ResultCursor sync() {<NEW_LINE>ArrayResultCursor result = new ArrayResultCursor("RULE");<NEW_LINE>result.addColumn("activeConnection", DataTypes.LongType);<NEW_LINE>result.addColumn("aggregateMultiDBCount", DataTypes.LongType);<NEW_LINE>result.addColumn("connectionCount", DataTypes.LongType);<NEW_LINE>result.add... | addColumn("joinMultiDBCount", DataTypes.LongType); |
1,488,227 | protected void paintTabBorder(Graphics g, int tabIndex, int x, int y, int w, int h, boolean isSelected) {<NEW_LINE>g.translate(x, y);<NEW_LINE>int right = w;<NEW_LINE>int bottom = h;<NEW_LINE>if (isFirstDisplayedTab(tabIndex, x, tabPane.getBounds().x)) {<NEW_LINE>if (isSelected) {<NEW_LINE>g.setColor(selectHighlight);<... | 1, 1, bottom - 1); |
1,316,501 | private void defineLayout() {<NEW_LINE>component.setLayout(new BorderLayout());<NEW_LINE>component.setNoInsets();<NEW_LINE>component.add(slider, BorderLayout.WEST);<NEW_LINE>component.<MASK><NEW_LINE>component.setName("SheetAssemblyPanel");<NEW_LINE>// Avoid slider to react on (and consume) page up/down keys or arrow k... | add(viewsPane, BorderLayout.CENTER); |
1,618,371 | public void enterSid_trunk_group(A10Parser.Sid_trunk_groupContext ctx) {<NEW_LINE>TrunkGroup.Type type = ctx.trunk_type() != null ? toType(ctx.trunk_type()) : null;<NEW_LINE>Optional<Integer> maybeNum = toInteger(ctx, ctx.trunk_number());<NEW_LINE>if (!maybeNum.isPresent()) {<NEW_LINE>// dummy<NEW_LINE>_currentTrunkGro... | new TrunkGroup(-1, type); |
395,687 | public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {<NEW_LINE>if (((bitField0_ & 0x00000001) == 0x00000001)) {<NEW_LINE>output.writeEnum(1, type_);<NEW_LINE>}<NEW_LINE>if (((bitField0_ & 0x00000002) == 0x00000002)) {<NEW_LINE>output.writeInt64(2, term_);<NEW_LINE>}<NEW_LINE>if ... | , oldPeers_.get(i)); |
1,854,475 | public static String findParameterType(ParameterContext parameterContext) {<NEW_LINE>ResolvedMethodParameter resolvedMethodParameter = parameterContext.resolvedMethodParameter();<NEW_LINE>ResolvedType parameterType = resolvedMethodParameter.getParameterType();<NEW_LINE>parameterType = parameterContext.alternateFor(para... | LOGGER.warn("@ModelAttribute annotated parameters should have already been expanded via " + "the ExpandedParameterBuilderPlugin"); |
925,639 | private void createQtyReportEvent(final IContextAware context, final I_PMM_Product pmmProduct, final SyncProductSupply syncProductSupply) {<NEW_LINE>logger.debug("Creating QtyReport event from {} ({})", syncProductSupply, pmmProduct);<NEW_LINE>final List<String> errors = new ArrayList<>();<NEW_LINE>final I_PMM_QtyRepor... | valueOf(qtyReportEvent.getPMM_QtyReport_Event_ID()); |
180,689 | protected <T> T cast(Object o, Class<T> clazz) {<NEW_LINE>if (UaEnumeration.class.isAssignableFrom(clazz) && o instanceof Integer) {<NEW_LINE>try {<NEW_LINE>Object enumeration = clazz.getMethod("from", new Class[] { Integer.class }).invoke(null, o);<NEW_LINE>return clazz.cast(enumeration);<NEW_LINE>} catch (IllegalAcce... | newInstance(componentType, xos.length); |
1,205,819 | public boolean canWrite(final File f) {<NEW_LINE>final Boolean[] ret = new Boolean[] { null };<NEW_LINE>for (Iterator<BaseAnnotationProvider> it = annotationProviders.iterator(); it.hasNext(); ) {<NEW_LINE><MASK><NEW_LINE>final InterceptionListener iListener = (provider != null) ? provider.getInterceptionListener() : n... | BaseAnnotationProvider provider = it.next(); |
1,043,897 | /*<NEW_LINE>* Look for missing type parameters @param tags<NEW_LINE>*/<NEW_LINE>private char[][] missingTypeParameterTags(Binding paramNameRefBinding, Scope scope) {<NEW_LINE>int paramTypeParamLength = this.paramTypeParameters == null ? 0 : this.paramTypeParameters.length;<NEW_LINE>// Verify if there's any type paramet... | ][], 0, size); |
1,731,325 | public static ListPhoneNumbersOfSkillGroupResponse unmarshall(ListPhoneNumbersOfSkillGroupResponse listPhoneNumbersOfSkillGroupResponse, UnmarshallerContext _ctx) {<NEW_LINE>listPhoneNumbersOfSkillGroupResponse.setRequestId(_ctx.stringValue("ListPhoneNumbersOfSkillGroupResponse.RequestId"));<NEW_LINE>listPhoneNumbersOf... | (_ctx.stringValue("ListPhoneNumbersOfSkillGroupResponse.Message")); |
35,290 | private static void writeExternal(@Nonnull Element element, @Nonnull ShelvedChangeList shelvedChangeList) throws WriteExternalException {<NEW_LINE>DefaultJDOMExternalizer.writeExternal(shelvedChangeList, element);<NEW_LINE>element.setAttribute(NAME_ATTRIBUTE, shelvedChangeList.getName());<NEW_LINE>element.setAttribute(... | .DATE.getTime())); |
67,104 | private void createPackageDeclaration(ModuleNode moduleNode) {<NEW_LINE>if (moduleNode.hasPackageName()) {<NEW_LINE>String packageName = moduleNode.getPackageName();<NEW_LINE>if (packageName.endsWith(".")) {<NEW_LINE>packageName = packageName.substring(0, packageName.length() - 1);<NEW_LINE>}<NEW_LINE>PackageNode packa... | createAnnotations(packageNode.getAnnotations()); |
1,527,112 | public static DatabaseType fromMetaData(DataSource dataSource) throws MetaDataAccessException {<NEW_LINE>String databaseProductName = JdbcUtils.extractDatabaseMetaData(dataSource, DatabaseMetaData::getDatabaseProductName);<NEW_LINE>if (StringUtils.hasText(databaseProductName) && databaseProductName.startsWith("DB2")) {... | extractDatabaseMetaData(dataSource, DatabaseMetaData::getDatabaseProductVersion); |
1,261,053 | public static Column createColumn(String name, Operation op, QueryState state, String prefix, String suffix) {<NEW_LINE>if (!name.equals("*")) {<NEW_LINE>name = Heading.findOriginal(state.originalSql(), name, prefix, suffix);<NEW_LINE>}<NEW_LINE>if (name.contains(".")) {<NEW_LINE>String head = name.split("\\.")[0];<NEW... | ), tr.getAlias()); |
1,184,094 | public DescribeAddonResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>DescribeAddonResult describeAddonResult = new DescribeAddonResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = context... | String currentParentElement = context.getCurrentParentElement(); |
1,338,249 | public void loadFrom(RootNode root) {<NEW_LINE>List<ClassNode> list = root.getClasses(true);<NEW_LINE>Map<String, ClspClass> names = new HashMap<>(list.size());<NEW_LINE>int k = 0;<NEW_LINE>for (ClassNode cls : list) {<NEW_LINE>ArgType clsType = cls.getClassInfo().getType();<NEW_LINE>String clsRawName = clsType.getObje... | setTypeParameters(cls.getGenericTypeParameters()); |
1,146,300 | private static Node ReactDatabaseSupplier(final ClassOrInterfaceDeclaration n) {<NEW_LINE>// ReactDatabaseSupplier(Context context)<NEW_LINE>{<NEW_LINE>ConstructorDeclaration c = new ConstructorDeclaration(EnumSet.of<MASK><NEW_LINE>NodeList<Parameter> parameters = NodeList.nodeList(new Parameter(JavaParser.parseClassOr... | (Modifier.PUBLIC), "ReactDatabaseSupplier"); |
257,502 | final AttachPolicyResult executeAttachPolicy(AttachPolicyRequest attachPolicyRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(attachPolicyRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExec... | endClientExecution(awsRequestMetrics, request, response); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.