idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,214,748 | public JavaThread addJavaThread(ImageThread imageThread, String name, long tid, long j9thread_t, long javaObjID, long jniEnv, String state, int priority, long blockingObject, String blockingObjectClass) throws BuilderFailureException {<NEW_LINE>try {<NEW_LINE>if (j9thread_t != IBuilderData.NOT_AVAILABLE && jniEnv != IB... | = new JCJavaObject(pointerObjectID, jClass); |
985,083 | public ShortestPathDeltaStepping compute(long startNode) {<NEW_LINE>// reset<NEW_LINE>for (int i = 0; i < nodeCount; i++) {<NEW_LINE>distance.set(i, Integer.MAX_VALUE);<NEW_LINE>}<NEW_LINE>buckets.reset();<NEW_LINE>// basically assign start node to bucket 0<NEW_LINE>relax(graph<MASK><NEW_LINE>// as long as the bucket c... | .toMappedNodeId(startNode), 0); |
97,052 | public List<Config> listConfigs(final Config.Criteria criteria) throws DockerException, InterruptedException {<NEW_LINE>assertApiVersionIsAbove("1.30");<NEW_LINE>final Map<String, List<String>> filters = new HashMap<>();<NEW_LINE>if (criteria.configId() != null) {<NEW_LINE>filters.put("id", Collections.singletonList(cr... | ("filters", urlEncodeFilters(filters)); |
954,265 | private void addContact(SourceUIContact contact) {<NEW_LINE>SourceContact sourceContact = (SourceContact) contact.getDescriptor();<NEW_LINE>List<ContactDetail> details = sourceContact.getContactDetails(OperationSetPersistentPresence.class);<NEW_LINE>int detailsCount = details.size();<NEW_LINE>if (detailsCount > 1) {<NE... | (new Separator(), 1); |
852,156 | private static int parseDotsConstraints(List<SmPLLexer.Token> tokens, int pos, StringBuilder output) {<NEW_LINE>int end = tokens.size();<NEW_LINE>int finalPos = pos;<NEW_LINE>String comma = "";<NEW_LINE>pos += 1;<NEW_LINE>while (pos < end) {<NEW_LINE>SmPLLexer.Token token = tokens.get(pos);<NEW_LINE>SmPLLexer.TokenType... | ()).append("()"); |
1,840,781 | private String importSinglePhoto(PhotoModel photo, UUID jobId, IdempotentImportExecutor idempotentImportExecutor, KoofrClient koofrClient) throws IOException, InvalidTokenException, DestinationMemoryFullException {<NEW_LINE>monitor.debug(() -> String.format("Import single photo %s", photo.getTitle()));<NEW_LINE>Buffere... | getConnection(photo.getFetchableUrl()); |
460,367 | private void updateJailsToNewJailsConfig() {<NEW_LINE>if (doneFile.getBoolean("updateJailsToNewJailsConfig", false)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>final File configFile = new File(ess.getDataFolder(), "jail.yml");<NEW_LINE>if (configFile.exists()) {<NEW_LINE>final EssentialsConfiguration config = new Essential... | ex.getMessage(), ex); |
570,354 | public JSONObject serviceImpl(Query post, HttpServletResponse response, Authorization rights, final JSONObjectWithDefault permissions) throws APIException {<NEW_LINE>JSONObject result = new JSONObject();<NEW_LINE>switch(post.get("show", "")) {<NEW_LINE>case "user-list":<NEW_LINE>if (permissions.getBoolean("list_users",... | result.put("user-roles", userRolesObj); |
36,585 | public static BatchGetPluginConfigInfoResponse unmarshall(BatchGetPluginConfigInfoResponse batchGetPluginConfigInfoResponse, UnmarshallerContext context) {<NEW_LINE>batchGetPluginConfigInfoResponse.setRequestId(context.stringValue("BatchGetPluginConfigInfoResponse.RequestId"));<NEW_LINE>batchGetPluginConfigInfoResponse... | (context.integerValue("BatchGetPluginConfigInfoResponse.Code")); |
918,607 | private void handleServiceRequest(String path, ServiceRequest serviceRequest) {<NEW_LINE>UaRequestMessage request = serviceRequest.getRequest();<NEW_LINE>if (logger.isTraceEnabled()) {<NEW_LINE>logger.trace("ServiceRequest received path={}, requestHandle={} request={}", path, request.getRequestHeader().getRequestHandle... | path, request.getTypeId()); |
102,718 | GroupConfig addGroup(String groupName) {<NEW_LINE>synchronized (SAVING_LOCK) {<NEW_LINE>if (DEBUG)<NEW_LINE>Debug.log(WindowManagerParser.<MASK><NEW_LINE>GroupParser groupParser = (GroupParser) groupParserMap.get(groupName);<NEW_LINE>if (groupParser != null) {<NEW_LINE>// NOI18N<NEW_LINE>PersistenceManager.LOG.// NOI18... | class, "WMParser.addGroup ENTER" + " group:" + groupName); |
1,101,297 | public CorrelateJoinPlan convertCorrelate(Correlate correlate) {<NEW_LINE>PhysicalPlan left = convert(correlate.getLeft());<NEW_LINE>PhysicalPlan right = convert(correlate.getRight());<NEW_LINE><MASK><NEW_LINE>List<Integer> requireList = correlate.getRequiredColumns().asList();<NEW_LINE>Map<CorrelationKey, List<Variabl... | CorrelationId correlationId = correlate.getCorrelationId(); |
1,190,785 | private void applyRequiredPolicies(List<HttpPipelinePolicy> policies, HttpPipelinePolicy authorizationPolicy) {<NEW_LINE>String clientName = properties.getOrDefault(SDK_NAME, "UnknownName");<NEW_LINE>String clientVersion = <MASK><NEW_LINE>ClientOptions buildClientOptions = (clientOptions == null) ? new ClientOptions() ... | properties.getOrDefault(SDK_VERSION, "UnknownVersion"); |
946,682 | public void endVisit(UnaryExpression x, BlockScope scope) {<NEW_LINE>try {<NEW_LINE>SourceInfo info = makeSourceInfo(x);<NEW_LINE>JUnaryOperator op;<NEW_LINE>int operator = ((x.bits & ASTNode.<MASK><NEW_LINE>switch(operator) {<NEW_LINE>case OperatorIds.MINUS:<NEW_LINE>op = JUnaryOperator.NEG;<NEW_LINE>break;<NEW_LINE>c... | OperatorMASK) >> ASTNode.OperatorSHIFT); |
678,871 | final SearchAddressBooksResult executeSearchAddressBooks(SearchAddressBooksRequest searchAddressBooksRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(searchAddressBooksRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetri... | addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint); |
487,739 | public static Cluster swapRandomPartitionsWithinZone(final Cluster nextCandidateCluster, final int zoneId) {<NEW_LINE>Cluster returnCluster = Cluster.cloneCluster(nextCandidateCluster);<NEW_LINE>Random r = new Random();<NEW_LINE>List<Integer> nodeIdsInZone = new ArrayList<Integer>(nextCandidateCluster.getNodeIdsInZone(... | nextInt(nodeIdsInZone.size()); |
1,762,997 | final CreateLayerResult executeCreateLayer(CreateLayerRequest createLayerRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createLayerRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTi... | addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig); |
1,316,941 | public PagePosition renderIntoArea(int x, int y, int width, int height, PagePosition current, int index) {<NEW_LINE>if (current.pixel + PIXEL_HEIGHT > height) {<NEW_LINE>current = current.newPage();<NEW_LINE>}<NEW_LINE>x += OFFSET.x;<NEW_LINE>y += OFFSET.y + current.pixel;<NEW_LINE>if (current.page == index) {<NEW_LINE... | + (int) OUT_POSITION.y); |
226,736 | protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3) {<NEW_LINE>GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);<NEW_LINE>bindGuiTexture(isSimple ? 1 : 0);<NEW_LINE>int sx = (width - xSize) / 2;<NEW_LINE>int sy = (height - ySize) / 2;<NEW_LINE>drawTexturedModalRect(sx, sy, 0, 0, <MASK><NEW_LINE>i... | this.xSize, this.ySize); |
1,196,789 | protected List<String> verifyKeyExists(List<MyNameValuePair> map, String type, String key, boolean ignoreKeyCase, boolean exists) throws WebBrowserException {<NEW_LINE>String methodName = "verifyKeyExists";<NEW_LINE>List<String> actualValue = this.getValue(map, key, ignoreKeyCase);<NEW_LINE>String keyName = this.getKey... | toString() + " should have a " + keyName); |
1,718,419 | final GetHomeRegionResult executeGetHomeRegion(GetHomeRegionRequest getHomeRegionRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getHomeRegionRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.Clien... | addHandlerContext(HandlerContextKey.SERVICE_ID, "MigrationHub Config"); |
840,766 | final DescribeCanariesLastRunResult executeDescribeCanariesLastRun(DescribeCanariesLastRunRequest describeCanariesLastRunRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeCanariesLastRunRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();... | (super.beforeMarshalling(describeCanariesLastRunRequest)); |
1,614,458 | public static BufferedImage resizeWithRatio(BufferedImage image, int destinationWidth, int destinationHeight) {<NEW_LINE>int type = image.getType() == 0 ? BufferedImage.TYPE_INT_ARGB : image.getType();<NEW_LINE>// *Special* if the width or height is 0 use image src dimensions<NEW_LINE>if (destinationWidth == 0) {<NEW_L... | Math.round(destinationHeight * sum); |
1,744,419 | public View onCreateView(@NonNull LayoutInflater inflater, @NonNull ViewGroup parent) {<NEW_LINE>final View view = inflater.inflate(R.<MASK><NEW_LINE>okHttpCacheMaxSizeView = view.findViewById(R.id.dd_debug_okhttp_cache_max_size);<NEW_LINE>okHttpCacheWriteErrorView = view.findViewById(R.id.dd_debug_okhttp_cache_write_e... | layout.dd_debug_drawer_module_okhttp, parent, false); |
139,049 | public static String formatDateTime19(Instant instant, ZoneId zoneId) {<NEW_LINE>ZonedDateTime zt = ZonedDateTime.ofInstant(instant, zoneId);<NEW_LINE>int year = zt.get(ChronoField.YEAR);<NEW_LINE>;<NEW_LINE>int month = zt.get(ChronoField.MONTH_OF_YEAR);<NEW_LINE>;<NEW_LINE>int dayOfMonth = zt.get(ChronoField.DAY_OF_MO... | ) (year / 1000 + '0'); |
706,569 | public void testSLLFutureGetTimesOutXml() throws Exception {<NEW_LINE>long currentThreadId = 0;<NEW_LINE>ResultsStatelessLocal bean = lookupSLLBean();<NEW_LINE>assertNotNull("Async Stateless Bean created successfully", bean);<NEW_LINE>// initialize latches<NEW_LINE>ResultsStatelessLocalFutureBean.svBeanLatch = new Coun... | .currentThread().getId(); |
552,821 | public void apply(Project project) {<NEW_LINE>this.project = project;<NEW_LINE>project.getPlugins().apply(JavaPlugin.class);<NEW_LINE>ContractVerifierExtension extension = project.getExtensions().create(EXTENSION_NAME, ContractVerifierExtension.class);<NEW_LINE>JavaPluginConvention javaConvention = project.getConventio... | contractTestSourceSet = configureSourceSets(extension, javaConvention); |
814,060 | private JComponent init() {<NEW_LINE>final JPanel result = new JPanel(new BorderLayout());<NEW_LINE>myLogModel = new DefaultListModel();<NEW_LINE>myLog = new JBList(myLogModel);<NEW_LINE>myLog.setCellRenderer(new FocusElementRenderer());<NEW_LINE>myAllocation = new JEditorPane();<NEW_LINE>final DefaultCaret caret = new... | getComponent(), BorderLayout.NORTH); |
667,798 | ResourceElem addChild(String name, ResourceElem child) {<NEW_LINE>if (!isFolder) {<NEW_LINE>children = new ArrayList<ResourceElem>();<NEW_LINE>names = new ArrayList<String>();<NEW_LINE>content = null;<NEW_LINE>isFolder = true;<NEW_LINE>}<NEW_LINE>// NOI18N<NEW_LINE>assert name != null && name.indexOf("/") == -1 : (chil... | = new HashSet<URL>(); |
677,878 | public RegisterAppInstanceUserEndpointResult registerAppInstanceUserEndpoint(RegisterAppInstanceUserEndpointRequest registerAppInstanceUserEndpointRequest) throws AmazonServiceException, AmazonClientException {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(registerAppInstanceUserEndpointRequest);<... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
442,993 | public boolean apply(Game game, Ability source) {<NEW_LINE>Player player = game.getPlayer(source.getControllerId());<NEW_LINE>if (player == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>Cards allCards = new CardsImpl(player.getLibrary().getTopCards(game, 3));<NEW_LINE>player.revealCards(source, allCards, game);<NE... | .getCards(game), game); |
1,175,591 | public Optional<RequestContainer> findRequestByIdish(String idish) {<NEW_LINE>Stack<String> splits = new Stack<String>();<NEW_LINE>splits.addAll(Arrays.asList(idish.split("/")));<NEW_LINE>if (splits.isEmpty()) {<NEW_LINE>throw new IllegalArgumentException("No id given");<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>Optional<Str... | String reqName = splits.pop(); |
938,356 | public void userConfirm(String token, final Response.Listener<AccessToken> responseListener, final Response.ErrorListener errorListener) {<NEW_LINE>Object postBody = null;<NEW_LINE>// verify the required parameter 'token' is set<NEW_LINE>if (token == null) {<NEW_LINE>VolleyError error = new VolleyError("Missing the req... | HashMap<String, String>(); |
140,506 | public CreateDatasetResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>CreateDatasetResult createDatasetResult = new CreateDatasetResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDep... | class).unmarshall(context)); |
574,660 | public SetDefaultAuthorizerResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>SetDefaultAuthorizerResult setDefaultAuthorizerResult = new SetDefaultAuthorizerResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentEleme... | class).unmarshall(context)); |
1,501,239 | public void visit(VisitableBuilder builder) {<NEW_LINE>Optional<String> resourceKind = Metadata.getKind(builder);<NEW_LINE>Optional<ObjectMeta> <MASK><NEW_LINE>if (!resourceKind.isPresent() || !objectMeta.isPresent()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (Utils.isNullOrEmpty(kind)) {<NEW_LINE>if (Utils.isNullOrEmp... | objectMeta = Metadata.getMetadata(builder); |
1,843,931 | protected ExecutionResult handleNonNullException(ExecutionContext executionContext, CompletableFuture<ExecutionResult> result, Throwable e) {<NEW_LINE>ExecutionResult executionResult = null;<NEW_LINE>List<GraphQLError> errors = ImmutableList.copyOf(executionContext.getErrors());<NEW_LINE>Throwable underlyingException =... | = new ExecutionResultImpl(null, errors); |
1,132,291 | public void initialize() {<NEW_LINE>this.viewModel = new GeneralPropertiesViewModel(databaseContext, dialogService, preferencesService, undoManager);<NEW_LINE>new ViewModelListCellFactory<Charset>().withText(Charset<MASK><NEW_LINE>encoding.disableProperty().bind(viewModel.encodingDisableProperty());<NEW_LINE>encoding.i... | ::displayName).install(encoding); |
564,219 | final DeleteMembersResult executeDeleteMembers(DeleteMembersRequest deleteMembersRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteMembersRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.Clien... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
1,211,221 | public void onBindViewHolder(ViewHolderFileStorage holder, int position) {<NEW_LINE>FileDocument document = currentFiles.get(position);<NEW_LINE>holder.textViewFileName.setText(document.getName());<NEW_LINE>if (document.isFolder()) {<NEW_LINE>String items = getNumberItemChildren(document.getFile());<NEW_LINE>holder.tex... | this.megaApi, this, position); |
75,326 | public void copySystemTag(String srcResourceUuid, String srcResourceType, String dstResourceUuid, String dstResourceType, boolean inherent) {<NEW_LINE>String sql = "select stag" <MASK><NEW_LINE>TypedQuery<SystemTagVO> srcq = dbf.getEntityManager().createQuery(sql, SystemTagVO.class);<NEW_LINE>srcq.setParameter("ruuid",... | + " from SystemTagVO stag" + " where stag.resourceUuid = :ruuid" + " and stag.resourceType = :rtype" + " and stag.inherent = :ih"; |
1,820,256 | private void calcTickPath(@NonNull RectF bounds) {<NEW_LINE>final float left = bounds.left;<NEW_LINE>final float right = bounds.right;<NEW_LINE>final float top = bounds.top;<NEW_LINE>final float bottom = bounds.bottom;<NEW_LINE>// #117 Leaving 2px gap from bottom<NEW_LINE>float extraBottomInset = 2;<NEW_LINE>float widt... | / Math.sqrt(2)); |
1,638,469 | public void openTorrent(String fileName, String save_path) {<NEW_LINE>String uc_filename = fileName.toUpperCase(Locale.US);<NEW_LINE>boolean is_remote = uc_filename.startsWith("HTTP://") || uc_filename.startsWith("HTTPS://") || uc_filename.startsWith("MAGNET:");<NEW_LINE>if (console != null) {<NEW_LINE>// System.out.pr... | save_path : COConfigurationManager.getDirectoryParameter("Default save path"); |
1,610,344 | public boolean process(ToOtaPackageStateServiceMsg msg) {<NEW_LINE>boolean isSuccess = false;<NEW_LINE>OtaPackageId targetOtaPackageId = new OtaPackageId(new UUID(msg.getOtaPackageIdMSB(), msg.getOtaPackageIdLSB()));<NEW_LINE>DeviceId deviceId = new DeviceId(new UUID(msg.getDeviceIdMSB(), msg.getDeviceIdLSB()));<NEW_LI... | valueOf(msg.getType()); |
622,619 | public boolean doesOperationExistForCeilingEntity(PermissionType permissionType, String ceilingEntityFullyQualifiedName) {<NEW_LINE>// the ceiling may be an impl, which will fail because entity permission is normally specified for the interface<NEW_LINE>// try the passed in ceiling first, but also try an interfaces imp... | ) interfaze).getName()); |
1,478,928 | /* (non-Javadoc)<NEW_LINE>* @see org.eclipse.ui.dialogs.FilteredItemsSelectionDialog#fillContentProvider(org.eclipse.ui.dialogs.FilteredItemsSelectionDialog.AbstractContentProvider, org.eclipse.ui.dialogs.FilteredItemsSelectionDialog.ItemsFilter, org.eclipse.core.runtime.IProgressMonitor)<NEW_LINE>*/<NEW_LINE>protected... | .getSpecManager().getRecentlyOpened(); |
1,718,094 | final RemoveTagsResult executeRemoveTags(RemoveTagsRequest removeTagsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(removeTagsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
277,807 | private void ajaxChangePermissions(final Project project, final HashMap<String, Object> ret, final HttpServletRequest req, final User user) throws ServletException {<NEW_LINE>final boolean admin = Boolean.parseBoolean(getParam(req, "permissions[admin]"));<NEW_LINE>final boolean read = Boolean.parseBoolean(getParam(req,... | (getParam(req, "permissions[schedule]")); |
1,612,969 | // find_among_b is for backwards processing. Same comments apply<NEW_LINE>protected int find_among_b(Among[] v) {<NEW_LINE>int i = 0;<NEW_LINE>int j = v.length;<NEW_LINE>int c = cursor;<NEW_LINE>int lb = limit_backward;<NEW_LINE>int common_i = 0;<NEW_LINE>int common_j = 0;<NEW_LINE>boolean first_key_inspected = false;<... | = common_i < common_j ? common_i : common_j; |
1,396,145 | final DeleteFileShareResult executeDeleteFileShare(DeleteFileShareRequest deleteFileShareRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteFileShareRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(F... | endClientExecution(awsRequestMetrics, request, response); |
138,368 | public void prepare(PreparedStatement statement) throws SQLException {<NEW_LINE>// Found for all providers<NEW_LINE>statement.setString(1, info.getName());<NEW_LINE>statement.setString(2, info.getText());<NEW_LINE>Sql.setStringOrNull(statement, 3, info.getDescription().orElse(null));<NEW_LINE>statement.setInt(4, info.g... | info.getPluginName(), serverUUID); |
824,426 | private boolean sameScalar(ScalarValue want, JsonObject parent, String name) throws Exception {<NEW_LINE>trace("comparing object scalar property " + name);<NEW_LINE><MASK><NEW_LINE>if (want instanceof StringValue) {<NEW_LINE>return sameString(((StringValue) want).getValue(), regexp, parent.getString(name));<NEW_LINE>}<... | String regexp = want.getRegexp(); |
1,223,865 | public void marshall(RegionDescription regionDescription, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (regionDescription == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(regionDescription.getDirectoryId(... | regionDescription.getDesiredNumberOfDomainControllers(), DESIREDNUMBEROFDOMAINCONTROLLERS_BINDING); |
1,056,924 | final DescribeScalingActivitiesResult executeDescribeScalingActivities(DescribeScalingActivitiesRequest describeScalingActivitiesRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeScalingActivitiesRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequest... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
158,022 | protected Control createDialogArea(Composite parent) {<NEW_LINE>Composite area = (Composite) super.createDialogArea(parent);<NEW_LINE>Composite editArea = new <MASK><NEW_LINE>FormLayout layout = new FormLayout();<NEW_LINE>layout.marginWidth = 5;<NEW_LINE>layout.marginHeight = 5;<NEW_LINE>editArea.setLayout(layout);<NEW... | Composite(area, SWT.NONE); |
653,502 | private RemittanceAdviceLineInvoiceDetails buildInvoiceDetailsForRemittanceLine(@NonNull final I_C_Invoice invoice, @NonNull final RemittanceAdvice remittanceAdvice, @NonNull final RemittanceAdviceLine remittanceAdviceLine) {<NEW_LINE>final CurrencyCode remittanceAdviceCurrencyCode = remittanceAdviceLine.getRemittedAmo... | (Amount.zero(remittanceAdviceCurrencyCode)); |
1,162,146 | private static void writeInspectionDiff(final String oldPath, final String newPath, final String outPath) {<NEW_LINE>try {<NEW_LINE>InputStream oldStream = oldPath != null ? new BufferedInputStream(new FileInputStream(oldPath)) : null;<NEW_LINE>InputStream newStream = new <MASK><NEW_LINE>Document oldDoc = oldStream != ... | BufferedInputStream(new FileInputStream(newPath)); |
1,347,589 | private void doSearch(ActionEvent e) {<NEW_LINE>boolean expand = e.getSource() == searchAndExpandButton;<NEW_LINE><MASK><NEW_LINE>if (StringUtils.isEmpty(wordToSearch)) {<NEW_LINE>this.lastSearchConditions = null;<NEW_LINE>return;<NEW_LINE>} else {<NEW_LINE>this.lastSearchConditions = Triple.of(wordToSearch, isCaseSens... | String wordToSearch = searchTF.getText(); |
1,593,557 | protected void encodeLabel(FacesContext context, CascadeSelect cascadeSelect, List<SelectItem> itemList, String valueToRender) throws IOException {<NEW_LINE>ResponseWriter writer = context.getResponseWriter();<NEW_LINE>Converter converter = ComponentUtils.getConverter(context, cascadeSelect);<NEW_LINE>String itemLabel ... | writeAttribute("class", styleClass, null); |
914,542 | static int encodeUTF8(CharSequence text, boolean nullTerminated, long target) {<NEW_LINE>int i = 0, len = text.length(), p = 0;<NEW_LINE>char c;<NEW_LINE>// ASCII fast path<NEW_LINE>while (i < len && (c = text.charAt(i)) < 0x80) {<NEW_LINE>UNSAFE.putByte(target + p++, (byte) c);<NEW_LINE>i++;<NEW_LINE>}<NEW_LINE>// Slo... | text.charAt(i++)); |
666,821 | public void configure(Map conf) {<NEW_LINE>this.stormConf = conf;<NEW_LINE>topic = getConfig("kafka.topic", "jstorm");<NEW_LINE>zkRoot = getConfig("storm.zookeeper.root", "/jstorm");<NEW_LINE>String zkHosts = getConfig("kafka.zookeeper.hosts", "127.0.0.1:2181");<NEW_LINE>zkServers = convertHosts(zkHosts, 2181);<NEW_LIN... | ("kafka.socket.receive.buffer.bytes"), 64 * 1024); |
1,502,074 | public StartupCommand[] initialize() {<NEW_LINE>Map<String, MockVMVO> vmsMaps = _simMgr.getVms(this.hostGuid);<NEW_LINE>totalCpu = agentHost.getCpuCount() * agentHost.getCpuSpeed();<NEW_LINE>totalMem = agentHost.getMemorySize();<NEW_LINE>for (Map.Entry<String, MockVMVO> entry : vmsMaps.entrySet()) {<NEW_LINE>MockVMVO v... | HypervisorType.Simulator, RouterPrivateIpStrategy.HostLocal); |
245,435 | private void processExternalSystemRequest(@NonNull final Exchange exchange) {<NEW_LINE>final var request = exchange.getIn().getBody(JsonExternalSystemRequest.class);<NEW_LINE>exchange.getIn().setHeader(HEADER_TARGET_ROUTE, request.getExternalSystemName().getName() + <MASK><NEW_LINE>exchange.getIn().setHeader(HEADER_TRA... | "-" + request.getCommand()); |
340,466 | private CharSequence generateCCharPointerBinaryOutputInit(CodeBuilder builder, CharSequence marshalledParametersOutputVar, MethodData methodData, List<Integer> customParameters, CharSequence staticBufferVar, int staticBufferSize) {<NEW_LINE>CharSequence sizeVar = "marshalledParametersSizeEstimate";<NEW_LINE>List<? exte... | index).getSimpleName())); |
858,764 | public IAllocationResult unload(final IAllocationRequest request) {<NEW_LINE>//<NEW_LINE>// If there are no sources, we have nothing to unload<NEW_LINE>if (sources.isEmpty()) {<NEW_LINE>return AllocationUtils.nullResult();<NEW_LINE>}<NEW_LINE>//<NEW_LINE>// Create the inial result: we are starting from how much we need... | createMutableAllocationResult(request.getQty()); |
813,344 | final EnableSecurityHubResult executeEnableSecurityHub(EnableSecurityHubRequest enableSecurityHubRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(enableSecurityHubRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.st... | endClientExecution(awsRequestMetrics, request, response); |
405,508 | public void decorate(T webComponent, WebModule wm) {<NEW_LINE>if (wm.getWebBundleDescriptor().hasExtensionProperty(WeldDeployer.WELD_EXTENSION)) {<NEW_LINE>DeploymentContext deploymentContext = wm.getWebModuleConfig().getDeploymentContext();<NEW_LINE>WeldBootstrap weldBootstrap = deploymentContext.getTransientAppMetaDa... | WeldDeployer.WELD_DEPLOYMENT, DeploymentImpl.class); |
167,621 | private static void runAssertion(RegressionEnvironment env, String eventTypeName, RegressionPath path) {<NEW_LINE>String stmtText = "@name('s0') select type?,dyn[1]?,nested.nes2?,map('a')? from " + eventTypeName;<NEW_LINE>env.compileDeploy(stmtText, path).addListener("s0");<NEW_LINE>env.assertStatement("s0", statement ... | ("map('a')?", Node.class)); |
1,584,544 | public List<SipURI> locate(SipURI sipUri) throws SipURIResolveException {<NEW_LINE>if (c_logger.isTraceEntryExitEnabled()) {<NEW_LINE>c_logger.traceEntry(this, "locate", sipUri);<NEW_LINE>}<NEW_LINE>if (!_initialized) {<NEW_LINE>throw new SipURIResolveException("Resolver service not initialized.");<NEW_LINE>}<NEW_LINE>... | throw new SipURIResolveException("Failed to retrieve DNS result", e); |
276,877 | final UpdateSecurityGroupRuleDescriptionsEgressResult executeUpdateSecurityGroupRuleDescriptionsEgress(UpdateSecurityGroupRuleDescriptionsEgressRequest updateSecurityGroupRuleDescriptionsEgressRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(updateSecurityGroupRuleDescriptionsEgressRequest... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
721,474 | private void startOperation(int op, @Nullable String[] backupNames) {<NEW_LINE>if (actionBeginInterface != null)<NEW_LINE>actionBeginInterface.onActionBegin(mode);<NEW_LINE>activity.registerReceiver(mBatchOpsBroadCastReceiver, new IntentFilter(BatchOpsService.ACTION_BATCH_OPS_COMPLETED));<NEW_LINE>// Start batch ops se... | ARG_FLAGS, flags.getFlags()); |
760,826 | public void sealAndInitialize(FhirContext theContext, Map<Class<? extends IBase>, BaseRuntimeElementDefinition<?>> theClassToElementDefinitions) {<NEW_LINE>super.sealAndInitialize(theContext, theClassToElementDefinitions);<NEW_LINE>myNameToSearchParam = Collections.unmodifiableMap(myNameToSearchParam);<NEW_LINE>ArrayLi... | , new ArrayList<>()); |
1,090,381 | public static void main(String[] args) throws PcapNativeException, NotOpenException {<NEW_LINE>String filter = args.length != 0 ? args[0] : "";<NEW_LINE>System.out.println(COUNT_KEY + ": " + COUNT);<NEW_LINE>System.out.println(READ_TIMEOUT_KEY + ": " + READ_TIMEOUT);<NEW_LINE>System.out.println(SNAPLEN_KEY + ": " + SNA... | PcapHandle handle = phb.build(); |
311,395 | private void scanFile(MediaFile file, MusicFolder musicFolder, MediaLibraryStatistics statistics, Map<String, AtomicInteger> albumCount, Map<String, Artist> artists, Map<String, Album> albums, Map<Integer, Album> albumsInDb, Genres genres, Map<Integer, Set<String>> encountered) {<NEW_LINE>if (scanCount.incrementAndGet(... | incrementTotalLengthInBytes(file.getFileSize()); |
965,106 | private void printFillBorder2() {<NEW_LINE>String typeCast = imageType.getTypeCastFromSum();<NEW_LINE>out.print("\tpublic static void fillBorder( " + imageName + " input, " + imageType.getSumType() + " value, int borderX0, int borderY0, int borderX1, int borderY1 ) {\n" + "\t\t// top and bottom\n" + "\t\tfor (int y = 0... | "\t\t\t\tsrcIdx += input.stride;\n" + "\t\t\t}\n" + "\t\t}\n" + "\t}\n\n"); |
263 | public Optional<ListMultimapProperty> create(Config config) {<NEW_LINE>Property property = config.getProperty();<NEW_LINE>DeclaredType type = maybeDeclared(property.getType()).orElse(null);<NEW_LINE>if (!erasesToAnyOf(type, Multimap.class, ImmutableMultimap.class, ListMultimap.class, ImmutableListMultimap.class)) {<NEW... | valueType, config.getTypes()); |
352,657 | public PropertyNamingStrategy create() {<NEW_LINE>if (String.class.isInstance(value)) {<NEW_LINE>final String val = value.toString();<NEW_LINE>switch(val) {<NEW_LINE>case PropertyNamingStrategy.IDENTITY:<NEW_LINE>return propertyName -> propertyName;<NEW_LINE>case PropertyNamingStrategy.LOWER_CASE_WITH_DASHES:<NEW_LINE>... | (space.translateName(propertyName)); |
1,049,857 | public static void main(String[] args) {<NEW_LINE>assert 1 + 2 == 3;<NEW_LINE>try {<NEW_LINE>assert 2 == 3;<NEW_LINE>throw new RuntimeException("Failed to throw assert!");<NEW_LINE>} catch (AssertionError expected) {<NEW_LINE>// Success<NEW_LINE>assert expected.getMessage() == null;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>a... | == 3 : new RuntimeException("42"); |
654,557 | private void insertChar(final char c) {<NEW_LINE>checkSize(size + 3);<NEW_LINE>System.arraycopy(tree, idx, tree, idx + 3, size - idx);<NEW_LINE>tree[idx] = c;<NEW_LINE>tree[idx + 1] = 0;<NEW_LINE>tree[idx + 2] = 0;<NEW_LINE>size += 3;<NEW_LINE>for (int i = 0; i < size; ) {<NEW_LINE>if (tree[i] == LAST_CHAR) {<NEW_LINE>... | char) (index >> 16); |
1,617,091 | public int calculateMinBroadcastConnections(List<BtcNodes.BtcNode> nodes) {<NEW_LINE>BtcNodes.BitcoinNodesOption nodesOption = BtcNodes.BitcoinNodesOption.values()[preferences.getBitcoinNodesOptionOrdinal()];<NEW_LINE>int result;<NEW_LINE>switch(nodesOption) {<NEW_LINE>case CUSTOM:<NEW_LINE>// We have set the nodes alr... | nodes.size() * 0.5); |
949,051 | public Vector filterUp(double threshold) {<NEW_LINE>IntIntSparseVectorStorage newStorage = new IntIntSparseVectorStorage(size());<NEW_LINE>if (storage.isDense()) {<NEW_LINE>int[] values = ((IntIntVectorStorage) storage).getValues();<NEW_LINE>for (int i = 0; i < values.length; i++) {<NEW_LINE>if (values[i] >= threshold)... | int value = entry.getIntValue(); |
1,118,292 | public <T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11> Record11<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11> fetchSingle(SelectField<T1> field1, SelectField<T2> field2, SelectField<T3> field3, SelectField<T4> field4, SelectField<T5> field5, SelectField<T6> field6, SelectField<T7> field7, SelectField<T8> field8, SelectF... | field8, field9, field10, field11); |
1,159,731 | public Observable<ServiceResponseWithHeaders<Page<JobPreparationAndReleaseTaskExecutionInformation>, JobListPreparationAndReleaseTaskStatusHeaders>> listPreparationAndReleaseTaskStatusNextSinglePageAsync(final String nextPageLink) {<NEW_LINE>if (nextPageLink == null) {<NEW_LINE>throw new IllegalArgumentException("Param... | String.format("%s", nextPageLink); |
1,083,346 | public void run() throws CLIException {<NEW_LINE>File launch = new File(getCwd(), ".vscode/launch.json");<NEW_LINE>if (!launch.exists()) {<NEW_LINE>final File vscode = new File(getCwd(), ".vscode");<NEW_LINE>if (!vscode.exists() && !vscode.mkdirs()) {<NEW_LINE>fatal("Failed to mkdir .vscode");<NEW_LINE>}<NEW_LINE>try (... | fatal(e.getMessage()); |
52,181 | public Client client() {<NEW_LINE>String serverAddr = <MASK><NEW_LINE>if (StringUtils.isBlank(serverAddr)) {<NEW_LINE>throw new DiscoveryException(EtcdConstant.ETCD_SERVER_ADDR + " can't be null or empty");<NEW_LINE>}<NEW_LINE>ClientBuilder clientBuilder = Client.builder().endpoints(serverAddr);<NEW_LINE>String usernam... | environment.getProperty(EtcdConstant.ETCD_SERVER_ADDR); |
1,206,744 | protected static String handleMenu(String menuPrefix, Map<String, Object> submenus, List<String> items, Map<String, String> uuidToName) {<NEW_LINE>if (items == null) {<NEW_LINE>return "";<NEW_LINE>}<NEW_LINE>// Calculate indent from our current one<NEW_LINE>int spaces = menuPrefix.length() - menuPrefix.trim().length();... | (menuPrefix).append(".separator\n"); |
375,411 | private static synchronized File createFallbackPOM(String groupId, String artifactId, String version) throws IOException {<NEW_LINE>String k = groupId + ':' + artifactId + ':' + version;<NEW_LINE>File fallbackPOM = fallbackPOMs.get(k);<NEW_LINE>if (fallbackPOM == null) {<NEW_LINE>fallbackPOM = File.createTempFile("fall... | println("<version>" + version + "</version>"); |
1,541,267 | final DeleteStreamResult executeDeleteStream(DeleteStreamRequest deleteStreamRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteStreamRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExec... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
1,763,445 | public void readFields(DataInput in) throws IOException {<NEW_LINE>super.readFields(in);<NEW_LINE>int size = in.readInt();<NEW_LINE>for (int i = 0; i < size; i++) {<NEW_LINE>long partitionId = in.readLong();<NEW_LINE>int size2 = in.readInt();<NEW_LINE>Map<Long, Long> tabletIdMap = partitionIdToBaseRollupTabletIdMap.com... | column = Column.read(in); |
627,681 | private void rewriteTransactionTypeTablePart2() throws Exception {<NEW_LINE>if (!tableExists("transaction_type_temp")) {<NEW_LINE>// previously failed mid-upgrade prior to updating schema version<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>dropTableIfExists("transaction_type");<NEW_LINE>Map<String, V09AgentRollup> v09AgentRol... | 0, v09AgentRollup.agentRollupId()); |
1,356,579 | private void processFile(File file, String license) {<NEW_LINE>try {<NEW_LINE>String <MASK><NEW_LINE>int indexOfPackageStart = content.indexOf("package ");<NEW_LINE>if (indexOfPackageStart != -1) {<NEW_LINE>int indexOfPackageEnd = content.indexOf(";", indexOfPackageStart + 1);<NEW_LINE>int indexOfFirstImport = content.... | content = FileUtils.readFileToString(file); |
1,034,907 | public JSONObject installAllPackages(String kubeconfig, JSONObject jsonEnvMap) throws IOException, InterruptedException, TimeoutException {<NEW_LINE>JSONObject result = new JSONObject();<NEW_LINE>for (String clientName : this.clientPackageService.getNames()) {<NEW_LINE>JSONObject clientInfo = this.clientPackageService.... | info("{},deployCommand={}", clientName, runCommand); |
637,487 | // figure out name for the connection - to be used in mbean<NEW_LINE>private String composeName(String id) {<NEW_LINE>StringBuilder shortSourcesListBuilder = new StringBuilder();<NEW_LINE>String separatorChar = "[";<NEW_LINE>for (DatabusSubscription sub : getSubscriptions()) {<NEW_LINE>shortSourcesListBuilder.append(se... | null ? "" : "_" + id); |
202,571 | public Config createConfig(Config config) {<NEW_LINE>super.createConfig(config);<NEW_LINE>if (ciphersuiteDelegate.getCipherSuites() == null) {<NEW_LINE>List<CipherSuite> <MASK><NEW_LINE>cipherSuites.add(CipherSuite.TLS_RSA_WITH_AES_128_CBC_SHA);<NEW_LINE>cipherSuites.add(CipherSuite.TLS_RSA_WITH_AES_256_CBC_SHA);<NEW_L... | cipherSuites = new LinkedList<>(); |
1,798,754 | public void refreshUserSubstitutions() {<NEW_LINE>component.removeAllComponents();<NEW_LINE>UserSessionSource uss = <MASK><NEW_LINE>List<UserSubstitution> substitutions = getUserSubstitutions();<NEW_LINE>AppUI ui = AppUI.getCurrent();<NEW_LINE>User currentOrSubstitutedUser = uss.getUserSession().getCurrentOrSubstituted... | beanLocator.get(UserSessionSource.NAME); |
552,593 | // region Methods for converting native to Kroll values<NEW_LINE>private void fillFrequencyFields() {<NEW_LINE>// reused variables in different cases<NEW_LINE>String days;<NEW_LINE>String byDay;<NEW_LINE>if (this.frequency != null) {<NEW_LINE>switch(this.frequency) {<NEW_LINE>case YEARLY:<NEW_LINE>Calendar cal = Calend... | byDay = matchExpression(".*(BYDAY=[,0-9A-Z]*).*", 6); |
1,160,047 | void recordPanacheEntityPersistenceUnits(PanacheHibernateOrmRecorder recorder, Optional<JpaModelPersistenceUnitMappingBuildItem> jpaModelPersistenceUnitMapping, Set<String> panacheEntityClasses) {<NEW_LINE>Map<String, String> panacheEntityToPersistenceUnit = new HashMap<>();<NEW_LINE>if (jpaModelPersistenceUnitMapping.... | iterator().next()); |
1,577,801 | public Message processRequest0(final RaftServerService service, final AppendEntriesRequest request, final RpcRequestClosure done) {<NEW_LINE>final Node node = (Node) service;<NEW_LINE>if (node.getRaftOptions().isReplicatorPipeline()) {<NEW_LINE>final String groupId = request.getGroupId();<NEW_LINE>final PeerPair pair =... | done.getRpcCtx(), response); |
1,370,647 | protected void onCreate(Bundle savedInstanceState) {<NEW_LINE>TiApplication tiApp = getTiApp();<NEW_LINE>// If this is a TiJSActivity derived class created via "tiapp.xml" <activity/> tags,<NEW_LINE>// then destroy it now and launch the root activity instead with the JSActivity's intent.<NEW_LINE>// Note: This feature ... | mainIntent.addFlags(Intent.FLAG_ACTIVITY_FORWARD_RESULT); |
1,085,174 | public void process(MarvinImage a_imageIn, MarvinImage a_imageOut, MarvinAttributes a_attributesOut, MarvinImageMask a_mask, boolean a_previewMode) {<NEW_LINE>width = a_imageIn.getWidth();<NEW_LINE>height = a_imageIn.getHeight();<NEW_LINE>mat1 = new double[width][height];<NEW_LINE>mat2 = new double[width][height];<NEW_... | new double[width][height]; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.