idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
93,639 | final CalculateRouteResult executeCalculateRoute(CalculateRouteRequest calculateRouteRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(calculateRouteRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.... | addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint); |
82,630 | public void initialize(ClassLoadHelper loadHelper, SchedulerSignaler signaler) throws SchedulerConfigException {<NEW_LINE>// Absolutely needs thread-bound DataSource to initialize.<NEW_LINE>this.dataSource = SchedulerFactoryBean.getConfigTimeDataSource();<NEW_LINE>if (this.dataSource == null) {<NEW_LINE>throw new Sched... | productName = JdbcUtils.commonDatabaseName(productName); |
812,587 | public int handleTask(ConsoleWrapper stdin, PrintStream stdout, PrintStream stderr, String[] args) throws Exception {<NEW_LINE>setTaskIO(new TaskIO<MASK><NEW_LINE>setTaskArgs(args);<NEW_LINE>JobInstance jobInstance;<NEW_LINE>JobExecution jobExecution;<NEW_LINE>long executionId = resolveJobExecutionId();<NEW_LINE>if (ex... | (stdin, stdout, stderr)); |
1,316,985 | void buildNumTypes() {<NEW_LINE>Scope bnt = BaseNum.getTable();<NEW_LINE>String[] num_methods_num = { "__abs__", "__add__", "__coerce__", "__div__", "__divmod__", "__eq__", "__float__", "__floordiv__", "__format__", "__ge__", "__getformat__", "__gt__", "__int__", "__le__", "__long__", "__lt__", "__mod__", "__mul__", "_... | "__rtruediv__", "__sub__", "__truediv__", "conjugate" }; |
798,363 | public void changePermissions() {<NEW_LINE>logDebug("changePermissions");<NEW_LINE>notifyDataSetChanged();<NEW_LINE>int nodeType = checkBackupNodeTypeByHandle(megaApi, node);<NEW_LINE>if (nodeType != BACKUP_NONE) {<NEW_LINE>showWarningDialog();<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>dialogBuilder.setTitle(getString<MASK>... | (R.string.file_properties_shared_folder_permissions)); |
270,476 | public void handle(final ErrorCode errCode, Map data) {<NEW_LINE>extEmitter.failedToRebootVm(VmInstanceInventory.valueOf(self), errCode);<NEW_LINE>if (HostErrors.FAILED_TO_STOP_VM_ON_HYPERVISOR.isEqual(errCode.getCode()) || HostErrors.FAILED_TO_START_VM_ON_HYPERVISOR.isEqual(errCode.getCode())) {<NEW_LINE>checkState(or... | getUuid()).update(); |
1,097,150 | final ListUsersResult executeListUsers(ListUsersRequest listUsersRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listUsersRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_L... | endClientExecution(awsRequestMetrics, request, response); |
1,293,400 | public void addActionsToAdapter(final double latitude, final double longitude, final ContextMenuAdapter adapter, Object selectedObj, boolean configureMenu) {<NEW_LINE>GpxSelectionHelper gpxHelper = app.getSelectedGpxHelper();<NEW_LINE>adapter.addItem(new ContextMenuItem(MAP_CONTEXT_MENU_ADD_ID).setTitleId(selectedObj i... | (ADD_GPX_WAYPOINT_ITEM_ORDER).setListener(listener); |
14,712 | private void renderVSync(RenderContext ctx, Repainter repainter, Panel panel, VSync vsync) {<NEW_LINE>ctx.trace("VSync", () -> {<NEW_LINE>VSync.Data data = vsync.getData(state.toRequest(), TrackPanel.onUiThread(state, () -> repainter.repaint(new Area(0, 0, width, height))));<NEW_LINE>if (data == null) {<NEW_LINE>return... | double h = panel.getPreferredHeight(); |
509,057 | public static void main(final String[] a) {<NEW_LINE>final long n = Long.parseLong(a[0]);<NEW_LINE>final long incr = Long.MAX_VALUE / (n / 2);<NEW_LINE>long start, elapsed;<NEW_LINE>for (int k = 10; k-- != 0; ) {<NEW_LINE>System.out.print("Broadword msb: ");<NEW_LINE>start = System.currentTimeMillis();<NEW_LINE>for (lo... | System.out.print("java.lang lsb: "); |
1,357,419 | protected void read(CompoundTag compound, boolean clientPacket) {<NEW_LINE>super.read(compound, clientPacket);<NEW_LINE>inputInventory.deserializeNBT<MASK><NEW_LINE>outputInventory.deserializeNBT(compound.getCompound("OutputItems"));<NEW_LINE>preferredSpoutput = null;<NEW_LINE>if (compound.contains("PreferredSpoutput")... | (compound.getCompound("InputItems")); |
1,657,675 | private void selectCurrentValue() {<NEW_LINE><MASK><NEW_LINE>if (editorControl != null && !editorControl.isDisposed()) {<NEW_LINE>try {<NEW_LINE>Object curValue = valueEditor.extractEditorValue();<NEW_LINE>final String curTextValue = valueController.getValueHandler().getValueDisplayString(((IAttributeController) valueC... | Control editorControl = valueEditor.getControl(); |
835,046 | public int onUpdate(int type) {<NEW_LINE>if (type == Level.BLOCK_UPDATE_RANDOM && (getDamage() & 0b00001100) == 0x00) {<NEW_LINE><MASK><NEW_LINE>getLevel().setBlock(this, this, false, false);<NEW_LINE>} else if (type == Level.BLOCK_UPDATE_RANDOM) {<NEW_LINE>if ((getDamage() & 0b00001100) == 0x08) {<NEW_LINE>setDamage(g... | setDamage(getDamage() | 0x08); |
866,204 | public void parNewConcurrentModeFailureMeta(GCLogTrace trace, String line) {<NEW_LINE>double totalPause = trace.getPauseTime();<NEW_LINE>double concurrentModeFailurePause = trace.getDoubleGroup(19);<NEW_LINE>double startTimeGap = trace.getDoubleGroup(12) - getClock().getTimeStamp();<NEW_LINE>ParNewPromotionFailed parNe... | tenured = trace.getOccupancyBeforeAfterWithMemoryPoolSizeSummary(13); |
1,141,922 | private Command newMergedCommand(final Map<Object, Command> mergeCommands, final int mergeCount, final CommandCollector commandCollector, final CommandType commandType) {<NEW_LINE>if (this.protocol == Protocol.Text) {<NEW_LINE>String resultKey = (String) commandCollector.getResult();<NEW_LINE>byte[] keyBytes = ByteUtil... | resultKey, keyBytes, commandType, null); |
794,292 | private void addAttribute(JTextComponent c, Document d, String text) throws BadLocationException {<NEW_LINE>String nsPrefix = ctx.findFxmlNsPrefix();<NEW_LINE>boolean addNsDecl = false;<NEW_LINE>// declare the namespace, if not yet present<NEW_LINE>if (nsPrefix == null) {<NEW_LINE>nsPrefix = ctx.findPrefixString(<MASK>... | JavaFXEditorUtils.FXML_FX_NAMESPACE_CURRENT, JavaFXEditorUtils.FXML_FX_PREFIX); |
923,501 | protected int sigwait(Emulator<?> emulator) {<NEW_LINE>RegisterContext context = emulator.getContext();<NEW_LINE>Pointer set = context.getPointerArg(0);<NEW_LINE>Pointer sig = context.getPointerArg(1);<NEW_LINE>int mask = set.getInt(0);<NEW_LINE>Task task = emulator.get(Task.TASK_KEY);<NEW_LINE>SigSet sigSet = new Unix... | LogFactory.getLog(AbstractEmulator.class); |
289,167 | public static void main(final String[] args) {<NEW_LINE>final int numElementsX = (args.length == 2) ? Integer.parseInt(args[0]) : 8;<NEW_LINE>final int numElementsY = (args.length == 2) ? Integer.parseInt(args[1]) : 8;<NEW_LINE>System.out.printf("image: x=%d, y=%d\n", numElementsX, numElementsY);<NEW_LINE>final ImageFl... | System.out.println("Before:"); |
1,005,686 | static Color[] terrain(int n, float alpha) {<NEW_LINE>int k = n / 2;<NEW_LINE>float[] H = { 4 / 12f, 2 / 12f, 0 / 12f };<NEW_LINE>float[] S = { 1f, 1f, 0f };<NEW_LINE>float[] V = { 0.65f, 0.9f, 0.95f };<NEW_LINE>Color[] palette = new Color[n];<NEW_LINE>float h = H[0];<NEW_LINE>float hw = (H[1] - H[0<MASK><NEW_LINE>floa... | ]) / (k - 1); |
789,139 | public void actionPerformed(ActionEvent e) {<NEW_LINE>if (noproxy.isSelected()) {<NEW_LINE>pref.putInt("proxySel", 1);<NEW_LINE>} else if (systemProxy.isSelected()) {<NEW_LINE>pref.putInt("proxySel", 2);<NEW_LINE>} else if (manual.isSelected()) {<NEW_LINE>pref.putInt("proxySel", 3);<NEW_LINE>pref.put("proxySel-http", h... | "proxySel-port", port.getText()); |
44,218 | public void execute() throws BuildException {<NEW_LINE>if (name == null)<NEW_LINE>throw new BuildException("Name of property to set have to be specified", this.getLocation());<NEW_LINE>if (propertiesList == null)<NEW_LINE>throw new BuildException("List of clusters have to be specified", this.getLocation());<NEW_LINE>th... | .getOwningTarget().getName(); |
1,688,755 | private void checkAuthnStatement(List<AuthnStatement> authnStatements) {<NEW_LINE>if (authnStatements.size() != 1) {<NEW_LINE>throw samlException("SAML Assertion subject contains [{}] Authn Statements while exactly one was expected.", authnStatements.size());<NEW_LINE>}<NEW_LINE>final AuthnStatement authnStatement = au... | .getSpConfiguration().getReqAuthnCtxClassRef(); |
1,350,507 | protected void processHandlerMethodException(HandlerMethod handlerMethod, Exception exception, Message<?> message) {<NEW_LINE>InvocableHandlerMethod invocable = getExceptionHandlerMethod(handlerMethod, exception);<NEW_LINE>if (invocable == null) {<NEW_LINE>logger.error("Unhandled exception from message handler method",... | MethodParameter returnType = invocable.getReturnType(); |
744,561 | public static void main(String[] args) {<NEW_LINE>if (args.length < minArgs) {<NEW_LINE>System.out.println(usage.toString());<NEW_LINE>System.exit(-1);<NEW_LINE>}<NEW_LINE>TreebankLangParserParams tlpp = new EnglishTreebankParserParams();<NEW_LINE>DiskTreebank tb = null;<NEW_LINE>String encoding = "UTF-8";<NEW_LINE>Str... | .loadPath(args[i]); |
1,336,435 | /* Copied from BlockProcessor (with modifications). */<NEW_LINE>boolean rewardBeneficiary(final MutableWorldState worldState, final ProcessableBlockHeader header, final List<BlockHeader> ommers, final Address miningBeneficiary, final Wei blockReward, final boolean skipZeroBlockRewards) {<NEW_LINE>// TODO(tmm): Added to... | getOrCreate(ommerHeader.getCoinbase()); |
1,007,870 | private CompiledSelection generateCSForSelectAll() {<NEW_LINE>MetaStreamEvent metaStreamEventForSelectAll = new MetaStreamEvent();<NEW_LINE>for (Attribute attribute : tableDefinition.getAttributeList()) {<NEW_LINE>metaStreamEventForSelectAll.addOutputData(attribute);<NEW_LINE>}<NEW_LINE>metaStreamEventForSelectAll.addI... | attribute.getName()))); |
713,629 | // findBPartner<NEW_LINE>@Override<NEW_LINE>public void refreshPanel() {<NEW_LINE>logger.fine("RefreshPanel");<NEW_LINE>if (!posPanel.hasOrder()) {<NEW_LINE>// Document Info<NEW_LINE>totalTitle.setTitle(Msg.getMsg(Env.getCtx(), "Totals"));<NEW_LINE>fieldSalesRep.setText(posPanel.getSalesRepName());<NEW_LINE>fieldDocume... | setText(posPanel.getBPName()); |
18,946 | private JXTitledPanel createImageBox(JPanel p, JDialog dialog, int width, int height, CFrame window) {<NEW_LINE>BufferedImage bi = new // TYPE_INT_ARGB is tinted red<NEW_LINE>BufferedImage(// TYPE_INT_ARGB is tinted red<NEW_LINE>window.getWidth(), // TYPE_INT_ARGB is tinted red<NEW_LINE>window.getHeight(), BufferedImag... | new Dimension(width, height)); |
623,514 | void validateSelf(final boolean shouldIdCheck, final boolean descriptionOptional) throws InvalidToolException {<NEW_LINE>super.validateSelf();<NEW_LINE>// Not the expected type, the wrong Object is in use.<NEW_LINE>if (!objectType.equals(type)) {<NEW_LINE>throw new InvalidToolException(RequestNLS.formatMessage(tc, "TYP... | , "DESCRIPTION_NOT_VALID", description, INVALID_CHARACTERS)); |
257,031 | public void logon(String username, String password, String hostname) throws SHTechnicalException, LoginFailedException {<NEW_LINE>this.hostname = hostname;<NEW_LINE>clientId = UUID.randomUUID().toString();<NEW_LINE>requestId = generateRequestId();<NEW_LINE>passwordEncrypted = generateHashFromPassword(password);<NEW_LIN... | XMLUtil.XPathValueFromString(sResponse, "/BaseResponse/@CurrentConfigurationVersion"); |
1,318,604 | public static ListFileTypeResponse unmarshall(ListFileTypeResponse listFileTypeResponse, UnmarshallerContext _ctx) {<NEW_LINE>listFileTypeResponse.setRequestId(_ctx.stringValue("ListFileTypeResponse.RequestId"));<NEW_LINE>NodeTypeInfoList nodeTypeInfoList = new NodeTypeInfoList();<NEW_LINE>nodeTypeInfoList.setPageNumbe... | ("ListFileTypeResponse.NodeTypeInfoList.NodeTypeInfo[" + i + "].NodeType")); |
1,771,346 | public Request<ReleaseIpamPoolAllocationRequest> marshall(ReleaseIpamPoolAllocationRequest releaseIpamPoolAllocationRequest) {<NEW_LINE>if (releaseIpamPoolAllocationRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<ReleaseIpamPoolAllocation... | (releaseIpamPoolAllocationRequest.getIpamPoolAllocationId())); |
511,168 | private void addStatsRecursive(List<ColumnStatistics> allStats, int index, Map<Integer, List<ColumnStatistics>> nodeAndSubNodeStats, List<ColumnStatistics> unencryptedStats, Map<Integer, Map<Integer, Slice>> encryptedStats) throws IOException {<NEW_LINE>if (allStats.isEmpty()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Col... | getNodes().contains(index); |
1,355,381 | public static void updateProgress(List<FileMeta> list1, boolean updateTime, int limit) {<NEW_LINE>List<FileMeta> list;<NEW_LINE>if (limit != -1 && list1.size() > limit) {<NEW_LINE>list = new ArrayList<>(list1.subList(0, limit));<NEW_LINE>} else {<NEW_LINE>list = list1;<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>for (FileMeta ... | long a = System.currentTimeMillis(); |
1,118,409 | public static UrlParts parseUrl(String theUrl) {<NEW_LINE>String url = theUrl;<NEW_LINE>UrlParts retVal = new UrlParts();<NEW_LINE>if (url.startsWith("http")) {<NEW_LINE>int qmIdx = url.indexOf('?');<NEW_LINE>if (qmIdx != -1) {<NEW_LINE>retVal.setParams(defaultIfBlank(url.substring(qmIdx + 1), null));<NEW_LINE>url = ur... | setVersionId(id.getVersionIdPart()); |
678,681 | public void marshall(FsxConfiguration fsxConfiguration, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (fsxConfiguration == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(fsxConfiguration.getFileSystemId(), ... | fsxConfiguration.getVpcConfiguration(), VPCCONFIGURATION_BINDING); |
1,200,399 | protected ProfileStructure saveToData() throws InvalidDataInputException {<NEW_LINE>ProfileStructure.Builder builder = new <MASK><NEW_LINE>builder.setName(editText_profile_name.getText().toString());<NEW_LINE>for (OperationSkillViewContainerFragment<?> fragment : operationViewList) {<NEW_LINE>if (!fragment.isEnabled())... | ProfileStructure.Builder(C.VERSION_CREATED_IN_RUNTIME); |
827,575 | public void testAnnotations() throws Exception {<NEW_LINE>zp.emptyPod();<NEW_LINE>zp.addOrReplaceZombie(1, "Alex");<NEW_LINE>assertEquals("Andy", zp.getZombie(2, "Andy"));<NEW_LINE>// TODO assertEquals("Andy", zp.getZombie(2, "should-ignore-this-value"));<NEW_LINE>// TODO assertEquals("Alex", zp.getZombie(1, "should-ig... | .getZombie(2, "Nathan")); |
595,121 | public static void main(String[] args) {<NEW_LINE>SingularBuilderExampleBuilder builder = SingularBuilderExample.builder().age(34);<NEW_LINE>System.out.println(builder.occupations(Arrays.asList("1234", "2345")).build());<NEW_LINE>System.out.println(builder.occupation<MASK><NEW_LINE>System.out.println(builder.occupation... | ("aaa").build()); |
1,668,356 | public HierarchicalPrincipal unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>HierarchicalPrincipal hierarchicalPrincipal = new HierarchicalPrincipal();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE... | int originalDepth = context.getCurrentDepth(); |
512,214 | public GetTemplateResult unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>GetTemplateResult getTemplateResult = new GetTemplateResult();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (context.isStartOfDocument())<NEW_LINE>targetDepth += 2;<NEW_LINE>while (true) {<NEW_L... | int originalDepth = context.getCurrentDepth(); |
1,571,123 | public XContentBuilder toXContent(XContentBuilder builder, Params params) throws IOException {<NEW_LINE>builder.field(Fields.AVAILABLE_PROCESSORS, availableProcessors);<NEW_LINE>builder.field(Fields.ALLOCATED_PROCESSORS, allocatedProcessors);<NEW_LINE>builder.startArray(Fields.NAMES);<NEW_LINE>{<NEW_LINE>for (ObjectInt... | mem.toXContent(builder, params); |
1,216,643 | public void realInverseFull(final double[] a, final int offa, boolean scale) {<NEW_LINE>final int twon = 2 * n;<NEW_LINE>switch(plan) {<NEW_LINE>case SPLIT_RADIX:<NEW_LINE>{<NEW_LINE>realInverse2(a, offa, scale);<NEW_LINE>int idx1, idx2;<NEW_LINE>for (int k = 0; k < n / 2; k++) {<NEW_LINE>idx1 = 2 * k;<NEW_LINE>idx2 = ... | + 1] = a[idx]; |
1,094,668 | public java.lang.String[] process(java.lang.String[] args) {<NEW_LINE>@Var<NEW_LINE>int index = 0;<NEW_LINE>while (index < args.length) {<NEW_LINE>@Var<NEW_LINE>int newIndex = index;<NEW_LINE>for (int i = 0; i < options.size(); i++) {<NEW_LINE>CommandOption o = (CommandOption) options.get(i);<NEW_LINE>newIndex = o.proc... | + ": " + args[index]); |
867,099 | public static ClientMessage encodeRequest(java.lang.String name, boolean globalOrderingEnabled, boolean statisticsEnabled, boolean multiThreadingEnabled, @Nullable java.util.Collection<com.hazelcast.client.impl.protocol.task.dynamicconfig.ListenerConfigHolder> listenerConfigs) {<NEW_LINE>ClientMessage clientMessage = C... | initialFrame.content, REQUEST_GLOBAL_ORDERING_ENABLED_FIELD_OFFSET, globalOrderingEnabled); |
1,101,592 | public String format(LabelFormatter formatter, int featureIndex) {<NEW_LINE>final char[][] wordsImage = allWords.image;<NEW_LINE>if (featureIndex < wordsImage.length) {<NEW_LINE>return formatter.format(new char[][] { wordsImage[featureIndex] }, new boolean[] { false });<NEW_LINE>} else {<NEW_LINE>final int[] wordIndice... | formatter.format(wordImages, stopwordFlags); |
1,289,036 | final UntagResourceResult executeUntagResource(UntagResourceRequest untagResourceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(untagResourceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE><MASK><NEW_LINE>Request<UntagResourceReq... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
527,292 | public static String replaceSystemProperties(String s) {<NEW_LINE>int i = s.indexOf("${");<NEW_LINE>if (i == -1)<NEW_LINE>return s;<NEW_LINE>StringBuilder sb = new StringBuilder(s.length());<NEW_LINE>int j = -1;<NEW_LINE>do {<NEW_LINE>sb.append(s.substring(j + 1, i));<NEW_LINE>if ((j = s.indexOf('}', i + 2)) == -1) {<N... | (k + 1, j)); |
753,338 | public static List<Member> partiallySortMembers(Evaluator evaluator, List<Member> list, Calc exp, int limit, boolean desc) {<NEW_LINE>assert !list.isEmpty();<NEW_LINE>assert limit <= list.size();<NEW_LINE>evaluator.getTiming().markStart(SORT_EVAL_TIMING_NAME);<NEW_LINE>boolean timingEval = true;<NEW_LINE>boolean timing... | getTiming().markEnd(SORT_EVAL_TIMING_NAME); |
134,614 | public PaymentsView createView(@NonNull final CreateViewRequest request) {<NEW_LINE>final <MASK><NEW_LINE>viewId.assertWindowId(WINDOW_ID);<NEW_LINE>final BPartnerId bPartnerId = request.getParameterAs(PARAMETER_TYPE_BPARTNER_ID, BPartnerId.class);<NEW_LINE>final Set<PaymentId> paymentIds = request.getParameterAsSet(PA... | ViewId viewId = request.getViewId(); |
177,241 | static Object doGeneric(HPyArrayWrapper receiver, long index, @Shared("lib") @CachedLibrary(limit = "1") InteropLibrary lib, @Shared("ensureHandleNode") @Cached HPyEnsureHandleNode ensureHandleNode, @Exclusive @Cached GilNode gil) throws UnsupportedMessageException, InvalidArrayIndexException {<NEW_LINE>boolean mustRel... | receiver.getNativePointer(), index); |
1,088,995 | void apply(XTextCursor cursor) {<NEW_LINE>XMultiPropertySet mps = UnoCast.cast(XMultiPropertySet.class, cursor).get();<NEW_LINE>XMultiPropertyStates mpss = UnoCast.cast(XMultiPropertyStates.class, cursor).get();<NEW_LINE>ArrayList<Optional<Object>> topLayer = layers.peek();<NEW_LINE>try {<NEW_LINE>// select values to b... | = new ArrayList<>(goodSize); |
1,540,316 | // //////////////////////////////////////////////////////////////////<NEW_LINE>private void processRefs(Address addr, Address[] refs, Address[] offcuts) {<NEW_LINE>if (width < 1) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (refs.length == 0 && offcuts.length == 0) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>StringBuffer buf =... | [i].toString()); |
988,219 | /*<NEW_LINE>* Set the slider's listeners<NEW_LINE>*/<NEW_LINE>public void linkTo(final ParametersInfo parametersInfo, final ConfigWindow parametersWindow) {<NEW_LINE>localVerticalGroup.setOnLongClickListener(new OnLongClickListener() {<NEW_LINE><NEW_LINE>public boolean onLongClick(View v) {<NEW_LINE>if (!parametersInfo... | numValue = Float.parseFloat(value); |
607,774 | protected SdkHttpFullRequest.Builder doPresign(SdkHttpFullRequest request, Aws4SignerRequestParams requestParams, U signingParams) {<NEW_LINE>SdkHttpFullRequest.Builder mutableRequest = request.toBuilder();<NEW_LINE>long expirationInSeconds = getSignatureDurationInSeconds(requestParams, signingParams);<NEW_LINE>addHost... | contentSha256, signingParams.doubleUrlEncode()); |
1,567,290 | public void start() throws Exception {<NEW_LINE>logger.info("Starting FS crawler");<NEW_LINE>if (loop < 0) {<NEW_LINE>logger.info("FS crawler started in watch mode. It will run unless you stop it with CTRL+C.");<NEW_LINE>}<NEW_LINE>if (loop == 0 && !rest) {<NEW_LINE>logger.warn("Number of runs is set to 0 and rest laye... | config, managementService, documentService, loop); |
1,259,975 | public static void vertical11(Kernel1D_S32 kernel, GrayS32 src, GrayS32 dst, int divisor, @Nullable GrowArray<DogArray_I32> workspaces) {<NEW_LINE>final int[] dataSrc = src.data;<NEW_LINE>final int[] dataDst = dst.data;<NEW_LINE>final int k1 = kernel.data[0];<NEW_LINE>final int k2 = kernel.data[1];<NEW_LINE>final int k... | (dataSrc[indexSrc]) * k11; |
1,354,157 | public double[] multipleLinearRegression(Vector<Double> data, int rows, int cols, boolean interceptTerm) {<NEW_LINE>if (data == null)<NEW_LINE>throw new NullPointerException("Null data");<NEW_LINE>if (rows < 0 || cols < 0)<NEW_LINE>throw new IllegalArgumentException("Number of rows and cols must be greater than 0");<NE... | = new double[cols - 1]; |
7,099 | private void createProduction() {<NEW_LINE>int noProds = 0;<NEW_LINE>String info = "";<NEW_LINE>//<NEW_LINE>MProduction production = null;<NEW_LINE>MWarehouse wh = null;<NEW_LINE>X_T_Replenish[] replenishs = getReplenish("M_WarehouseSource_ID IS NULL " + "AND EXISTS (SELECT * FROM M_Product p WHERE p.M_Product_ID=T_Rep... | ), replenish.getM_Warehouse_ID()); |
1,734,344 | private void processNode(final HdKeyNode hdKeyNode) {<NEW_LINE>int depth = hdKeyNode.getDepth();<NEW_LINE>switch(depth) {<NEW_LINE>case 3:<NEW_LINE>if (_mbwManager.getWalletManager(false).hasAccount(hdKeyNode.getUuid())) {<NEW_LINE>final WalletAccount existingAccount = _mbwManager.getWalletManager(false).getAccount(hdK... | .string.import_xpub_should_xpriv), false); |
827,341 | // update an existing photo with given entity<NEW_LINE>@Override<NEW_LINE>public UpdateResponse update(Long key, Photo entity) {<NEW_LINE>final Photo currPhoto = _db.getData().get(key);<NEW_LINE>if (currPhoto == null) {<NEW_LINE><MASK><NEW_LINE>}<NEW_LINE>// Disallow changing entity ID and URN<NEW_LINE>// ID and URN ar... | return new UpdateResponse(HttpStatus.S_404_NOT_FOUND); |
1,674,680 | static DTLSRequest readClientRequest(byte[] data, int dataOff, int dataLen, OutputStream dtlsOutput) throws IOException {<NEW_LINE>// TODO Support the possibility of a fragmented ClientHello datagram<NEW_LINE>byte[] message = DTLSRecordLayer.receiveClientHelloRecord(data, dataOff, dataLen);<NEW_LINE>if (null == message... | TlsUtils.readUint24(message, 1); |
1,319,181 | public static void deleteKeystoreAlias(String certId, String keystorePath, String keystoreName, String keystorePassword) {<NEW_LINE>try {<NEW_LINE>KeyStore keystore = KeyStore.getInstance(KeyStore.getDefaultType());<NEW_LINE>FileInputStream fis = new FileInputStream(keystorePath + "/" + keystoreName);<NEW_LINE>keystore... | throw new AWSIotCertificateException("Error retrieving certificate and key.", e); |
1,413,354 | public void resumePlay(Game game, boolean wasPaused) {<NEW_LINE>activePlayerId = game.getActivePlayerId();<NEW_LINE>UUID priorityPlayerId = game.getPriorityPlayerId();<NEW_LINE>TurnPhase phaseType = game.getPhase().getType();<NEW_LINE>PhaseStep stepType = game.getStep().getType();<NEW_LINE>Iterator<Phase> it = phases.i... | game, phase.getType()); |
70,562 | public final PermissionsBuilder<PermissionType, PermissionsType> addPermission(@NonNull final PermissionType permission, @NonNull final CollisionPolicy collisionPolicy) {<NEW_LINE>assertValidPermissionToAdd(permission);<NEW_LINE>final Map<Resource<MASK><NEW_LINE>final Resource resource = permission.getResource();<NEW_L... | , PermissionType> permissions = getPermissionsInternalMap(); |
117,449 | private IStatus download(ConnectionData data, IProgressMonitor monitor) {<NEW_LINE>// perform the download<NEW_LINE>try {<NEW_LINE>// Use ECF FileTransferJob implementation to get the remote file.<NEW_LINE>FileReader reader = createReader(data);<NEW_LINE>OutputStream <MASK><NEW_LINE>reader.readInto(this.uri, anOutputSt... | anOutputStream = createOutputStream(this.saveTo); |
1,011,357 | private SelectOrSinkPlan toPlan(RelNode rel, List<String> fieldNames, OptimizerContext context, boolean isInfiniteRows) {<NEW_LINE>logger.fine("Before logical opt:\n" + RelOptUtil.toString(rel));<NEW_LINE>LogicalRel logicalRel = optimizeLogical(context, rel);<NEW_LINE>logger.fine("After logical opt:\n" + RelOptUtil.toS... | false, rowMetadata, planExecutor, permissions); |
328,383 | private Container or(CharIterator it, final boolean exclusive) {<NEW_LINE>ArrayContainer ac = new ArrayContainer();<NEW_LINE>int myItPos = 0;<NEW_LINE>ac.cardinality = 0;<NEW_LINE>// do a merge. int -1 denotes end of input.<NEW_LINE>int myHead = (myItPos == cardinality) ? -1 : (content[myItPos++]);<NEW_LINE>int hisHead... | .emit((char) hisHead); |
1,438,733 | private void loadImages() {<NEW_LINE>// try to load icon images<NEW_LINE>iconMap = new HashMap<>();<NEW_LINE>String[] filenames = { // descendants in view<NEW_LINE>DOCS, // descendants in view<NEW_LINE>FRAGMENT, // descendants in view<NEW_LINE>EMPTY_FRAGMENT, // descendants in view<NEW_LINE>VIEWED_FRAGMENT, // descenda... | (disabledFilenames[i], disabledIcon); |
1,720,626 | final DeleteAttachmentResult executeDeleteAttachment(DeleteAttachmentRequest deleteAttachmentRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteAttachmentRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | false), new DeleteAttachmentResultJsonUnmarshaller()); |
203,678 | public void executeAction(WorkflowProcessor processor, Map<String, WorkflowActionClassParameter> params) throws WorkflowActionFailureException {<NEW_LINE>if (LicenseUtil.getLevel() < LicenseLevel.STANDARD.level)<NEW_LINE>// the apis will do nothing anyway<NEW_LINE>return;<NEW_LINE>WebContext ctx = WebContextFactory.get... | user = uWebAPI.getLoggedInUser(request); |
1,068,092 | public int enqueueRead(Object reference, long hostOffset, int[] events, boolean useDeps) {<NEW_LINE>final int returnEvent;<NEW_LINE>if (vectorObject) {<NEW_LINE>final FieldBuffer fieldBuffer = wrappedFields[vectorStorageIndex];<NEW_LINE>returnEvent = fieldBuffer.enqueueRead(reference, (useDeps) ? events : null, useDeps... | ) ? events : null, useDeps); |
1,833,203 | protected void handleResourceRequestWithRestLiResponse(RestRequest request, RoutingResult routingResult, Callback<RestLiResponse> callback) {<NEW_LINE>DataMap entityDataMap = null;<NEW_LINE>if (request.getEntity() != null && request.getEntity().length() > 0) {<NEW_LINE>if (UnstructuredDataUtil.isUnstructuredDataRouting... | .getContext().getRawRequestContext(); |
1,115,954 | private void createLockFile() throws IllegalStateException {<NEW_LINE>try {<NEW_LINE>int currentPid = android.os.Process.myPid();<NEW_LINE>if (lockFile.exists()) {<NEW_LINE>int lastPid = -1;<NEW_LINE>// read pid<NEW_LINE>byte[] bytes = new byte[64];<NEW_LINE><MASK><NEW_LINE>int read = fis.read(bytes);<NEW_LINE>fis.clos... | FileInputStream fis = new FileInputStream(lockFile); |
1,605,661 | private static long toLong(Sequence seq, int radix, boolean isBool, boolean bigEnding) {<NEW_LINE>int size = seq.length();<NEW_LINE>long result = 0;<NEW_LINE>if (bigEnding) {<NEW_LINE>for (int i = size; i > 0; --i) {<NEW_LINE>Object obj = seq.getMem(i);<NEW_LINE>if (obj instanceof Number) {<NEW_LINE>int n = ((Number) o... | MessageManager mm = EngineMessage.get(); |
106,540 | protected void generate(StringToStringMap values, ToolHost toolHost, Interface modelItem) throws Exception {<NEW_LINE>String wscompileDir = SoapUI.getSettings().getString(ToolsSettings.JWSDP_WSCOMPILE_LOCATION, null);<NEW_LINE>if (Tools.isEmpty(wscompileDir)) {<NEW_LINE>UISupport.showErrorMessage("wscompile directory m... | UISupport.isWindows(), modelItem); |
1,320,139 | public static ExecutableDdlJob create(DropGlobalIndexPreparedData preparedData, ExecutionContext executionContext, boolean skipSchemaChange, boolean validate) {<NEW_LINE>// TODO(moyi) merge the if-else path<NEW_LINE>DropGsiJobFactory jobFactory;<NEW_LINE>boolean isNewPartDb = DbInfoManager.getInstance().isNewPartitionD... | getIndexTableName(), physicalPlanData, executionContext); |
1,763,737 | protected void init() {<NEW_LINE>myRoot = new Wrapper();<NEW_LINE>OnePixelSplitter splitter = new OnePixelSplitter(false, 0.5f);<NEW_LINE>myRoot.setContent(splitter);<NEW_LINE>myDescriptionPanel = new PluginDescriptionPanel();<NEW_LINE>splitter.setSecondComponent(myDescriptionPanel.getPanel());<NEW_LINE>myTablePanel = ... | add(header, BorderLayout.NORTH); |
1,144,503 | public void validateUpdateDatastreams(List<Datastream> datastreams, List<Datastream> allDatastreams) throws DatastreamValidationException {<NEW_LINE>for (Datastream newDatastream : datastreams) {<NEW_LINE>List<Datastream> existingDatastreams = allDatastreams.stream().filter(ds -> ds.getName().equals(newDatastream.getNa... | + "Old stream: {%s}; New stream: {%s}", existingDatastream, newDatastream)); |
511,023 | public Rng[] computeFragments(Rng jr) {<NEW_LINE>Rng[] parts = getPartRanges();<NEW_LINE>int partIndex = 0;<NEW_LINE>List<Rng> res = new ArrayList<>();<NEW_LINE>Rng pr = parts[partIndex];<NEW_LINE>assert pr.start <= jr.start;<NEW_LINE>OUT: if (jr.end <= pr.end) {<NEW_LINE>res.add(jr);<NEW_LINE>} else {<NEW_LINE>int l =... | .start, jr.end)); |
1,001,474 | public Object remove(Object sessionKey, boolean removeFromStore) {<NEW_LINE>int hashCode = hash(sessionKey);<NEW_LINE>int index = getIndex(hashCode);<NEW_LINE>CacheItem prev = null, item = null;<NEW_LINE>synchronized (bucketLocks[index]) {<NEW_LINE>for (item = buckets[index]; item != null; item = item.getNext()) {<NEW_... | index] = item.getNext(); |
1,552,616 | final DescribeLoggingConfigurationResult executeDescribeLoggingConfiguration(DescribeLoggingConfigurationRequest describeLoggingConfigurationRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeLoggingConfigurationRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContex... | false), new DescribeLoggingConfigurationResultJsonUnmarshaller()); |
1,831,842 | private Mono<Response<Flux<ByteBuffer>>> deleteWithResponseAsync(String resourceGroupName, String privateZoneName, String ifMatch, 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 n... | this.client.mergeContext(context); |
679,481 | protected void delete(Context context, UUID uuid) throws AuthorizeException {<NEW_LINE>Group group = null;<NEW_LINE>try {<NEW_LINE>group = gs.find(context, uuid);<NEW_LINE>if (group == null) {<NEW_LINE>throw new ResourceNotFoundException(GroupRest.CATEGORY + "." + GroupRest.NAME + " with id: " + uuid + " not found");<N... | gs.delete(context, group); |
1,119,230 | protected void superPrePassivate(InvocationContext inv) {<NEW_LINE>try {<NEW_LINE><MASK><NEW_LINE>results.addPrePassivate(CLASS_NAME, "superPrePassivate");<NEW_LINE>// Validate and update context data.<NEW_LINE>Map<String, Object> map = inv.getContextData();<NEW_LINE>String data;<NEW_LINE>if (map.containsKey("PrePassiv... | ResultsLocal results = ResultsLocalBean.getSFBean(); |
970,828 | public void mouseDown(MouseEvent e) {<NEW_LINE>double xValue = xyGraph.primaryXAxis.getPositionValue(e.x, false);<NEW_LINE>double yValue = xyGraph.primaryYAxis.getPositionValue(e.y, false);<NEW_LINE>if (xyGraph.primaryXAxis.getRange().getLower() > xValue || xyGraph.primaryXAxis.getRange().getUpper() < xValue)<NEW_LINE>... | sortedTraces.get(i - 1); |
296,912 | static List<PathSegment> parse(String path) {<NEW_LINE>requireNonNull(path, "path");<NEW_LINE>checkArgument(!path.isEmpty(), "path is empty.");<NEW_LINE>final Context context = new Context(path);<NEW_LINE>checkArgument(context.read() == '/', "path: %s (must start with '/')", context.path());<NEW_LINE>final ImmutableLis... | "path: %s (must contain at least one segment)", context.path()); |
1,012,370 | private RexNode convertIdentifier(Blackboard bb, SqlIdentifier identifier) {<NEW_LINE>// first check for reserved identifiers like CURRENT_USER<NEW_LINE>final SqlCall call = bb.getValidator().makeNullaryCall(identifier);<NEW_LINE>if (call != null) {<NEW_LINE>return bb.convertExpression(call);<NEW_LINE>}<NEW_LINE>String... | (bb, (RexInputRef) e); |
235,094 | private boolean requestDecorView(View view, LayoutParams params, int layoutRes) {<NEW_LINE>if (mDecorView != null) {<NEW_LINE>return true;<NEW_LINE>}<NEW_LINE>mDecorView = new ActivityDecorView();<NEW_LINE>mDecorView.setId(android.R.id.content);<NEW_LINE>mDecorView.setProvider(this);<NEW_LINE>if (view != null) {<NEW_LI... | mDecorView.addView(view, params); |
1,493,533 | final GetNetworkInsightsAccessScopeContentResult executeGetNetworkInsightsAccessScopeContent(GetNetworkInsightsAccessScopeContentRequest getNetworkInsightsAccessScopeContentRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getNetworkInsightsAccessScopeContentRequest);<NEW_LINE>AWSRequestMet... | invoke(request, responseHandler, executionContext); |
1,547,508 | private BeanRegistrationWriter createScopedProxyBeanRegistrationWriter(String beanName, BeanDefinition beanDefinition) {<NEW_LINE>Object targetBeanName = beanDefinition.getPropertyValues().get("targetBeanName");<NEW_LINE>BeanDefinition targetBeanDefinition = getTargetBeanDefinition(targetBeanName);<NEW_LINE>if (targetB... | statements.add("factory.setTargetBeanName($S)", targetBeanName); |
102,586 | public ListPiiEntitiesDetectionJobsResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ListPiiEntitiesDetectionJobsResult listPiiEntitiesDetectionJobsResult = new ListPiiEntitiesDetectionJobsResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetD... | String currentParentElement = context.getCurrentParentElement(); |
884,133 | public /*<NEW_LINE>* When enabled writes to the log will throw LogFileFullException.<NEW_LINE>*<NEW_LINE>* @param boolean if true subsequent writes to the log throw LogFileFullException.<NEW_LINE>* if false subsequent writes may succeed.<NEW_LINE>*/<NEW_LINE>void simulateLogOutputFull(boolean isFull) throws ObjectManag... | "simulateLogOutputFull", "isFull=" + isFull + "(boolean)"); |
364,057 | private void writeSingle(final OutputStream out, final String name, final ReadData read) {<NEW_LINE>try {<NEW_LINE>byte[] bases = read.getBases();<NEW_LINE>byte[] quals = read.getQualities();<NEW_LINE>final int len = bases.length;<NEW_LINE>for (int i = 0; i < len; ++i) {<NEW_LINE>quals[i] = (byte) SAMUtils.phredToFastq... | .getBytes(StandardCharsets.UTF_8)); |
127,751 | private HeaderSymlinkTree createExportedModuleSymlinkTreeBuildRule(BuildTarget buildTarget, ProjectFilesystem projectFilesystem, ActionGraphBuilder graphBuilder, CxxPlatform cxxPlatform, AppleNativeTargetDescriptionArg args) {<NEW_LINE>Path headerPathPrefix = <MASK><NEW_LINE>ImmutableSortedMap.Builder<Path, SourcePath>... | AppleDescriptions.getHeaderPathPrefix(args, buildTarget); |
1,385,775 | public static ListQueuesResponse unmarshall(ListQueuesResponse listQueuesResponse, UnmarshallerContext _ctx) {<NEW_LINE>listQueuesResponse.setRequestId(_ctx.stringValue("ListQueuesResponse.RequestId"));<NEW_LINE>List<QueueInfo> queues = new ArrayList<QueueInfo>();<NEW_LINE>for (int i = 0; i < _ctx.lengthValue("ListQueu... | + "].ComputeInstanceType[" + j + "]")); |
1,611,053 | public okhttp3.Call readNamespacedStatefulSetScaleCall(String name, String namespace, String pretty, final ApiCallback _callback) throws ApiException {<NEW_LINE>Object localVarPostBody = null;<NEW_LINE>// create path and map variables<NEW_LINE>String localVarPath = "/apis/apps/v1/namespaces/{namespace}/statefulsets/{na... | final String[] localVarContentTypes = {}; |
278,142 | public InfinispanUserSessionProvider create(KeycloakSession session) {<NEW_LINE>InfinispanConnectionProvider connections = session.getProvider(InfinispanConnectionProvider.class);<NEW_LINE>Cache<String, SessionEntityWrapper<UserSessionEntity>> cache = connections.getCache(InfinispanConnectionProvider.USER_SESSION_CACHE... | connections.getCache(InfinispanConnectionProvider.OFFLINE_CLIENT_SESSION_CACHE_NAME); |
322,938 | public void mousePressed(MouseEvent e, TransferData data) {<NEW_LINE>MageCard cardPanel = data.getComponent().getTopPanelRef();<NEW_LINE>cardPanel.requestFocusInWindow();<NEW_LINE>// for some reason sometime mouseRelease happens before numerous Mouse_Dragged events<NEW_LINE>// that results in not finished dragging<NEW_... | int) mouse.getY()); |
1,736,880 | public void checkConverted() {<NEW_LINE>List<String> keys = null;<NEW_LINE>try {<NEW_LINE>keys = _protoCache.keySet().stream().collect(Collectors.toList());<NEW_LINE>} catch (Exception e) {<NEW_LINE>System.err.println("Unable to read converted sessions, assuming still in legacy format. Run again without 'check' option ... | err.println("Failed: " + s); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.