idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
278,749 | public void actionPerformed(ActionEvent e) {<NEW_LINE>X509Metadata metadata = new X509Metadata("whocares", "whocares");<NEW_LINE>File certificatesConfigFile = new File(folder, X509Utils.CA_CONFIG);<NEW_LINE>FileBasedConfig config = new FileBasedConfig(certificatesConfigFile, FS.detect());<NEW_LINE>NewCertificateConfig ... | certificateConfig.store(config, metadata); |
596,782 | public Void execute(CommandContext commandContext) {<NEW_LINE>if (appDefinitionId == null) {<NEW_LINE>throw new FlowableIllegalArgumentException("appDefinitionId is null");<NEW_LINE>}<NEW_LINE>if (variables == null) {<NEW_LINE>throw new FlowableIllegalArgumentException("variables is null");<NEW_LINE>}<NEW_LINE>if (vari... | variableService.createVariableInstance(variableName, type); |
1,315,763 | public void testMSExcel() throws IOException {<NEW_LINE>File demoDocument = null;<NEW_LINE>MSExcel msExcel = null;<NEW_LINE>try {<NEW_LINE>msExcel = new MSExcel();<NEW_LINE>System.out.println(<MASK><NEW_LINE>msExcel.setVisible(true);<NEW_LINE>Helper.sleep(5);<NEW_LINE>demoDocument = Helper.createNotExistingFile("jnates... | "MSExcel version: " + msExcel.getVersion()); |
109,900 | public void init(Context context) {<NEW_LINE>setOrientation(VERTICAL);<NEW_LINE>setDividerDrawable(context.getResources().getDrawable(R.drawable.spacer_keyline));<NEW_LINE>setShowDividers(SHOW_DIVIDER_MIDDLE);<NEW_LINE>setClipChildren(false);<NEW_LINE>setClipToPadding(false);<NEW_LINE>LayoutInflater.from(context).infla... | this, R.id.search_se); |
1,194,573 | public // d681743<NEW_LINE>// d681743<NEW_LINE>void // d681743<NEW_LINE>mergeSaved(InjectionBinding<EJB> injectionBinding) throws InjectionException {<NEW_LINE>EJBInjectionBinding ejbBinding = (EJBInjectionBinding) injectionBinding;<NEW_LINE>mergeSavedValue(getInjectionClassType(), ejbBinding.getInjectionClassType(), "... | ivBeanName, ejbBinding.ivBeanName, "ejb-link"); |
1,463,265 | protected ImmutableSet<Either<SymbolInformation, DocumentSymbol>> compute() {<NEW_LINE>status.setValue<MASK><NEW_LINE>try {<NEW_LINE>SymbolsProvider sp = currentSymbolsProvider.getValue();<NEW_LINE>if (sp != null) {<NEW_LINE>String currentProviderName = sp.getName();<NEW_LINE>debug("Fetching " + currentProviderName);<N... | (HighlightedText.plain("Fetching symbols...")); |
65,350 | public Set<Template> parse(InputStreamReader reader) throws ParsingException {<NEW_LINE>JsonReader jr = new JsonReader(reader);<NEW_LINE>try {<NEW_LINE>if (jr.hasNext()) {<NEW_LINE>JsonToken token = jr.peek();<NEW_LINE>Set<Template> templates = new HashSet<>();<NEW_LINE>if (JsonToken.BEGIN_ARRAY.equals(token)) {<NEW_LI... | .TEMPLATE, null, e)); |
1,097,476 | final void startReceiver(CoreSubscriber<? super Object> s) {<NEW_LINE>if (once == 0 && ONCE.compareAndSet(this, 0, 1)) {<NEW_LINE>if (log.isDebugEnabled()) {<NEW_LINE>log.debug(format<MASK><NEW_LINE>}<NEW_LINE>if (inboundDone && getPending() == 0) {<NEW_LINE>if (inboundError != null) {<NEW_LINE>Operators.error(s, inbou... | (channel, "{}: subscribing inbound receiver"), this); |
1,559,324 | public static List<Interval> toIntervals(final RangeSet<Long> rangeSet) {<NEW_LINE>final List<Interval> retVal = new ArrayList<>();<NEW_LINE>for (Range<Long> range : rangeSet.asRanges()) {<NEW_LINE>final long start;<NEW_LINE>final long end;<NEW_LINE>if (range.hasLowerBound()) {<NEW_LINE>final long millis = range.lowerE... | .eternity().getStartMillis(); |
559,829 | public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {<NEW_LINE>if (((bitField0_ & 0x00000001) == 0x00000001)) {<NEW_LINE>com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);<NEW_LINE>}<NEW_LINE>if (((bitField0_ & 0x00000002) == 0x00000002)) {<NEW_LINE>output.<MA... | writeMessage(2, getClientConfig()); |
1,670,279 | public okhttp3.Call readNamespacedDeploymentScaleCall(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}/deployments/{name... | = { "application/json", "application/yaml", "application/vnd.kubernetes.protobuf" }; |
1,402,778 | final CacheCluster executeRebootCacheCluster(RebootCacheClusterRequest rebootCacheClusterRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(rebootCacheClusterRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEven... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "RebootCacheCluster"); |
279,011 | private QueryBuilder withinQuery(String fieldName, Object[] valArray) {<NEW_LINE>GeoDistanceQueryBuilder filter = QueryBuilders.geoDistanceQuery(fieldName);<NEW_LINE>Assert.noNullElements(valArray, "Geo distance filter takes 2 not null elements array as parameter.");<NEW_LINE>Assert.isTrue(<MASK><NEW_LINE>Assert.isTrue... | valArray.length == 2, "Geo distance filter takes a 2-elements array as parameter."); |
84,653 | public void receiveTouches(String eventName, WritableArray touches, WritableArray changedIndices) {<NEW_LINE>Assertions.assertCondition(touches.size() > 0);<NEW_LINE>int reactTag = touches.getMap(0).getInt(TARGET_KEY);<NEW_LINE>@UIManagerType<NEW_LINE>int uiManagerType = ViewUtil.getUIManagerType(reactTag);<NEW_LINE>if... | receiveTouches(eventName, touches, changedIndices); |
436,287 | public boolean hashCodesEqual(@Nonnull final ASTNode n1, @Nonnull final LighterASTNode n2) {<NEW_LINE>if (n1 instanceof LeafElement && n2 instanceof Token) {<NEW_LINE>boolean isForeign1 = n1 instanceof ForeignLeafPsiElement;<NEW_LINE>boolean isForeign2 <MASK><NEW_LINE>if (isForeign1 != isForeign2)<NEW_LINE>return false... | = n2.getTokenType() instanceof ForeignLeafType; |
1,236,366 | public static void unzipFile(File zipFile, File targetDirectory) throws IOException {<NEW_LINE>checkNotNull(zipFile);<NEW_LINE>checkNotNull(targetDirectory);<NEW_LINE>checkArgument(targetDirectory.isDirectory(), "%s is not a valid directory", targetDirectory.getAbsolutePath());<NEW_LINE>final ZipFile zipFileObj = new Z... | File parentFile = targetFile.getParentFile(); |
1,011,481 | public static LatLon decodeMapsMeLatLonToInt(String s) {<NEW_LINE>// 44TvlEGXf-<NEW_LINE>int lat = 0, lon = 0;<NEW_LINE>int shift = kMaxCoordBits - 3;<NEW_LINE>for (int i = 0; i < s.length(); ++i, shift -= 3) {<NEW_LINE>int a = net.osmand.osm.io.Base64.indexOf(s.charAt(i));<NEW_LINE>if (a < 0)<NEW_LINE>return null;<NEW... | 1 + 1) * 360.0 - 180; |
1,211,955 | public void draw(final BoundingBox boundingBox, final byte zoomLevel, final Canvas canvas, final Point topLeftPoint) {<NEW_LINE>if (coordinates == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>// prepare accuracy circle<NEW_LINE>final float accuracy = coordinates.getAccuracy();<NEW_LINE>if (accuracyCircle == null) {<NEW... | ), canvas.getHeight()); |
1,184,463 | final GetMemberResult executeGetMember(GetMemberRequest getMemberRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getMemberRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_L... | endClientExecution(awsRequestMetrics, request, response); |
334,570 | public Parameterable createParameterable(String paramString) throws ServletParseException {<NEW_LINE>if (c_logger.isTraceEntryExitEnabled()) {<NEW_LINE>Object[] params = { paramString };<NEW_LINE>c_logger.traceEntry(this, "createParameterable", params);<NEW_LINE>}<NEW_LINE>if (paramString == null) {<NEW_LINE>throw new ... | ServletParseException("bad parameterable syntax [" + paramString + ']'); |
1,829,920 | void handleHandshake(TransportChannel channel, long requestId, StreamInput stream) throws IOException {<NEW_LINE>// Must read the handshake request to exhaust the stream<NEW_LINE>HandshakeRequest handshakeRequest = new HandshakeRequest(stream);<NEW_LINE>final int nextByte = stream.read();<NEW_LINE>if (nextByte != -1) {... | new HandshakeResponse(this.version)); |
1,311,771 | public static void showInputDialog(String initialText, int maxLen) {<NEW_LINE>new Handler(Looper.getMainLooper()).post(() -> {<NEW_LINE>if (inputDialog == null) {<NEW_LINE>EditText editText = new EditText(context);<NEW_LINE>editText.setLines(3);<NEW_LINE>editText.setText(initialText);<NEW_LINE>float density = context.g... | linearLayout.addView(editText, params); |
894,054 | private static RangeHighlighter createOrReuseLineMarker(@Nonnull LineMarkerInfo<?> info, @Nonnull MarkupModelEx markupModel, @Nullable HighlightersRecycler toReuse) {<NEW_LINE>LineMarkerInfo.LineMarkerGutterIconRenderer<?> newRenderer = (LineMarkerInfo.LineMarkerGutterIconRenderer<<MASK><NEW_LINE>RangeHighlighter highl... | ?>) info.createGutterRenderer(); |
675,276 | public IInvoiceGenerateResult generateInvoicesFromQueue(final Properties ctx) {<NEW_LINE>// note that we don't want to store the actual invoices in the result to omit memory-problems<NEW_LINE>final InvoiceGenerateResult result = new InvoiceGenerateResult(false);<NEW_LINE>final IWorkpackageProcessor packageProcessor = n... | ctx, packageProcessor.getClass()); |
1,285,534 | protected void prepareBuffer() {<NEW_LINE>// bufferToSend now is the header ByteBuf, it will store serialized header, without blob content and crc<NEW_LINE>bufferToSend = PooledByteBufAllocator.DEFAULT.ioBuffer(sizeExcludingBlobAndCrcSize());<NEW_LINE>writeHeader();<NEW_LINE>int crcStart = bufferToSend.writerIndex();<N... | CompositeByteBuf) blob).iterator(); |
804,919 | public byte readBufferByte(long index, @Shared("isBuffer") @Cached IsBufferNode isBuffer, @Shared("error") @Cached BranchProfile error, @Shared("classProfile") @Cached("createClassProfile()") ValueProfile classProfile) throws UnsupportedMessageException, InvalidBufferOffsetException {<NEW_LINE>if (!isBuffer.execute(thi... | ByteBuffer) classProfile.profile(obj); |
129,238 | public void updateViews(AlLinkPreviewModel linkPreviewModel) {<NEW_LINE>if (linkPreviewModel != null && linkPreviewModel.hasLinkData()) {<NEW_LINE>urlLoadLayout.setVisibility(View.VISIBLE);<NEW_LINE>if (linkPreviewModel.hasImageOnly()) {<NEW_LINE>toggleImageOnlyVisibility(true);<NEW_LINE>Glide.with(context).load(linkPr... | new OpenLinkTask(context, message)); |
832,937 | public Float validateAndGetRate(int dayCount, Currency currencyFrom, Currency currencyTo, LocalDate date) throws AxelorException {<NEW_LINE>try {<NEW_LINE>HTTPResponse response = null;<NEW_LINE>if (dayCount < 8) {<NEW_LINE>HTTPClient httpclient = new HTTPClient();<NEW_LINE>HTTPRequest request = new HTTPRequest();<NEW_L... | getRateFromJson(currencyFrom, currencyTo, response); |
699,109 | // end static class ExactBlock<NEW_LINE>public static void main(String[] args) {<NEW_LINE>TransducerGraph fa = new TransducerGraph();<NEW_LINE>fa.addArc(fa.getStartNode(), "1", "a", "");<NEW_LINE>fa.addArc(fa.getStartNode(), "2", "b", "");<NEW_LINE>fa.addArc(fa.getStartNode(), "3", "c", "");<NEW_LINE>fa.addArc("1", "4"... | System.out.println(randomFA); |
1,774,780 | public SingularGuavaTable2<A, B, C> build() {<NEW_LINE>com.google.common.collect.ImmutableTable<java.lang.Object, java.lang.Object, java.lang.Object> rawTypes = this.rawTypes == null ? com.google.common.collect.ImmutableTable.<java.lang.Object, java.lang.Object, java.lang.Object>of() : this.rawTypes.build();<NEW_LINE>c... | rawTypes, integers, generics, extendsGenerics); |
1,779,042 | private void onMenuItemClicked(NavMenu.Item item) {<NEW_LINE>final MwmActivity parent = ((MwmActivity) mFrame.getContext());<NEW_LINE>switch(item) {<NEW_LINE>case STOP:<NEW_LINE>mNavMenu.close(false);<NEW_LINE>Statistics.INSTANCE.trackRoutingFinish(true, RoutingController.get().getLastRouterType(), TrafficManager.INSTA... | parent, SettingsActivity.class))); |
1,384,701 | public GuestbookResponse initGuestbookResponseForFragment(DatasetVersion workingVersion, FileMetadata fileMetadata, DataverseSession session) {<NEW_LINE>Dataset dataset = workingVersion.getDataset();<NEW_LINE>GuestbookResponse guestbookResponse = new GuestbookResponse();<NEW_LINE>if (workingVersion.isDraft()) {<NEW_LIN... | setDataFile(fileMetadata.getDataFile()); |
1,795,761 | private AlertDialog createResetCacheCoordinatesDialog(final Waypoint wpt) {<NEW_LINE>final AlertDialog.Builder builder = Dialogs.newBuilder(this);<NEW_LINE>builder.<MASK><NEW_LINE>final String[] items = { res.getString(R.string.waypoint_localy_reset_cache_coords), res.getString(R.string.waypoint_reset_local_and_remote_... | setTitle(R.string.waypoint_reset_cache_coords); |
1,297,949 | protected void applyEnterFiltered(CodegenMethod method, ExprForgeCodegenSymbol symbols, CodegenClassScope classScope, CodegenNamedMethods namedMethods) {<NEW_LINE>CodegenExpressionRef eps = symbols.getAddEPS(method);<NEW_LINE>CodegenExpressionRef <MASK><NEW_LINE>CodegenMethod referenceAddToColl = referenceAddToCollCode... | ctx = symbols.getAddExprEvalCtx(method); |
1,823,479 | /*<NEW_LINE>static Map<String, ReplicationStatus> checkIfPasswordIsReplicated(final ChaiUser user, final PwmSession pwmSession)<NEW_LINE>throws ChaiUnavailableException<NEW_LINE>{<NEW_LINE>final Map<String, ReplicationStatus> repStatusMap = new HashMap<String, ReplicationStatus>();<NEW_LINE><NEW_LINE>{<NEW_LINE>final R... | PwmSetting.PASSWORD_STRENGTH_METER_TYPE, StrengthMeterType.class); |
458,570 | protected static boolean nGetFullPathProperties(long pathPtr, byte[] properties, int length) {<NEW_LINE>if (length != TOTAL_PROPERTY_COUNT * 4)<NEW_LINE>return false;<NEW_LINE>Path path = getPath(pathPtr);<NEW_LINE>ByteBuffer propertiesBB = ByteBuffer.wrap(properties);<NEW_LINE>propertiesBB.order(ByteOrder.nativeOrder(... | STROKE_LINE_CAP_INDEX * 4, path.strokeLineCap); |
1,138,061 | public Object calculate(Context ctx) {<NEW_LINE>if (param == null || param.isLeaf() || param.getSubSize() < 5) {<NEW_LINE>MessageManager mm = EngineMessage.get();<NEW_LINE>throw new RQException("Fyield:" + mm.getMessage("function.missingParam"));<NEW_LINE>}<NEW_LINE>int size = param.getSubSize();<NEW_LINE>Object[<MASK>... | ] result = new Object[size]; |
693,969 | public void bindViewHolder(FlexibleAdapter adapter, ViewHolder holder, int position, List<Object> payloads) {<NEW_LINE>Context context = holder.itemView.getContext();<NEW_LINE>holder.accountColorIndicator.setBackgroundColor(ColorManager.getInstance().getAccountPainter().getDefaultMainColor());<NEW_LINE>holder.accountCo... | setText(R.string.archived_chats); |
49,544 | public static byte[] serialize(ConstraintDescriptor constraint, MemoryTracker memoryTracker) {<NEW_LINE>try (var scopedBuffer = new HeapScopedBuffer(lengthOf(constraint), memoryTracker)) {<NEW_LINE>ByteBuffer target = scopedBuffer.getBuffer();<NEW_LINE>target.putInt(LEGACY_LABEL_OR_REL_TYPE_ID);<NEW_LINE>target.put(CON... | asIndexBackedConstraint().ownedIndexId()); |
1,572,991 | private void fixSpinner(Context context, int hourOfDay, int minute, boolean is24HourView, RNTimePickerDisplay display) {<NEW_LINE>if (Build.VERSION.SDK_INT == Build.VERSION_CODES.N && display == RNTimePickerDisplay.SPINNER) {<NEW_LINE>try {<NEW_LINE>Class<?> styleableClass = Class.forName("com.android.internal.R$stylea... | int.class, int.class); |
961,607 | protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException {<NEW_LINE>config.put("noCode", "true");<NEW_LINE>WebApplicationContext ctx = WebApplicationContextUtils.getRequiredWebApplicationContext(req.getServletContext());<NEW_LINE>config.put("supportsImpactAnalysis", checkImpactAnalysisS... | config.put("models", pluginTree); |
629,326 | public StopRelationalDatabaseResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>StopRelationalDatabaseResult stopRelationalDatabaseResult = new StopRelationalDatabaseResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentPar... | )).unmarshall(context)); |
1,567,852 | boolean tryUploadHeapDumpIfItExists() {<NEW_LINE>if (uploadFilePath == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>boolean uploadedHeapDump = false;<NEW_LINE>File localSource = getDefaultHeapDumpPath();<NEW_LINE>LOG.info("Looking for heap dump at {}", localSource);<NEW_LINE>if (localSource.exists()) {<NEW_LINE><... | LOG.warn("Heap dump {} detected, attempting to upload file to ", localSource); |
914,346 | private void doExperiment() {<NEW_LINE>LookupCSV lookupCSV = new LookupCSV();<NEW_LINE>int[] numberOfQueries = { 100000, 1000000, 10000000, 100000000, 1000000000 };<NEW_LINE>String[] filePaths = { LARGE_INPUT_FILE_PATH1, LARGE_INPUT_FILE_PATH2 };<NEW_LINE>String[] fileNames = { Constants.SURNAMES_CSV_FILE, Constants.SD... | , numberOfQueries[q], timeSpent); |
1,788,172 | private void handleClientCoreMessage_TemplateChange(Message msg) {<NEW_LINE>SonicUtils.log(TAG, Log.INFO, "handleClientCoreMessage_TemplateChange wasLoadDataInvoked = " + wasLoadDataInvoked.get() + ",msg arg1 = " + msg.arg1);<NEW_LINE>if (wasLoadDataInvoked.get()) {<NEW_LINE>if (TEMPLATE_CHANGE_REFRESH == msg.arg1) {<N... | sessionClient.loadUrl(srcUrl, null); |
1,276,877 | public void run(RegressionEnvironment env) {<NEW_LINE>sendTimer(env, 0);<NEW_LINE>String epl = "@name('s0') select irstream max(price) as maxVol" + " from SupportMarketDataBean#time(1.1 sec) " + "output every 1 seconds";<NEW_LINE>env.compileDeploy(epl).addListener("s0");<NEW_LINE>sendEvent(env, "SYM1", 1d);<NEW_LINE>se... | 0].get("maxVol")); |
323,952 | final DisassociateNodeResult executeDisassociateNode(DisassociateNodeRequest disassociateNodeRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(disassociateNodeRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
1,493,480 | private void populateExtensions() {<NEW_LINE>for (HypervisorFactory f : pluginRgty.getExtensionList(HypervisorFactory.class)) {<NEW_LINE>HypervisorFactory old = hypervisorFactories.get(f.getHypervisorType().toString());<NEW_LINE>if (old != null) {<NEW_LINE>throw new CloudRuntimeException(String.format("duplicate Hyperv... | ).toString(), f); |
230,795 | public NumericDoubleValues select(final SortedNumericDoubleValues values, final double missingValue, final BitSet parentDocs, final DocIdSetIterator childDocs, int maxDoc, int maxChildren) throws IOException {<NEW_LINE>if (parentDocs == null || childDocs == null) {<NEW_LINE>return FieldData.replaceMissing(FieldData.emp... | childDocs, firstChildDoc, parentDoc, maxChildren); |
1,848,848 | public static void main(String[] args) throws IOException {<NEW_LINE>DataplexJdbcIngestionOptions options = PipelineOptionsFactory.fromArgs(args).withValidation().as(DataplexJdbcIngestionOptions.class);<NEW_LINE>Pipeline pipeline = Pipeline.create(options);<NEW_LINE>DataplexClient dataplexClient = DefaultDataplexClient... | .name() + " supported.")); |
594,502 | private void login() {<NEW_LINE>InputUtils.hideKeyboard(mEtLogin);<NEW_LINE>final String username = mEtLogin.getText().toString();<NEW_LINE>final String password = mEtPassword.getText().toString();<NEW_LINE>enableInput(false);<NEW_LINE>UiUtils.show(mProgress);<NEW_LINE>mTvLogin.setText("");<NEW_LINE>ThreadPool.getWorke... | 0], auth[1]); |
1,025,793 | public com.amazonaws.services.appregistry.model.ServiceQuotaExceededException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.appregistry.model.ServiceQuotaExceededException serviceQuotaExceededException = new com.amazonaws.services.appregistry.model.ServiceQuot... | JsonToken token = context.getCurrentToken(); |
642,951 | public void open(ClosedListener l) {<NEW_LINE>this.listener = l;<NEW_LINE>skinnedDialog = new SkinnedDialog("skin3_dlg_deviceadd_mfchooser", "shell", SWT.TITLE | SWT.BORDER);<NEW_LINE>skinnedDialog.addCloseListener(new SkinnedDialogClosedListener() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void skinDialogClosed(Sk... | addListener(SWT.MouseUp, btnListener); |
667,727 | protected void recalculateBoundingBox() {<NEW_LINE>if (this.direction == null)<NEW_LINE>return;<NEW_LINE>if (this.verticalOrientation == null)<NEW_LINE>return;<NEW_LINE>Vec3 pos = Vec3.atLowerCornerOf(getPos()).add(.5, .5, .5).subtract(Vec3.atLowerCornerOf(direction.getNormal()).scale(0.46875));<NEW_LINE>double d1 = po... | (double) this.getHeight(); |
1,149,293 | public void configure(ConfigurableProvider provider) {<NEW_LINE>provider.<MASK><NEW_LINE>provider.addAlgorithm("KeyPairGenerator.McEliecePointcheval", PREFIX + "McElieceCCA2KeyPairGeneratorSpi");<NEW_LINE>provider.addAlgorithm("KeyPairGenerator.McElieceFujisaki", PREFIX + "McElieceCCA2KeyPairGeneratorSpi");<NEW_LINE>pr... | addAlgorithm("KeyPairGenerator.McElieceKobaraImai", PREFIX + "McElieceCCA2KeyPairGeneratorSpi"); |
1,271,927 | private void step3aBoundsUpdate(List<Vec> X, boolean[] r, int q, Vec v, final List<Vec> means, final int[] assignment, double[] upperBound, double[][] lowerBound, double[] meanSummaryConsts, List<Double> distAccelCache, List<List<Double>> meanQIs) {<NEW_LINE>// 3(a)<NEW_LINE>if (r[q]) {<NEW_LINE>r[q] = false;<NEW_LINE>... | [q][meanIndx] = d; |
388,584 | final ListTestGridSessionsResult executeListTestGridSessions(ListTestGridSessionsRequest listTestGridSessionsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listTestGridSessionsRequest);<NEW_LINE><MASK><NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_LINE>Request<ListT... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
98,169 | final DescribeExportTasksResult executeDescribeExportTasks(DescribeExportTasksRequest describeExportTasksRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeExportTasksRequest);<NEW_LINE><MASK><NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_LINE>Request<DescribeEx... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
1,348,419 | protected HttpProcessor createHttpProcessor(Settings settings) {<NEW_LINE>// request interceptors<NEW_LINE>List<HttpRequestInterceptor> requestInterceptors = new ArrayList<>();<NEW_LINE>requestInterceptors.add(new RequestDefaultHeaders());<NEW_LINE>requestInterceptors.add(new HeaderChecker());<NEW_LINE>requestIntercept... | responseInterceptors = new ArrayList<>(); |
1,279,378 | public void whenUpdateRetentionTimeThenUpdateInKafkaAndDB() throws Exception {<NEW_LINE>final EventType eventType = NakadiTestUtils.createEventType();<NEW_LINE>IntStream.range(0, 15).forEach(x -> publishEvent(eventType.getName(), "{\"foo\":\"bar\"}"));<NEW_LINE>NakadiTestUtils.switchTimelineDefaultStorage(eventType);<N... | getOptions().setRetentionTime(newRetentionTime); |
252,241 | public Mono<Void> filter(ServerWebExchange exchange, GatewayFilterChain chain) {<NEW_LINE>Route route = <MASK><NEW_LINE>Mono<Void> asyncResult = chain.filter(exchange);<NEW_LINE>if (route != null) {<NEW_LINE>String routeId = route.getId();<NEW_LINE>Object[] params = paramParser.parseParameterFor(routeId, exchange, r ->... | exchange.getAttribute(ServerWebExchangeUtils.GATEWAY_ROUTE_ATTR); |
1,566,588 | private HandlerInfo adaptToHandlerInfo(org.apache.cxf.jaxws30.handler.types.PortComponentHandlerType pt) {<NEW_LINE>HandlerInfo handler = new HandlerInfo();<NEW_LINE>handler.setId(pt.getId());<NEW_LINE>handler.setHandlerClass(pt.getHandlerClass().getValue());<NEW_LINE>handler.setHandlerName(pt.getHandlerName().getValue... | addSoapRole(sRole.getValue()); |
863,431 | public void init(Properties props) {<NEW_LINE>_port = (int) props.get(PORT);<NEW_LINE>_zkStr = props.getProperty(ZOOKEEPER_CONNECT);<NEW_LINE>_logDirPath = props.getProperty(LOG_DIRS);<NEW_LINE>// Create the ZK nodes for Kafka, if needed<NEW_LINE>int indexOfFirstSlash = _zkStr.indexOf('/');<NEW_LINE>if (indexOfFirstSla... | AdminClientConfig.BOOTSTRAP_SERVERS_CONFIG, "localhost:" + _port); |
527,474 | private byte[] renderFunction(WasmFunction function) {<NEW_LINE>WasmBinaryWriter code = new WasmBinaryWriter();<NEW_LINE>List<WasmLocal> localVariables = function.getLocalVariables();<NEW_LINE>int parameterCount = Math.min(function.getParameters().size(), localVariables.size());<NEW_LINE>localVariables = localVariables... | code.writeLEB(entry.count); |
1,740,092 | /*<NEW_LINE>*<NEW_LINE>*/<NEW_LINE>private void onTweetFeedItemSingleTap(View view, int position) {<NEW_LINE>if (mSelectedItems.size() == 0) {<NEW_LINE>TweetFeedItemView tweetFeedItemView = (TweetFeedItemView) (view);<NEW_LINE>TwitterStatus status = tweetFeedItemView.getTwitterStatus();<NEW_LINE>FragmentActivity activi... | "status", status.toString()); |
526,212 | public void initFreeStreamer(double tL, double tV, double tH) {<NEW_LINE>double tx = getFacing().getAxis() == Axis.X ? tL : tH;<NEW_LINE>double ty = getFacing().getAxis() <MASK><NEW_LINE>double tz = getFacing().getAxis() == Axis.Y ? tV : getFacing().getAxis() == Axis.X ? tH : tL;<NEW_LINE>Direction f = null;<NEW_LINE>i... | == Axis.Y ? tL : tV; |
1,300,256 | public void initialize() {<NEW_LINE>themeChoiceBox.getItems().addAll(UiTheme.applicableValues());<NEW_LINE>if (!themeChoiceBox.getItems().contains(settings.theme().get())) {<NEW_LINE>settings.theme().set(UiTheme.LIGHT);<NEW_LINE>}<NEW_LINE>themeChoiceBox.valueProperty().bindBidirectional(settings.theme());<NEW_LINE>the... | bindBidirectional(settings.showMinimizeButton()); |
1,558,063 | final CreateSimulationJobResult executeCreateSimulationJob(CreateSimulationJobRequest createSimulationJobRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createSimulationJobRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | false), new CreateSimulationJobResultJsonUnmarshaller()); |
1,298,266 | public String replace(Parameters parameters) {<NEW_LINE>// URL<NEW_LINE>String urlString = url.replace(parameters);<NEW_LINE>if (!Item.checkReq(isRequired, urlString)) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>// Options<NEW_LINE>List<String> optionsString = new ArrayList<>();<NEW_LINE>for (Item option : options) {<N... | return "Request error: " + result.getResponseCode(); |
471,017 | public TableMember unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>TableMember tableMember = new TableMember();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE... | class).unmarshall(context)); |
1,571,166 | public static void openTorrentSimple() {<NEW_LINE>Utils.execSWTThread(new AERunnable() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void runSupport() {<NEW_LINE>final <MASK><NEW_LINE>if (shell == null)<NEW_LINE>return;<NEW_LINE>FileDialog fDialog = new FileDialog(shell, SWT.OPEN | SWT.MULTI);<NEW_LINE>fDialog.setFilt... | Shell shell = Utils.findAnyShell(); |
825,832 | public void asyncSendMessage(SendMessageCallback callback, List<byte[]> bodyList, String groupId, String streamId, long dt, String msgUUID, long timeout, TimeUnit timeUnit, Map<String, String> extraAttrMap) throws ProxysdkException {<NEW_LINE>dt = ProxyUtils.covertZeroDt(dt);<NEW_LINE>if (!ProxyUtils.isBodyValid(bodyLi... | callback, msgUUID, timeout, timeUnit); |
1,383,498 | public void run() {<NEW_LINE>boolean active = TimeHelper.sleepToNextMinute();<NEW_LINE>while (active) {<NEW_LINE>Transaction t = Cat.newTransaction("AlertHeartbeat", TimeHelper.getMinuteStr());<NEW_LINE>long current = System.currentTimeMillis();<NEW_LINE>try {<NEW_LINE>Set<String<MASK><NEW_LINE>for (String domain : dom... | > domains = m_projectService.findAllDomains(); |
7,883 | public void marshall(GetTablesRequest getTablesRequest, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (getTablesRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(getTablesRequest.getCatalogId(), CAT... | getTablesRequest.getTransactionId(), TRANSACTIONID_BINDING); |
310,177 | public boolean deleteRecording(File destDir, String recordingId, File recordingDir, String format) {<NEW_LINE>File metadataXml = recordingServiceHelper.getMetadataXmlLocation(recordingDir.getPath());<NEW_LINE>RecordingMetadata r = recordingServiceHelper.getRecordingMetadata(metadataXml);<NEW_LINE>if (r != null) {<NEW_L... | + File.separatorChar + recordingId)); |
341,975 | public void drawMap(IMAGE_TYPE image, boolean adjustToFit) {<NEW_LINE>imageBdr.initialize(image);<NEW_LINE>imageBdr.setColor(UColor.WHITE);<NEW_LINE>imageBdr.setAreaFilled(true);<NEW_LINE>imageBdr.drawRect(0, 0, imageBdr.getWidth(), imageBdr.getHeight());<NEW_LINE>if (imageBdr.getWidth() > 0 && map != null) {<NEW_LINE>... | imageBdr.setLineStyle(false, 1f); |
179,568 | public void stop(boolean mpOnly, int shutdownMode, boolean closeConnection) throws Exception {<NEW_LINE>if (callback != null)<NEW_LINE>callback.stop(mpOnly, shutdownMode, closeConnection);<NEW_LINE>if (!mpOnly) {<NEW_LINE>if (UnitTestMEStarter.me.getWSRMEngineComponent() != null) {<NEW_LINE>UnitTestMEStarter.me.getWSRM... | .getWSRMEngineComponent().destroy(); |
1,023,109 | public SortField visitReference(Reference ref, final SortSymbolContext context) {<NEW_LINE>// can't use the SortField(fieldName, type) constructor<NEW_LINE>// because values are saved using docValues and therefore they're indexed in lucene as binary and not<NEW_LINE>// with the reference valueType.<NEW_LINE>// this is ... | ColumnIdent columnIdent = ref.column(); |
1,105,073 | static <T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> Seq<Tuple10<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>> zipAll(Iterable<? extends T1> s1, Iterable<? extends T2> s2, Iterable<? extends T3> s3, Iterable<? extends T4> s4, Iterable<? extends T5> s5, Iterable<? extends T6> s6, Iterable<? extends T7> s7, Iterable<? extends T8... | default9, default10, Tuple::tuple); |
1,819,780 | // this method MUST NOT be called with the wabgroup locked.. (and must not lock the wabGroup)<NEW_LINE>// this method is only used when the entire wabGroup is being removed, which occurs during<NEW_LINE>// server-stop and in response to the removal of the wab feature from the server config.<NEW_LINE>void uninstallGroup... | = new ArrayList<WAB>(); |
811,208 | private static EObject capture(String subject, MatchResult mr, int group_index, Options opts) {<NEW_LINE>int start = mr.start(group_index);<NEW_LINE>if (start == -1) {<NEW_LINE>return nocapture(opts);<NEW_LINE>}<NEW_LINE>int end = mr.end(group_index);<NEW_LINE>if (opts.capture_type == am_index) {<NEW_LINE>if (INDEX_COM... | subject.substring(start, end); |
1,562,371 | final ListSolutionVersionsResult executeListSolutionVersions(ListSolutionVersionsRequest listSolutionVersionsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listSolutionVersionsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRe... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "ListSolutionVersions"); |
635,687 | private void deleteAccountAndReturnIfNecessary() {<NEW_LINE>if (mInitMode && mAccount != null && !mAccount.isOptionSet(Account.OPTION_LOGGED_IN_SUCCESSFULLY)) {<NEW_LINE>xmppConnectionService.deleteAccount(mAccount);<NEW_LINE>}<NEW_LINE>final boolean magicCreate = mAccount != null && mAccount.isOptionSet(Account.OPTION... | ? null : xmppConnectionService.getAccounts(); |
460,752 | final GetDeviceResult executeGetDevice(GetDeviceRequest getDeviceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getDeviceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_L... | addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig); |
589,182 | private BaseBottomSheetItem createShowAlongTheRouteItem(final LocalRoutingParameter optionsItem) {<NEW_LINE>return new SimpleBottomSheetItem.Builder().setIcon(getContentIcon((optionsItem.getActiveIconId()))).setTitle(getString(R.string.show_along_the_route)).setLayoutId(R.layout.bottom_sheet_item_simple_56dp).setOnClic... | routingOptionsHelper.addNewRouteMenuParameter(applicationMode, optionsItem); |
1,749,868 | // Uses a few rules to stem tokens<NEW_LINE>public static String stem(String a) {<NEW_LINE>int i = a.indexOf(' ');<NEW_LINE>if (i != -1)<NEW_LINE>return stem(a.substring(0, i)) + ' ' + stem(a.substring(i + 1));<NEW_LINE>// Maybe we should just use the Stanford stemmer<NEW_LINE>String res = a;<NEW_LINE>// hard coded wor... | a.length() - 3); |
615,085 | public int cb(http_parser.lolevel.HTTPParser p, ByteBuffer buf, int pos, int len) {<NEW_LINE>IRubyObject ret = runtime.getNil();<NEW_LINE>byte[] data = fetchBytes(buf, pos, len);<NEW_LINE>if (callback_object != null) {<NEW_LINE>if (((RubyObject) callback_object).respond_to_p(runtime.newSymbol("on_body")).toJava(Boolean... | (new String(data))); |
72,764 | private String fixRepositoryName(String repositoryName) {<NEW_LINE>if (StringUtils.isEmpty(repositoryName)) {<NEW_LINE>return repositoryName;<NEW_LINE>}<NEW_LINE>// Decode url-encoded repository name (issue-278)<NEW_LINE>// http://stackoverflow.com/questions/17183110<NEW_LINE>String name = repositoryName.replace("%7E",... | ).replace("%2f", "/"); |
926,956 | public UpdateClusterResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>UpdateClusterResult updateClusterResult = new UpdateClusterResult();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonTok... | int originalDepth = context.getCurrentDepth(); |
1,032,777 | private double computeImpactB(IntVar v, int a, int b, double before) {<NEW_LINE>model<MASK><NEW_LINE>double after;<NEW_LINE>try {<NEW_LINE>v.updateBounds(a, b, this);<NEW_LINE>model.getSolver().getEngine().propagate();<NEW_LINE>after = searchSpaceSize(vars);<NEW_LINE>return 1.0d - (after / before);<NEW_LINE>} catch (Co... | .getEnvironment().worldPush(); |
144,811 | public void handle(GlowSession session, LoginStartMessage message) {<NEW_LINE>String name = message.getUsername();<NEW_LINE>int length = name.length();<NEW_LINE>if (length > 16 || !usernamePattern.matcher(name).find()) {<NEW_LINE>session.disconnect("Invalid username provided.", true);<NEW_LINE>}<NEW_LINE>GlowServer ser... | getPublic()).getEncoded(); |
1,487,918 | public void save(File file) throws IOException {<NEW_LINE>PrintStream out = new PrintStream(file, "UTF-8");<NEW_LINE>out.println("font.name=" + fontName);<NEW_LINE><MASK><NEW_LINE>out.println("font.bold=" + bold);<NEW_LINE>out.println("font.italic=" + italic);<NEW_LINE>out.println("font.gamma=" + gamma);<NEW_LINE>out.p... | out.println("font.size=" + fontSize); |
1,365,343 | private JoinReference buildJoin(Queryable source, String referenceName, Map<String, Argument> callingColumnArgs, Map<String, Argument> fixedArguments) {<NEW_LINE>Queryable root = source.getRoot();<NEW_LINE>Type<?> tableClass = dictionary.getEntityClass(root.getName(), root.getVersion());<NEW_LINE>JoinPath joinPath = ne... | (1)).build(); |
281,240 | boolean checkType(TypeBinding binding) {<NEW_LINE>if (binding == null)<NEW_LINE>return false;<NEW_LINE>switch(binding.kind()) {<NEW_LINE>case Binding.PARAMETERIZED_TYPE:<NEW_LINE>TypeBinding[] arguments = <MASK><NEW_LINE>if (arguments == null)<NEW_LINE>return false;<NEW_LINE>for (int i = 0, length = arguments.length; i... | ((ParameterizedTypeBinding) binding).arguments; |
1,668,053 | public static ListOrdersResponse unmarshall(ListOrdersResponse listOrdersResponse, UnmarshallerContext _ctx) {<NEW_LINE>listOrdersResponse.setRequestId(_ctx.stringValue("ListOrdersResponse.RequestId"));<NEW_LINE>listOrdersResponse.setTotalCount(_ctx.longValue("ListOrdersResponse.TotalCount"));<NEW_LINE>listOrdersRespon... | ("ListOrdersResponse.Orders[" + i + "].CommitterId")); |
938,270 | public DescribeCACertificateResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>DescribeCACertificateResult describeCACertificateResult = new DescribeCACertificateResult();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = ori... | int originalDepth = context.getCurrentDepth(); |
647,747 | protected void onCreate(Bundle savedInstanceState) {<NEW_LINE>((Infinity) getApplication()).getAppComponent().inject(this);<NEW_LINE>setImmersiveModeNotApplicable();<NEW_LINE>super.onCreate(savedInstanceState);<NEW_LINE><MASK><NEW_LINE>ButterKnife.bind(this);<NEW_LINE>applyCustomTheme();<NEW_LINE>if (Build.VERSION.SDK_... | setContentView(R.layout.activity_view_private_messages); |
284,005 | public static void complete(File datadir) {<NEW_LINE>File renderdata = new File(datadir, "renderdata");<NEW_LINE>File dynamicrenderdata = new File(renderdata, "modsupport");<NEW_LINE>dynamicrenderdata.mkdirs();<NEW_LINE>// Clean up anything in directory<NEW_LINE>File[] files = dynamicrenderdata.listFiles();<NEW_LINE>fo... | tdi.getModVersion() + " skipped"); |
100,679 | private boolean writeOff(int invoiceId, String documentNo, Timestamp dateInvoiced, int currencyId, BigDecimal openAmt) {<NEW_LINE>// Nothing to do<NEW_LINE>if (openAmt == null || openAmt.signum() == 0)<NEW_LINE>return false;<NEW_LINE>if (openAmt.abs().compareTo(getMaxInvWriteOffAmt()) >= 0)<NEW_LINE>return false;<NEW_L... | payment.setTenderType(MPayment.TENDERTYPE_Check); |
1,257,707 | public static Query<? extends Model> createQuery(Long recordId, DataConfigLine line, Class<? extends Model> modelClass) throws AxelorException {<NEW_LINE>String filter;<NEW_LINE>switch(line.getTypeSelect()) {<NEW_LINE>case DataConfigLineRepository.TYPE_PATH:<NEW_LINE>MetaField relationalField = line.getMetaFieldPath();... | getMetaModel().getName()); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.