idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
998,258 | private void createEdges(int origEdgeKey, int origRevEdgeKey, GHPoint3D prevSnapped, int prevWayIndex, boolean isPillar, GHPoint3D currSnapped, int wayIndex, PointList fullPL, EdgeIteratorState closestEdge, int prevNodeId, int nodeId) {<NEW_LINE>int max = wayIndex + 1;<NEW_LINE>PointList basePoints = new PointList(max ... | (), baseReversePoints, !reverse); |
260,760 | public void run() {<NEW_LINE>String configInfo;<NEW_LINE>try {<NEW_LINE>configInfo = HttpUtils.doGet(url, ImmutableMap.<String, String>builder().put(AUTHORIZATION, authorization).build());<NEW_LINE>List<List<String>> configs = GsonUtils.GSON.fromJson(configInfo, new TypeToken<List<List<String>>>() {<NEW_LINE>}.getType(... | first, hostPort.second, e); |
1,177,232 | public StreamCopier create(String configuredSchema, AzureBlobStorageConfig azureBlobConfig, String stagingFolder, ConfiguredAirbyteStream configuredStream, ExtendedNameTransformer nameTransformer, JdbcDatabase db, SqlOperations sqlOperations) {<NEW_LINE>try {<NEW_LINE>AirbyteStream stream = configuredStream.getStream()... | getNamespace(), configuredSchema, nameTransformer); |
535,506 | final DBSecurityGroup executeCreateDBSecurityGroup(CreateDBSecurityGroupRequest createDBSecurityGroupRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createDBSecurityGroupRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMe... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
347,599 | public boolean convert(String inputFile, String toName, boolean fixHTML, Map<String, String> notes) {<NEW_LINE>try {<NEW_LINE>final FileOutputStream out = new FileOutputStream(new File(toName));<NEW_LINE>ZipOutputStream zos = new ZipOutputStream(out);<NEW_LINE>zos.setLevel(0);<NEW_LINE><MASK><NEW_LINE>writeToZip(zos, "... | writeToZip(zos, "mimetype", "application/epub+zip"); |
1,763,571 | private void drawSample(String _title, String[] _xAxisLabels, String _xAxisTitle, String _yAxisTitle, double[][] _data, int _width, int _height, Graphics g) {<NEW_LINE>try {<NEW_LINE>if (_width == 0) {<NEW_LINE>_width = 450;<NEW_LINE>}<NEW_LINE>if (_height == 0) {<NEW_LINE>_height = 250;<NEW_LINE>}<NEW_LINE>this.setPre... | axisProperties, legendProperties, _width, _height); |
142,831 | public void drawAnchor(UGraphic ug, CommonTile tile1, CommonTile tile2, ISkinParam skinParam) {<NEW_LINE>final double y1 = tile1.getY<MASK><NEW_LINE>final double y2 = tile2.getY() + tile2.getContactPointRelative();<NEW_LINE>final double xx1 = tile1.getMiddleX();<NEW_LINE>final double xx2 = tile2.getMiddleX();<NEW_LINE>... | () + tile1.getContactPointRelative(); |
593,651 | public void executeAttack() {<NEW_LINE>// needs to execute the isVulnerable method to configure the workflow<NEW_LINE>// type<NEW_LINE>boolean vulnerable = isVulnerable();<NEW_LINE>LOGGER.info("Using the following oracle type: {}", vulnerableType);<NEW_LINE>if (!vulnerable) {<NEW_LINE>LOGGER.warn("The server is not vul... | oracle, config.isMsgPkcsConform()); |
909,166 | protected final Number openNonAssetNative(int cookie, String fileName, int accessMode) throws FileNotFoundException {<NEW_LINE>CppAssetManager am = assetManagerForJavaObject();<NEW_LINE>if (am == null) {<NEW_LINE>return RuntimeEnvironment.castNativePtr(0);<NEW_LINE>}<NEW_LINE>ALOGV(<MASK><NEW_LINE>String fileName8 = fi... | "openNonAssetNative in %s (Java object %s)\n", am, AssetManager.class); |
962,257 | /*<NEW_LINE>* Type entries are encoded as:<NEW_LINE>* simpleTypeName / packageName / enclosingTypeName / modifiers<NEW_LINE>* e.g. Object/java.lang//0<NEW_LINE>* e.g. Cloneable/java.lang//512<NEW_LINE>* e.g. LazyValue/javax.swing/UIDefaults/0<NEW_LINE>* or for secondary types as:<NEW_LINE>* simpleTypeName / pac... | '.', key, start, last); |
1,504,792 | private static List<? extends TypeMirror> computeNewClass(Set<ElementKind> types, CompilationInfo info, TreePath parent, Tree error, int offset) {<NEW_LINE>NewClassTree nct = (NewClassTree) parent.getLeaf();<NEW_LINE>boolean errorInRealArguments = false;<NEW_LINE>for (Tree param : nct.getArguments()) {<NEW_LINE>errorIn... | types.add(ElementKind.LOCAL_VARIABLE); |
1,645,255 | public FlowInfo analyseCode(BlockScope currentScope, FlowContext flowContext, FlowInfo flowInfo) {<NEW_LINE>Constant cst = this.left.optimizedBooleanConstant();<NEW_LINE>boolean isLeftOptimizedTrue = cst != Constant.NotAConstant && cst.booleanValue() == true;<NEW_LINE>boolean isLeftOptimizedFalse = cst != Constant.NotA... | previousMode).unconditionalInits())); |
936,129 | private void checkForCycles() {<NEW_LINE>final TIntObjectHashMap<TIntHashSet> transitivePredecessors = new TIntObjectHashMap<>();<NEW_LINE>myRegisteredPassFactories.forEachEntry(new TIntObjectProcedure<PassConfig>() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public boolean execute(int passId, PassConfig config) {<NEW_LINE... | transitivePredecessors.put(passId, allPredecessors); |
455,719 | public void render(MatrixStack matrixStack, int mouseX, int mouseY, float partialTicks) {<NEW_LINE>renderBackground(matrixStack);<NEW_LINE>Matrix4f matrix = matrixStack.peek().getPositionMatrix();<NEW_LINE>BufferBuilder bufferBuilder = Tessellator.getInstance().getBuffer();<NEW_LINE>RenderSystem.setShader(GameRenderer:... | 2 - 100, 87, 10526880); |
876,034 | protected Control createContents(Composite parent) {<NEW_LINE>Composite area = new Composite(parent, SWT.NONE);<NEW_LINE>GridLayoutFactory.fillDefaults().numColumns(2).applyTo(area);<NEW_LINE>Label label = new Label(area, SWT.NONE);<NEW_LINE><MASK><NEW_LINE>languageCombo = new ComboViewer(area, SWT.READ_ONLY);<NEW_LINE... | label.setText(Messages.LabelLanguage); |
722,244 | public void updated(Dictionary<String, ?> config) throws ConfigurationException {<NEW_LINE>logger.trace("updated() is called!");<NEW_LINE>if (config != null) {<NEW_LINE>startWatchdog();<NEW_LINE>port = DEFAULT_PORT;<NEW_LINE>host = (String) config.get("host");<NEW_LINE>password = (String) config.get("password");<NEW_LI... | , LinkedList<FreeswitchBindingConfig>>(); |
1,770,325 | protected ByteBuf[] serialize(WriteRequest message) throws IOException {<NEW_LINE>if (message.hasCommand()) {<NEW_LINE>byte[] command = new byte[message.getSerializedSize()];<NEW_LINE>CodedOutputStream stream = CodedOutputStream.newInstance(command);<NEW_LINE>message.writeTo(stream);<NEW_LINE>return new ByteBuf[] { Unp... | stream = CodedOutputStream.newInstance(header); |
1,257,085 | public static GetRepositoryTagV2Response unmarshall(GetRepositoryTagV2Response getRepositoryTagV2Response, UnmarshallerContext _ctx) {<NEW_LINE>getRepositoryTagV2Response.setRequestId(_ctx.stringValue("GetRepositoryTagV2Response.RequestId"));<NEW_LINE>getRepositoryTagV2Response.setErrorCode(_ctx.stringValue("GetReposit... | (_ctx.stringValue("GetRepositoryTagV2Response.Result.Commit.ShortId")); |
197,740 | public void load() {<NEW_LINE>this.resetComponents();<NEW_LINE>try {<NEW_LINE>// Get a working copy of the interesting files set definitions and sort<NEW_LINE>// by set name.<NEW_LINE>if (panelType == PANEL_TYPE.FILE_INGEST_FILTERS) {<NEW_LINE>this.filesSets = new TreeMap<>(FilesSetsManager.<MASK><NEW_LINE>} else {<NEW... | getInstance().getCustomFileIngestFilters()); |
1,580,668 | private Text createFileLink(String pathToFile) {<NEW_LINE>LinkedFile linkedFile = new LinkedFile("", Path.of(pathToFile), "pdf");<NEW_LINE>Text fileLinkText = new Text(Localization.lang("Found match in %0", pathToFile) + System.lineSeparator() + System.lineSeparator());<NEW_LINE>fileLinkText.setStyle("-fx-font-weight: ... | toAbsolutePath().toString()); |
942,854 | public void readSpanValue(Buffer buffer, SpanBo span, SpanDecodingContext decodingContext) {<NEW_LINE>final byte version = buffer.readByte();<NEW_LINE>span.setVersion(version);<NEW_LINE>final SpanBitFiled bitFiled = new SpanBitFiled(buffer.readByte());<NEW_LINE>final short serviceType = buffer.readShort();<NEW_LINE>spa... | setAcceptorHost(buffer.readPrefixedString()); |
347,731 | protected void put(int[][] mbPix, byte[][] buf, int stride, int chromaFormat, int mbX, int mbY, int width, int height, int vertOff, int vertStep) {<NEW_LINE>int chromaStride = (stride + (1 << SQUEEZE_X[chromaFormat]) - 1) >> SQUEEZE_X[chromaFormat];<NEW_LINE>int chromaMBW = 3 - SQUEEZE_X[chromaFormat];<NEW_LINE>int chr... | [0], 3, 3); |
1,851,541 | public void translate(final ITranslationEnvironment environment, final IInstruction instruction, final List<ReilInstruction> instructions) throws InternalTranslationException {<NEW_LINE>TranslationHelpers.checkTranslationArguments(environment, instruction, instructions, "divu");<NEW_LINE>final String sourceRegister1 = ... | , reminder, dw, "HI")); |
439,449 | private MethodTree createMethodDefinition(boolean mustStatic) {<NEW_LINE>// if all the statements are contained within a Block, get just the block, it will be processed recursively<NEW_LINE>List<VariableTree> formalArguments = IntroduceHint.createVariables(copy, parameters, pathToClass, statementPaths.subList(from, to ... | = new LinkedList<TypeParameterTree>(); |
1,788,372 | public void verifyEJBMethodInjection() throws Exception {<NEW_LINE>String envName = null;<NEW_LINE>assertNotNull("Injected Method Field is set : " + ivMethodInjected, ivMethodInjected);<NEW_LINE>ivMethodInjected.tx_Default();<NEW_LINE>svLogger.info("Method called successfully on Injected Method Field");<NEW_LINE>// Nex... | envName + ") not null :" + ivMethodInjected, ivMethodInjected); |
417,730 | public AuditableRestAction<Void> transferOwnership(@Nonnull Member newOwner) {<NEW_LINE>Checks.notNull(newOwner, "Member");<NEW_LINE>checkGuild(newOwner.getGuild(), "Member");<NEW_LINE>if (!getSelfMember().isOwner())<NEW_LINE>throw new PermissionException("The logged in account must be the owner of this Guild to be abl... | MODIFY_GUILD.compile(getId()); |
440,046 | private boolean killDecision(Entity e, List<String> thingsToKill, boolean negateAnimals, boolean negateMonsters, boolean specifiedAnimals, boolean specifiedMonsters) {<NEW_LINE>boolean negate = false;<NEW_LINE>boolean specified = false;<NEW_LINE>if (e instanceof Golem || e instanceof Squid || e instanceof Animals || (a... | ).getName(), e); |
1,834,560 | public static Query newSetQuery(String field, InetAddress... values) {<NEW_LINE>// We must compare the encoded form (InetAddress doesn't implement Comparable, and even if it<NEW_LINE>// did, we do our own thing with ipv4 addresses):<NEW_LINE>// NOTE: we could instead convert-per-comparison and save this extra array, at... | byte[values.length][]; |
1,413,637 | public void marshall(CreateFlowDefinitionRequest createFlowDefinitionRequest, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (createFlowDefinitionRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(cre... | createFlowDefinitionRequest.getHumanLoopActivationConfig(), HUMANLOOPACTIVATIONCONFIG_BINDING); |
782,623 | static String fixupGuardedBlocks(String indentedLine) {<NEW_LINE>int <MASK><NEW_LINE>if (offset == -1)<NEW_LINE>return indentedLine;<NEW_LINE>// move the guarded block at the end of the first line in the string<NEW_LINE>// NOI18N<NEW_LINE>int firstLineEnd = indentedLine.indexOf('\n');<NEW_LINE>if (firstLineEnd == -1 ||... | offset = indentedLine.indexOf(MAGIC_PREFIX); |
1,748,402 | private static JScrollPane createScrollableTreeAddOnsNotRunnable(final AddOnCollection availableAddOns, AddOn... addOnsNotRunnable) {<NEW_LINE>AddOnSearcher addOnSearcher = new AddOnSearcher() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public AddOn searchAddOn(String id) {<NEW_LINE>return availableAddOns.getAddOn(id);<NEW... | DefaultMutableTreeNode rootNode = new DefaultMutableTreeNode(""); |
1,508,416 | private void checkGradients() {<NEW_LINE>List<NDArray> grads = new ArrayList<>();<NEW_LINE>model.getBlock().getParameters().values().stream().filter(Parameter::requiresGradient).forEach(param -> grads.add(parameterStore.getValue(param, devices[0], <MASK><NEW_LINE>try (NDManager scoped = manager.newSubManager()) {<NEW_L... | true).getGradient())); |
915,850 | private Switch createPlayerButtons() {<NEW_LINE>final Switch playerItemSwitch = SitemapFactory.eINSTANCE.createSwitch();<NEW_LINE>final List<Mapping> mappings = playerItemSwitch.getMappings();<NEW_LINE>Mapping commandMapping;<NEW_LINE>mappings.add(commandMapping = SitemapFactory.eINSTANCE.createMapping());<NEW_LINE>com... | PlayPauseType.PAUSE.name()); |
895,152 | private static void genArticle(final String permalink) throws Exception {<NEW_LINE>if (!StringUtils.endsWithIgnoreCase(permalink, ".html") && !StringUtils.endsWithIgnoreCase(permalink, ".htm")) {<NEW_LINE>FileUtils.forceMkdir(<MASK><NEW_LINE>final String html = Mocks.mockRequest(permalink, scheme, host);<NEW_LINE>final... | new File(staticSitePath + permalink)); |
955,727 | public Map<String, Object> invoke() {<NEW_LINE>final Map<String, Object> result = new HashMap<>();<NEW_LINE>if (sentinelProperties.isEnabled()) {<NEW_LINE>result.put("appName", AppNameUtil.getAppName());<NEW_LINE>result.put("logDir", LogBase.getLogBaseDir());<NEW_LINE>result.put("logUsePid", LogBase.isLogNameUsePid());... | "systemRules", SystemRuleManager.getRules()); |
405,550 | public void exportSection(PrintPageFormat pageFormat, JRGridLayout pageGridLayout, boolean lastPage) {<NEW_LINE>if (!lastPage) {<NEW_LINE>write(" <w:p>\n");<NEW_LINE>write(" <w:pPr>\n");<NEW_LINE>}<NEW_LINE>write(" <w:sectPr>\n");<NEW_LINE>write(" <w:pgSz w:w=\"" + LengthUtil.twip(pageFormat.getPageWidth()) + ... | .twip(leftMargin) + "\" w:header=\"0\" w:footer=\"0\" w:gutter=\"0\" />\n"); |
1,444,124 | private static org.netbeans.modules.web.jsps.parserapi.PageInfo convertPageInfo(PageInfo pageInfo, String xmlView, JspCompilationContext ctxt) throws JspException {<NEW_LINE>PageInfoImpl nbPageInfo = new PageInfoImpl(getTaglibsMapReflect(pageInfo, ctxt), getJSPPrefixMapperReflect(pageInfo), getXMLPrefixMapperReflect(pa... | setErrorPage(pageInfo.getErrorPage()); |
544,001 | private void handleActionUpdate(String url) {<NEW_LINE>manager = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);<NEW_LINE>builder = new NotificationCompat.Builder(this);<NEW_LINE>builder.setContentTitle(CheckForUpdateUtil.getStringRes(R.string.update_downloading)).setContentText(CheckForUpdateUtil.getStri... | BuildConfig.APPLICATION_ID + ".fileprovider", file); |
1,211,371 | public boolean handle(KeyEvent event) {<NEW_LINE>event = mTranslator.doTranslateKeys(event);<NEW_LINE>setDispatchEvent(event);<NEW_LINE>boolean isUpAction = event.getAction() == DEFAULT_ACTION;<NEW_LINE>boolean isDownAction = event.getAction() == KeyEvent.ACTION_DOWN;<NEW_LINE>// user opens the video and continue to ho... | boolean uiVisible = mFragment.isUiVisible(); |
76,962 | private void appendObjectStringify(Writer writer, HollowDataAccess dataAccess, HollowObjectTypeDataAccess typeDataAccess, int ordinal, int indentation) throws IOException {<NEW_LINE>HollowObjectSchema schema = typeDataAccess.getSchema();<NEW_LINE>if (schema.numFields() == 1 && (collapseAllSingleFieldObjects || collapse... | (fieldName).append("\": "); |
1,206,738 | public static ListDataSourcesResponse unmarshall(ListDataSourcesResponse listDataSourcesResponse, UnmarshallerContext _ctx) {<NEW_LINE>listDataSourcesResponse.setRequestId(_ctx.stringValue("ListDataSourcesResponse.RequestId"));<NEW_LINE>listDataSourcesResponse.setSuccess(_ctx.booleanValue("ListDataSourcesResponse.Succe... | ("ListDataSourcesResponse.DataSources[" + i + "].GmtModified")); |
1,501,039 | private void updateLightListUniforms(Matrix4f viewMatrix, Shader shader, LightList lights) {<NEW_LINE>Uniform ambientColor = shader.getUniform("g_AmbientLightColor");<NEW_LINE>ambientColor.setValue(VarType.Vector4, getAmbientColor(lights, true, ambientLightColor));<NEW_LINE>Uniform lightData = shader.getUniform("g_Ligh... | float invRadius = light.getInvRadius(); |
505,776 | public void marshall(SignUpRequest signUpRequest, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (signUpRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(signUpRequest.getClientId(), CLIENTID_BINDING... | e.getMessage(), e); |
1,733,068 | public ApiResponse<Subscription> subscriptionGetSubscriptionWithHttpInfo() throws ApiException {<NEW_LINE>Object localVarPostBody = null;<NEW_LINE>// create path and map variables<NEW_LINE>String localVarPath = "/v4/subscription";<NEW_LINE>// query params<NEW_LINE>List<Pair> localVarQueryParams = new ArrayList<Pair>();... | localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); |
1,460,083 | public void saveToFile() {<NEW_LINE>// create properties<NEW_LINE>Properties properties = new Properties();<NEW_LINE>// get parameters<NEW_LINE>properties.setProperty("param_migrationMode_isUpgrade", booleanToString(isUpgrade()));<NEW_LINE>if (getLogLevel() != null)<NEW_LINE>properties.setProperty("param_maxLogLevel", ... | , booleanToString(isDropSource())); |
1,695,279 | public void testAsyncInvoker_post3(Map<String, String> param, StringBuilder ret) {<NEW_LINE>String serverIP = param.get("serverIP");<NEW_LINE>String serverPort = param.get("serverPort");<NEW_LINE><MASK><NEW_LINE>Client c = cb.build();<NEW_LINE>WebTarget t = c.target("http://" + serverIP + ":" + serverPort + "/bookstore... | ClientBuilder cb = ClientBuilder.newBuilder(); |
1,254,107 | private static void adjustTypeDescriptions(Map<Class<?>, ExpandedTypeDescription> types) {<NEW_LINE>ExpandedTypeDescription pathItemTD = types.get(PathItem.class);<NEW_LINE>for (PathItem.HttpMethod m : PathItem.HttpMethod.values()) {<NEW_LINE>pathItemTD.substituteProperty(m.name().toLowerCase(), Operation.class, getter... | addPropertyParameters("enum", String.class); |
947,419 | protected void parseIntent(Context ctx, String action, Bundle bundle) throws IllegalArgumentException {<NEW_LINE>boolean playing = bundle.getBoolean("playing", false);<NEW_LINE>if (!playing) {<NEW_LINE>// if not playing, there is no guarantee the bundle will contain any track info<NEW_LINE>setState(MicroService.State.U... | mbid = bundle.getString("mb-trackid"); |
352,066 | public static ClientMessage encodeRequest(java.lang.String name, com.hazelcast.internal.serialization.Data key, com.hazelcast.internal.serialization.Data value, long threadId, long ttl, long maxIdle) {<NEW_LINE>ClientMessage clientMessage = ClientMessage.createForEncode();<NEW_LINE>clientMessage.setRetryable(false);<NE... | initialFrame.content, REQUEST_MAX_IDLE_FIELD_OFFSET, maxIdle); |
245,886 | public void process(int row, int[] scores) {<NEW_LINE>int indexDisparity = imageDisparity.startIndex + row * imageDisparity.stride;<NEW_LINE>// Mark all pixels as invalid which can't be estimate due to disparityMin<NEW_LINE>for (int col = 0; col < disparityMin; col++) {<NEW_LINE>imageDisparity.data[<MASK><NEW_LINE>}<NE... | indexDisparity++] = (byte) disparityRange; |
599,831 | // hmm, one listener can be added more times but should not be problem since frameworks in project do not change often...<NEW_LINE>private void listenOnFrameworks() {<NEW_LINE>List<PhpFrameworkProvider> frameworks = project.getFrameworks();<NEW_LINE>List<ImportantFilesImplementation> newConfigFiles = new ArrayList<>(fr... | "PHP framework {0} uses deprecated method, switch to PhpFrameworkProvider.getConfigurationFiles2()", framework.getIdentifier()); |
250,101 | protected static Media readMedia(JsonNode node) {<NEW_LINE>Media media = new Media();<NEW_LINE>JsonNode bitrate = node.get("bitrate");<NEW_LINE>if (bitrate != null && !bitrate.isNull()) {<NEW_LINE>media.bitrate = bitrate.intValue();<NEW_LINE>media.hasBitrate = true;<NEW_LINE>}<NEW_LINE>media.copyright = node.path("copy... | add(person.textValue()); |
1,329,826 | protected boolean shouldSkipOverrideProperty(P property) {<NEW_LINE>P existingProperty = entity.getPersistentProperty(property.getName());<NEW_LINE>if (existingProperty == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>Class<?> declaringClass = getDeclaringClass(property);<NEW_LINE>Class<?> existingDeclaringClass =... | ?> existingPropertyType = getPropertyType(existingProperty); |
271,212 | public static DescribeAppGroupDataReportResponse unmarshall(DescribeAppGroupDataReportResponse describeAppGroupDataReportResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeAppGroupDataReportResponse.setRequestId(_ctx.stringValue("DescribeAppGroupDataReportResponse.requestId"));<NEW_LINE>Result result = new Result()... | ("DescribeAppGroupDataReportResponse.result.receivedSample[" + i + "].receivedTimeMs")); |
1,165,285 | public OutlierResult run(Relation<O> relation) {<NEW_LINE><MASK><NEW_LINE>QueryBuilder<O> qb = new QueryBuilder<>(relation, distance);<NEW_LINE>// Phase one: KNN and k-dist<NEW_LINE>WritableDoubleDataStore kdists = DataStoreUtil.makeDoubleStorage(ids, DataStoreFactory.HINT_DB);<NEW_LINE>WritableDataStore<KNNList> knns ... | DBIDs ids = relation.getDBIDs(); |
1,299,990 | public InputDefinition unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>InputDefinition inputDefinition = new InputDefinition();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDep... | )).unmarshall(context)); |
1,348,576 | public org.python.Object __imul__(org.python.Object other) {<NEW_LINE>if (other instanceof org.python.types.Int) {<NEW_LINE>long count = ((org.python.types.Int) other).value;<NEW_LINE>org.python.types.List result = new org.python.types.List();<NEW_LINE>for (long i = 0; i < count; i++) {<NEW_LINE>result.value.addAll(thi... | types.Bool) other).value; |
1,144,500 | public DeleteMessageBatchRequestEntry unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>DeleteMessageBatchRequestEntry deleteMessageBatchRequestEntry = new DeleteMessageBatchRequestEntry();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LI... | ().unmarshall(context)); |
122,231 | private void registerCommands(CommandDispatcher<CommandSourceStack> dispatcher, boolean dedicated) {<NEW_LINE>WorldEdit.getInstance().getEventBus().post(new PlatformsRegisteredEvent());<NEW_LINE>PlatformManager manager = WorldEdit.getInstance().getPlatformManager();<NEW_LINE>Platform commandsPlatform = <MASK><NEW_LINE>... | manager.queryCapability(Capability.USER_COMMANDS); |
771,683 | public synchronized Future start() throws IllegalStateException {<NEW_LINE>if (isStopping() || isStopped() || isFailed()) {<NEW_LINE>throw new IllegalStateException(getIdentifier() + " is stopping or stopped, can not start again");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>if (isStarting() || isStarted()) {<NEW_LINE>return st... | ) + " start failed: " + e, e); |
1,715,820 | static <T, M extends Regression<T>> RegressionMetrics regression(T[] x, double[] y, BiFunction<T[], double[], M> trainer) {<NEW_LINE>int n = x.length;<NEW_LINE>int[][] train = LOOCV.of(n);<NEW_LINE>double[] prediction = new double[n];<NEW_LINE>long fitTime = 0;<NEW_LINE>long scoreTime = 0;<NEW_LINE>for (int i = 0; i < ... | long start = System.nanoTime(); |
1,094,346 | private void onIsolinesStateChanged(@NonNull IsolinesState type) {<NEW_LINE>if (type != IsolinesState.EXPIREDDATA) {<NEW_LINE>type.activate(this, findViewById(R.id.coordinator), findViewById(R.id.menu_frame));<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>com.mapswithme.maps.dialog.AlertDialog dialog = new com.mapswithme.maps.d... | dialog.show(this, ISOLINES_ERROR_DIALOG_TAG); |
800,550 | protected Expression transformDeclarationExpression(final DeclarationExpression de) {<NEW_LINE>visitAnnotations(de);<NEW_LINE>Expression oldLeft = de.getLeftExpression();<NEW_LINE>checkingVariableTypeInDeclaration = true;<NEW_LINE>Expression left = transform(oldLeft);<NEW_LINE>checkingVariableTypeInDeclaration = false;... | setDeclaringClass(de.getDeclaringClass()); |
1,145,013 | public static GetQualityResultResponse unmarshall(GetQualityResultResponse getQualityResultResponse, UnmarshallerContext _ctx) {<NEW_LINE>getQualityResultResponse.setRequestId(_ctx.stringValue("GetQualityResultResponse.RequestId"));<NEW_LINE>getQualityResultResponse.setMessage(_ctx.stringValue("GetQualityResultResponse... | ("GetQualityResultResponse.Data.QualityResultResponseList[" + i + "].ChannelType")); |
1,751,547 | public static void main(String[] args) {<NEW_LINE>Loader.loadNativeLibraries();<NEW_LINE>// [START solver]<NEW_LINE>// Create the linear solver with the GLOP backend.<NEW_LINE>MPSolver solver = MPSolver.createSolver("GLOP");<NEW_LINE>// [END solver]<NEW_LINE>// [START variables]<NEW_LINE>// Create the variables x and y... | "Objective value = " + objective.value()); |
5,189 | public final void signedFactor() throws RecognitionException, TokenStreamException {<NEW_LINE>returnAST = null;<NEW_LINE>ASTPair currentAST = new ASTPair();<NEW_LINE>PascalAST signedFactor_AST = null;<NEW_LINE>{<NEW_LINE>switch(LA(1)) {<NEW_LINE>case PLUS:<NEW_LINE>{<NEW_LINE>PascalAST tmp123_AST = null;<NEW_LINE>tmp12... | .create(LT(1)); |
1,501,646 | public BDDDomain[] extDomain(BigInteger[] domainSizes) {<NEW_LINE>int offset = fdvarnum;<NEW_LINE>int binoffset;<NEW_LINE>int extravars = 0;<NEW_LINE>int n, bn;<NEW_LINE>boolean more;<NEW_LINE>int num = domainSizes.length;<NEW_LINE>{<NEW_LINE>domain = new BDDDomain[num];<NEW_LINE>} else /* Allocated before */<NEW_LINE>... | ] d2 = new BDDDomain[fdvaralloc]; |
965,208 | public void visitFor(SFor userForNode, ScriptScope scriptScope) {<NEW_LINE>ForLoopNode irForLoopNode = new ForLoopNode(userForNode.getLocation());<NEW_LINE>irForLoopNode.setInitializerNode(visit(userForNode.getInitializerNode(), scriptScope));<NEW_LINE>irForLoopNode.setConditionNode(injectCast(userForNode.getConditionN... | .getBlockNode(), scriptScope)); |
1,346,742 | public static long parseFromSize(String str) {<NEW_LINE>if (str == null || str.isEmpty()) {<NEW_LINE>return -1;<NEW_LINE>}<NEW_LINE>str = str.toLowerCase();<NEW_LINE>long fromScale = BYTE_SIZE;<NEW_LINE>try {<NEW_LINE>if (str.endsWith("kb")) {<NEW_LINE>str = str.substring(0, str.length() - 2).trim();<NEW_LINE>fromScale... | ) - 2).trim(); |
1,499,656 | public final void scheduledTrigger() {<NEW_LINE>AgentInstanceContext agentInstanceContext = observerEventEvaluator.getContext().getAgentInstanceContext();<NEW_LINE>agentInstanceContext.getInstrumentationProvider().qPatternObserverScheduledEval();<NEW_LINE>agentInstanceContext.getAuditProvider().scheduleFire(agentInstan... | getClasspathImportServiceRuntime().getTimeAbacus()); |
1,630,513 | public boolean amiiboFastWrite(int addr, int bank, byte[] data) {<NEW_LINE>if (null == data) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>return internalFastWrite((startAddr, bank1, data1) -> {<NEW_LINE>byte[] req = new byte[(data1.length + 4)];<NEW_LINE>req[0] = (byte) NfcByte.N2_FAST_WRITE;<NEW_LINE>req[1] = (byte) (... | (byte) (bank1 & 0xFF); |
150,979 | private void rewriteAgentConfigTablePart1() throws Exception {<NEW_LINE>dropTableIfExists("agent_config_temp");<NEW_LINE>session.updateSchemaWithRetry("create table if not exists agent_config_temp" + " (agent_rollup_id varchar, config blob, config_update boolean," + " config_update_token uuid, primary key (agent_rollup... | , row.getUUID(3)); |
1,359,264 | public void read(org.apache.thrift.protocol.TProtocol prot, FetchRuleKeyLogsRequest struct) throws org.apache.thrift.TException {<NEW_LINE>org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;<NEW_LINE>java.util.BitSet incoming = iprot.readBitSet(3);<NEW_LINE>if (incoming.g... | .String>(_list29.size); |
1,799,704 | public K lastKey() {<NEW_LINE>atomicOperationsManager.acquireReadLock(this);<NEW_LINE>try {<NEW_LINE>acquireSharedLock();<NEW_LINE>try {<NEW_LINE>final <MASK><NEW_LINE>final BucketSearchResult searchResult = lastItem(atomicOperation);<NEW_LINE>if (searchResult == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>final ... | OAtomicOperation atomicOperation = atomicOperationsManager.getCurrentOperation(); |
95,522 | private void initWindow() {<NEW_LINE>logger.info("Initializing display (if last line in log then likely the game crashed from an issue with your " + "video card)");<NEW_LINE>// set opengl core profile to 3.3<NEW_LINE>GLFW.glfwWindowHint(GLFW.GLFW_CONTEXT_VERSION_MAJOR, 3);<NEW_LINE>GLFW.glfwWindowHint(GLFW.GLFW_CONTEXT... | = getClass().getClassLoader(); |
1,639,401 | private void addStaticInitializer(ClassWriter cw) {<NEW_LINE>MethodVisitor mv = cw.visitMethod(ACC_STATIC, "<clinit>", "()V", null, null);<NEW_LINE>mv.visitCode();<NEW_LINE>if (pluginId != null) {<NEW_LINE>mv.visitLdcInsn(pluginId);<NEW_LINE>mv.visitMethodInsn(INVOKESTATIC, "org/glowroot/agent/plugin/api/Agent", "getCo... | PUTSTATIC, adviceInternalName, "configService", "Lorg/glowroot/agent/plugin/api/config/ConfigService;"); |
671,621 | protected ActionResult<List<Wo>> execute(EffectivePerson effectivePerson, String sectionName, String subjectType) throws Exception {<NEW_LINE>try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {<NEW_LINE>ActionResult<List<Wo>> result = new ActionResult<>();<NEW_LINE>EntityManager em = ... | (BBSSubjectInfo_.sectionName), sectionName); |
124,868 | protected <RESULT extends ClickLog> RESULT createEntity(Map<String, Object> source, Class<? extends RESULT> entityType) {<NEW_LINE>try {<NEW_LINE>final RESULT result = entityType.newInstance();<NEW_LINE>result.setUrlId(DfTypeUtil.toString(source.get("urlId")));<NEW_LINE>result.setDocId(DfTypeUtil.toString(source.get("d... | throw new IllegalBehaviorStateException(msg, e); |
1,623,711 | private boolean rebalanceByMovingLeadershipIn(Broker broker, ClusterModel clusterModel, Set<Goal> optimizedGoals, OptimizationOptions optimizationOptions) {<NEW_LINE>long moveStartTimeMs = System.currentTimeMillis();<NEW_LINE>if (!clusterModel.deadBrokers().isEmpty() || optimizationOptions.excludedBrokersForLeadership(... | candidateBrokers = Collections.singleton(broker); |
888,677 | private String generateExtractRvalue(TypeData data, Messager messager, String member) {<NEW_LINE><MASK><NEW_LINE>if (valueExtractFormatter.isEmpty()) {<NEW_LINE>if (data.isInterface()) {<NEW_LINE>Console.error(messager, "Interface %s cannot be parsed without a valueExtractFormatter " + "on either the interface's JsonTy... | CodeFormatter valueExtractFormatter = data.getValueExtractFormatter(); |
1,690,470 | public static void horizontal(Kernel1D_S32 kernel, GrayS16 src, GrayI16 dst) {<NEW_LINE>final short[] dataSrc = src.data;<NEW_LINE>final <MASK><NEW_LINE>final int[] dataKer = kernel.data;<NEW_LINE>final int offset = kernel.getOffset();<NEW_LINE>final int kernelWidth = kernel.getWidth();<NEW_LINE>final int width = src.g... | short[] dataDst = dst.data; |
180,456 | public TemplateActiveVersionRequest unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>TemplateActiveVersionRequest templateActiveVersionRequest = new TemplateActiveVersionRequest();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentPar... | class).unmarshall(context)); |
351,346 | private void checkSyncUpstreamsState(LoadBalancerRequestId loadBalancerRequestId, String singularityRequestId) {<NEW_LINE>Retryer<SingularityLoadBalancerUpdate> syncingRetryer = RetryerBuilder.<SingularityLoadBalancerUpdate>newBuilder().retryIfException().withWaitStrategy(WaitStrategies.fixedWait(1, TimeUnit.SECONDS)).... | error("Could not check sync upstream state for singularity request {}. ", singularityRequestId, e); |
969,008 | public static IStatus waitForFolderAccess(String dir, long timeToWait) {<NEW_LINE>int retries = (int) (timeToWait / 500L) + 1;<NEW_LINE>Throwable lastException = null;<NEW_LINE>boolean isLocked = true;<NEW_LINE>// $NON-NLS-1$<NEW_LINE>File tempFile = new File(dir, ".tmp");<NEW_LINE>while (isLocked) {<NEW_LINE>try {<NEW... | isLocked = !tempFile.createNewFile(); |
873,591 | private static DataArrays trimDataArrays(final DataArrays da, final long thetaLong, final int numValues) {<NEW_LINE>final <MASK><NEW_LINE>final double[] valuesArrIn = da.valuesArr;<NEW_LINE>final int count = count(hashArrIn, thetaLong);<NEW_LINE>final long[] hashArrOut = new long[count];<NEW_LINE>final double[] valuesA... | long[] hashArrIn = da.hashArr; |
782,193 | /*<NEW_LINE>@Override<NEW_LINE>public void onMapEvent(Event event, MapPosition position) {<NEW_LINE>// place.viewport = GmsMapsTypeHelper.toLatLngBounds(mapView.map().viewport().getBBox(null, 0));<NEW_LINE>// resultIntent.putExtra(LocationConstants.EXTRA_FINAL_BOUNDS, place.viewport);<NEW_LINE>// p... | (address.getAddressLine(i)); |
1,500,141 | private void doTokenize() throws AuraValidationException {<NEW_LINE>if (!StringUtils.isBlank(text)) {<NEW_LINE>int lastMatch = 0;<NEW_LINE>Matcher <MASK><NEW_LINE>while (matcher.find()) {<NEW_LINE>int start = matcher.start();<NEW_LINE>int end = matcher.end();<NEW_LINE>// All text before the currently found expression<N... | matcher = EXPRESSION_PATTERN.matcher(text); |
1,590,803 | public <B, R> Free<F, R> zip(Functor<F> f, Free<F, B> b, BiFunction<? super T, ? super B, ? extends R> zipper) {<NEW_LINE>Either<Higher<F, Free<F, T>>, T> first = resume(f);<NEW_LINE>Either<Higher<F, Free<F, B>>, B> <MASK><NEW_LINE>if (first.isLeft() && second.isLeft()) {<NEW_LINE>return suspend(f.map_(first.leftOrElse... | second = b.resume(f); |
1,211,996 | private void updateOrganizations(OpenIdAlfioUser alfioUser) {<NEW_LINE>int userId = userRepository.findIdByUserName(alfioUser.getEmail()).orElseThrow();<NEW_LINE>var databaseOrganizationIds = organizationRepository.findAllForUser(alfioUser.getEmail()).stream().map(Organization::getId).collect(Collectors.toSet());<NEW_L... | userOrganizationRepository.removeOrganizationUserLinks(userId, organizationsToUnlink); |
1,829,852 | public double convexityFromYield(ResolvedFixedCouponBond bond, LocalDate settlementDate, double yield) {<NEW_LINE>ImmutableList<FixedCouponBondPaymentPeriod> payments = bond.getPeriodicPayments();<NEW_LINE>int nCoupon = payments.size() - couponIndex(payments, settlementDate);<NEW_LINE>FixedCouponBondYieldConvention yie... | 1d + factorToNextCoupon * yield / couponPerYear); |
230,016 | public IBaseParameters diff(@Description(value = "The resource ID and version to diff from", example = "Patient/example/version/1") @OperationParam(name = ProviderConstants.DIFF_FROM_PARAMETER, typeName = "id", min = 1, max = 1) IIdType theFromVersion, @Description(value = "The resource ID and version to diff to", exam... | .code(1129) + msg); |
1,643,013 | public DescribeHostsResult unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>DescribeHostsResult describeHostsResult = new DescribeHostsResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (context.isStartOfDocument())<NEW_LINE... | new ArrayList<Host>()); |
168,215 | private void drawSettingsArrow(MatrixStack matrixStack, int x2, int x3, int y1, int y2, boolean hSettings) {<NEW_LINE>float xa1 = x3 + 1;<NEW_LINE>float xa2 = (x3 + x2) / 2.0F;<NEW_LINE>float xa3 = x2 - 1;<NEW_LINE>float ya1;<NEW_LINE>float ya2;<NEW_LINE>Matrix4f matrix = matrixStack.peek().getPositionMatrix();<NEW_LIN... | ya2, 0).next(); |
1,591,471 | private static int readSimpleHuffmanCode(int alphabetSizeMax, int alphabetSizeLimit, int[] tableGroup, int tableIdx, State s) {<NEW_LINE>// TODO(eustas): Avoid allocation?<NEW_LINE>int[] codeLengths = new int[alphabetSizeLimit];<NEW_LINE>int[] symbols = new int[4];<NEW_LINE>int maxBits = 1 + log2floor(alphabetSizeMax -... | BitReader.readFewBits(s, 1); |
1,023,336 | private void generateSplitPoints(final SplitStoreFromRDDOfElements operation, final Context context, final AccumuloStore store) throws OperationException {<NEW_LINE>final byte[] schemaAsJson = store<MASK><NEW_LINE>final String keyConverterClassName = store.getKeyPackage().getKeyConverter().getClass().getName();<NEW_LIN... | .getSchema().toCompactJson(); |
1,679,836 | protected Mono<HttpClientResponse> doRequest(final ServerWebExchange exchange, final String httpMethod, final URI uri, final HttpHeaders httpHeaders, final Flux<DataBuffer> body) {<NEW_LINE>return Mono.from(httpClient.headers(headers -> httpHeaders.forEach(headers::add)).request(HttpMethod.valueOf(httpMethod)).uri(uri.... | , entry.getValue())); |
503,862 | // TODO(olsona): can we guarantee that <VCARDPROPERTY>.getPref() will always return a value?<NEW_LINE>@VisibleForTesting<NEW_LINE>static Person convert(VCard vCard) {<NEW_LINE>Person person = new Person();<NEW_LINE>Preconditions.checkArgument(atLeastOneNamePresent(vCard), "At least one name must be present");<NEW_LINE>... | (Collectors.toList())); |
38,364 | synchronized public void writeMetadata(@NonNull BackupFiles.BackupFile backupFile) throws IOException {<NEW_LINE>if (metadata == null) {<NEW_LINE>throw new RuntimeException("Metadata not set for path " + backupFile.getBackupPath());<NEW_LINE>}<NEW_LINE>Path metadataFile = backupFile.getMetadataFile();<NEW_LINE>try (Out... | put("instruction_set", metadata.instructionSet); |
851,182 | public void run(Arguments arguments, Instrumentation instrumentation, Collection<AutoCloseable> objectsToCloseOnShutdown) {<NEW_LINE>if (arguments.isNoop()) {<NEW_LINE>LOGGER.info("Agent noop is true, do not run anything");<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Reporter reporter = arguments.getReporter();<NEW_LINE>Strin... | reporter, arguments, processUuid, appId); |
921,531 | public static void takeSignature(IMethodResult result, String imgFormat, Bitmap bitmap, String filePath, int penColor, int bgColor) {<NEW_LINE>Logger.D(TAG, "takeSignature+");<NEW_LINE>try {<NEW_LINE>String outputFilePath;<NEW_LINE>if (imgFormat.equals("jpg")) {<NEW_LINE>outputFilePath = saveJpg(bitmap, filePath);<NEW_... | results.put("status", "error"); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.