idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
965,288 | public CallAdapter<?, ?> nextCallAdapter(@Nullable CallAdapter.Factory skipPast, Type returnType, Annotation[] annotations) {<NEW_LINE>Objects.requireNonNull(returnType, "returnType == null");<NEW_LINE>Objects.requireNonNull(annotations, "annotations == null");<NEW_LINE>int start = callAdapterFactories.indexOf(skipPast... | get(returnType, annotations, this); |
25,184 | private TaskSnapshotRequest buildTaskSnapshotRequest() {<NEW_LINE>Map<String, JobWrapper> jobWrapperMap = jobmanager.getJobs();<NEW_LINE>List<TaskSnapshotMessage> taskSnapshotMessageList = new ArrayList<>();<NEW_LINE>TaskSnapshotRequest taskSnapshotRequest = new TaskSnapshotRequest();<NEW_LINE>Date date = new Date(Syst... | setAgentIp(AgentUtils.fetchLocalIp()); |
423,634 | private static SchemaKTable<?> buildTable(final PlanBuildContext buildContext, final DataSource dataSource, final Stacker contextStacker) {<NEW_LINE>final KeyFormat keyFormat = dataSource.getKsqlTopic().getKeyFormat();<NEW_LINE>if (keyFormat.isWindowed()) {<NEW_LINE>throw new IllegalArgumentException("windowed");<NEW_L... | .getValueFormat()), pseudoColumnVersionToUse); |
1,841,497 | private com.alibaba.polardbx.executor.operator.Executor createNonFrameWindowExec(SortWindow overWindow, ExecutionContext context, int index) {<NEW_LINE>Executor input = getInputs().get(0).createExecutor(context, index);<NEW_LINE>MemoryAllocatorCtx memoryAllocator = context<MASK><NEW_LINE>List<DataType> dataTypes = Calc... | .getMemoryPool().getMemoryAllocatorCtx(); |
732,087 | protected void onCreate(Bundle savedInstanceState) {<NEW_LINE>super.onCreate(savedInstanceState);<NEW_LINE>setContentView(R.layout.__picker_activity_photo_pager);<NEW_LINE>int currentItem = getIntent().getIntExtra(EXTRA_CURRENT_ITEM, 0);<NEW_LINE>List<String> paths = getIntent().getStringArrayListExtra(EXTRA_PHOTOS);<N... | findViewById(R.id.toolbar); |
182,832 | ActionResult<Wo> execute(EffectivePerson effectivePerson, JsonElement jsonElement) throws Exception {<NEW_LINE>logger.debug(effectivePerson, "jsonElement:{}.", jsonElement);<NEW_LINE>try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {<NEW_LINE>ActionResult<Wo> result = new ActionResul... | .setLastUpdateTime(new Date()); |
983,824 | private static Object allocateInstanceDynamicHelper(Class<?> type, boolean fillContents, Register threadRegister, OptionValues options, Counters counters, Class<?> nonNullType) {<NEW_LINE>KlassPointer hub = ClassGetHubNode.readClass(nonNullType);<NEW_LINE>if (probability(FAST_PATH_PROBABILITY, !hub.isNull())) {<NEW_LIN... | false, "", options, counters); |
547,016 | private // but it just naturally came into my mind that I used a queue<NEW_LINE>List<List<Integer>> buildAllComb(int[] nums) {<NEW_LINE>List<List<Integer>> result = new ArrayList();<NEW_LINE>if (nums == null || nums.length == 0) {<NEW_LINE>return result;<NEW_LINE>}<NEW_LINE>List<Integer> list = new ArrayList<Integer>()... | >> q = new LinkedList(); |
1,320,028 | private void bail(Byte2ObjectMap<ItemStack> targetContents, Byte2ObjectMap<ItemStack> remainingCraftingGridContents, String format, Object... args) {<NEW_LINE>Mekanism.logger.warn(format, args);<NEW_LINE>SelectedWindowData windowData = craftingWindow.getWindowData();<NEW_LINE>for (ItemStack stack : targetContents.value... | ItemStack stack = entry.getValue(); |
531,216 | public Request<CreateAppRequest> marshall(CreateAppRequest createAppRequest) {<NEW_LINE>if (createAppRequest == null) {<NEW_LINE>throw new AmazonClientException("Invalid argument passed to marshall(CreateAppRequest)");<NEW_LINE>}<NEW_LINE>Request<CreateAppRequest> request = new DefaultRequest<CreateAppRequest>(createAp... | .toString(content.length)); |
160,473 | protected void installDefaults(AbstractButton b) {<NEW_LINE>super.installDefaults(b);<NEW_LINE>if (!defaults_initialized) {<NEW_LINE>String prefix = getPropertyPrefix();<NEW_LINE>minimumWidth = UIManager.getInt(prefix + "minimumWidth");<NEW_LINE>iconTextGap = FlatUIUtils.<MASK><NEW_LINE>background = UIManager.getColor(... | getUIInt(prefix + "iconTextGap", 4); |
1,155,558 | public void marshall(CreateCloudFormationChangeSetRequest createCloudFormationChangeSetRequest, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (createCloudFormationChangeSetRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>prot... | createCloudFormationChangeSetRequest.getSemanticVersion(), SEMANTICVERSION_BINDING); |
68,749 | public com.amazonaws.services.acmpca.model.MalformedCSRException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.acmpca.model.MalformedCSRException malformedCSRException = new com.amazonaws.services.acmpca.model.MalformedCSRException(null);<NEW_LINE><MASK><NEW_L... | int originalDepth = context.getCurrentDepth(); |
1,814,591 | public static void main(String[] args) {<NEW_LINE>final String USAGE = "To run this example, supply:\n" + "* a filter name\n" + "* filter pattern\n" + "* log group name\n" + "* lambda function arn\n\n" + "Ex: PutSubscriptionFilter <filter-name> \\\n" + " <filter pattern> \\\n" + " ... | (log_group).withDestinationArn(function_arn); |
963,577 | public static void main(String[] args) {<NEW_LINE>Cart cart = new Cart();<NEW_LINE>Cart cart2 = new Cart();<NEW_LINE>Items item1 = new Items(cart);<NEW_LINE>Items item2 = new Items(cart2);<NEW_LINE>Set<Items> itemsSet = new HashSet<Items>();<NEW_LINE>itemsSet.add(item1);<NEW_LINE>itemsSet.add(item2);<NEW_LINE>cart.setI... | System.out.println("Closing SessionFactory"); |
1,835,508 | public int doRead(byte[] b, int off, int len) throws IOException {<NEW_LINE>if (len == 0) {<NEW_LINE>return 0;<NEW_LINE>}<NEW_LINE>int cappedLen = cap(len);<NEW_LINE>if (cappedLen <= 0) {<NEW_LINE>return -1;<NEW_LINE>}<NEW_LINE>RandomAccessFile file = this.file;<NEW_LINE>try {<NEW_LINE>if (file == null) {<NEW_LINE>file... | this.offset + this.position); |
979,756 | private PComplex rect(double r, double phi) {<NEW_LINE>// deal with special values<NEW_LINE>if (!Double.isFinite(r) || !Double.isFinite(phi)) {<NEW_LINE>// need to raise an exception if r is a nonzero number and phi is infinite<NEW_LINE>if (r != 0.0 && !Double.isNaN(r) && Double.isInfinite(phi)) {<NEW_LINE>throw raise(... | createComplex(-real, -imag); |
1,792,021 | final CreateWorldTemplateResult executeCreateWorldTemplate(CreateWorldTemplateRequest createWorldTemplateRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createWorldTemplateRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | endClientExecution(awsRequestMetrics, request, response); |
1,192,785 | // DO NOT MODIFY THIS CODE, GENERATED AUTOMATICALLY<NEW_LINE>public static java.lang.String version(com.sun.jdi.VirtualMachine a) throws org.netbeans.modules.debugger.jpda.jdi.InternalExceptionWrapper, org.netbeans.modules.debugger.jpda.jdi.VMDisconnectedExceptionWrapper {<NEW_LINE>if (org.netbeans.modules.debugger.jpd... | logCallEnd("com.sun.jdi.VirtualMachine", "version", retValue); |
496,617 | public void marshall(KantarWatermarkSettings kantarWatermarkSettings, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (kantarWatermarkSettings == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(kantarWatermark... | kantarWatermarkSettings.getKantarServerUrl(), KANTARSERVERURL_BINDING); |
1,709,788 | private void computeEHat() {<NEW_LINE>Ehat = empty2D();<NEW_LINE>for (int m = 0; m < data.length; m++) {<NEW_LINE>int[][][] docData = data[m];<NEW_LINE>int[] docLabels = labels[m];<NEW_LINE>int[] windowLabels = new int[window];<NEW_LINE>Arrays.fill(windowLabels, classIndex.indexOf(backgroundSymbol));<NEW_LINE>if (docLa... | = new int[j + 1]; |
1,253,136 | public void doPost(String url, String requestBody) throws IOException {<NEW_LINE>Log.i(LoggingService.LOG_TAG, "HTTP request. body: " + requestBody);<NEW_LINE>HttpURLConnection conn = (HttpURLConnection) new URL(url).openConnection();<NEW_LINE>conn.setDoOutput(true);<NEW_LINE>conn.setUseCaches(false);<NEW_LINE>conn.set... | LoggingService.LOG_TAG, "HTTP response. body: " + responseBody); |
1,803,380 | final RollbackStackResult executeRollbackStack(RollbackStackRequest rollbackStackRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(rollbackStackRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE><MASK><NEW_LINE>Request<RollbackStackReq... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
1,836,873 | public List<String> subdomainVisits(String[] cpdomains) {<NEW_LINE>Map<String, Integer> map = new HashMap<>();<NEW_LINE>for (String each : cpdomains) {<NEW_LINE>String[] pair = each.split(" ");<NEW_LINE>String[] subDomains = pair[1].split("\\.");<NEW_LINE>StringBuilder sb = new StringBuilder();<NEW_LINE>for (int i = su... | (key) + " " + key); |
805,305 | public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {<NEW_LINE>super.onViewCreated(view, savedInstanceState);<NEW_LINE>edtUsername = view.findViewById(R.id.edtUsername);<NEW_LINE>spinnerDomain = view.findViewById(R.id.spinnerDomain);<NEW_LINE>spinnerDomain.setOnItemSelectedListener(new AdapterView... | htmlData, "text/html", "UTF-8", null); |
431,012 | public void announce(DruidNode service) {<NEW_LINE>final String serviceName = CuratorServiceUtils.makeCanonicalServiceName(service.getServiceName());<NEW_LINE>final ServiceInstance<Void> instance;<NEW_LINE>synchronized (monitor) {<NEW_LINE>if (instanceMap.containsKey(serviceName)) {<NEW_LINE>log.warn("Ignoring request ... | instanceMap.put(serviceName, instance); |
227,321 | public static void main(String[] args) {<NEW_LINE>TableServiceClient tableServiceClient = new TableServiceClientBuilder().<MASK><NEW_LINE>// We'll first create a table. This operation produces a TableClient that can be used to perform operations<NEW_LINE>// directly on the table.<NEW_LINE>String tableName = "myTable";<... | connectionString("DefaultEndpointsProtocol=https;AccountName=dummyAccount;AccountKey=xyzDummy;EndpointSuffix=core.windows.net").buildClient(); |
1,278,655 | public String toTarget(Translator translator, Symbol table) {<NEW_LINE>HtmlWriter writer = new HtmlWriter();<NEW_LINE>writer.startTag("table");<NEW_LINE>writeClassAttributeIfDefinedForSymbol(table, writer);<NEW_LINE>int longestRow = longestRow(table);<NEW_LINE>int rowCount = 0;<NEW_LINE>for (Symbol row : table.getChild... | body = translateCellBody(translator, cell); |
946,361 | public void onItemSelected(AdapterView<?> parent, View view, int pos, long id) {<NEW_LINE>String selected = parent.getItemAtPosition(pos).toString();<NEW_LINE>if (parent == baudRateSpinner) {<NEW_LINE>setBaudRate(Integer.parseInt(selected));<NEW_LINE>} else if (parent == modelSpinner) {<NEW_LINE>try {<NEW_LINE>masterLi... | ().toUpperCase())); |
1,803,695 | public Workspace importDump(String json) throws Exception {<NEW_LINE>PostmanDump pmDump = readJson(json, PostmanDump.class);<NEW_LINE>// validation<NEW_LINE>if (pmDump.getCollections() == null && pmDump.getEnvironments() == null && pmDump.getGlobals() == null) {<NEW_LINE>throw new IllegalArgumentException("Empty Dump d... | = new LinkedList<Collection>(); |
1,737,384 | private void showUploadConfirmationDialog(@NonNull FragmentActivity activity, @NonNull String actionButton, @Nullable SelectionModeListener listener) {<NEW_LINE>long[] size = new long[1];<NEW_LINE>List<SelectableItem<GpxInfo>> items = new ArrayList<>();<NEW_LINE>for (GpxInfo gpxInfo : selectedItems) {<NEW_LINE>Selectab... | (R.string.shared_string_continue)); |
1,353,296 | protected void internalTransform(Body b, String phaseName, Map<String, String> options) {<NEW_LINE>BranchedRefVarsAnalysis analysis = new BranchedRefVarsAnalysis(ExceptionalUnitGraphFactory.createExceptionalUnitGraph(b));<NEW_LINE>for (Unit s : b.getUnits()) {<NEW_LINE>FlowSet<RefIntPair> beforeSet = analysis.getFlowBe... | , "Nullness: Null", NullCheckTag.NAME)); |
981,970 | public static void registerLoggers() {<NEW_LINE>registerLogger("tnt", Logger.stardardLogger("tnt", "brief", new String[] { "brief", "full" }, true));<NEW_LINE>registerLogger("projectiles", Logger.stardardLogger("projectiles", "brief", new String[] { "brief", "full" }));<NEW_LINE>registerLogger("fallingBlocks", Logger.s... | String[]::new))); |
1,733,496 | final ImportDocumentationPartsResult executeImportDocumentationParts(ImportDocumentationPartsRequest importDocumentationPartsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(importDocumentationPartsRequest);<NEW_LINE><MASK><NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NE... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
1,583,653 | private static ArrayNode createJSONList(final List list, final List<String> propertyKeys, final boolean showTypes) {<NEW_LINE>final <MASK><NEW_LINE>for (Object item : list) {<NEW_LINE>if (item instanceof Element) {<NEW_LINE>jsonList.add(objectNodeFromElement((Element) item, propertyKeys, showTypes ? GraphSONMode.EXTEND... | ArrayNode jsonList = jsonNodeFactory.arrayNode(); |
925,547 | private static Path createTempFile(String libraryName) throws IOException {<NEW_LINE>int <MASK><NEW_LINE>String name = (sep >= 0) ? libraryName.substring(sep + 1) : libraryName;<NEW_LINE>int dot = name.lastIndexOf('.');<NEW_LINE>String prefix = ((dot >= 0) ? name.substring(0, dot) : name) + '-';<NEW_LINE>String suffix ... | sep = libraryName.lastIndexOf('/'); |
134,835 | /*<NEW_LINE>* (non-Javadoc)<NEW_LINE>*<NEW_LINE>* @see javax.resource.spi.ResourceAdapter#endpointActivation(javax.resource.spi.endpoint.MessageEndpointFactory, javax.resource.spi.ActivationSpec)<NEW_LINE>*/<NEW_LINE>public void endpointActivation(MessageEndpointFactory msgEndpointFac, ActivationSpec activationSpec) th... | ).getName() + "] and is not supported by this resource adapter."); |
1,502,006 | public void registerSchemas(SchemaConfig schemaConfig, SchemaPlus parent) throws IOException {<NEW_LINE>try {<NEW_LINE>rootSchema = new PhoenixSchema(schemaConfig, plugin, Collections.emptyList(), plugin.getName());<NEW_LINE>if (isDrillImpersonationEnabled) {<NEW_LINE>ugi.doAs((PrivilegedExceptionAction<Void>) () -> {<... | add(getName(), rootSchema); |
691,311 | public Description matchMethod(MethodTree methodTree, VisitorState state) {<NEW_LINE>MethodSymbol <MASK><NEW_LINE>if (isSynchronized(methodSymbol)) {<NEW_LINE>return NO_MATCH;<NEW_LINE>}<NEW_LINE>for (MethodSymbol s : ASTHelpers.findSuperMethods(methodSymbol, state.getTypes())) {<NEW_LINE>if (isSynchronized(s)) {<NEW_L... | methodSymbol = ASTHelpers.getSymbol(methodTree); |
1,253,548 | private void terminateUnderlyingTransaction(SipServletRequest invite) {<NEW_LINE>if (c_logger.isTraceEntryExitEnabled()) {<NEW_LINE>c_logger.traceEntry(this, "terminateUnderlyingTransaction", invite);<NEW_LINE>}<NEW_LINE>if (!_tuWrapper.hasOngoingTransactions()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>_underlyingTransac... | toString() + "]: The transaction was already terminated. Possibly due to a" + "downstream forking creating a derived session"); |
520,793 | final DescribeTagsResult executeDescribeTags(DescribeTagsRequest describeTagsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeTagsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExec... | endClientExecution(awsRequestMetrics, request, response); |
462,099 | public void updateFilesCompletion() {<NEW_LINE>int filesCompleted = m_filesCompleted.incrementAndGet();<NEW_LINE>m_progressBar.setProgress(filesCompleted);<NEW_LINE>if (filesCompleted == m_filesCount) {<NEW_LINE>m_progressBarLayout.setVisibility(View.GONE);<NEW_LINE>Set<String> cardElements = CardRetriever.getInstance(... | 10, 0, 10, 0); |
893,030 | public ResultStatus updateById(LogicalClusterDO logicalClusterDO) {<NEW_LINE>if (ValidateUtils.isNull(logicalClusterDO) || ValidateUtils.isNull(logicalClusterDO.getId())) {<NEW_LINE>return ResultStatus.PARAM_ILLEGAL;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>LogicalClusterDO oldLogicalClusterDO = logicalClusterDao.<MASK><NEW_... | getById(logicalClusterDO.getId()); |
232,705 | public com.amazonaws.services.simplesystemsmanagement.model.ParameterAlreadyExistsException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.simplesystemsmanagement.model.ParameterAlreadyExistsException parameterAlreadyExistsException = new com.amazonaws.services... | JsonToken token = context.getCurrentToken(); |
178,643 | public void jpa_jpa20_cache_testCache014() throws Exception {<NEW_LINE>int testEntryId = 14000;<NEW_LINE>Cache l2cache = em_CACHE_JEE_DCTRUE_SCM_ENASEL.getEntityManagerFactory().getCache();<NEW_LINE>// 1. Test when shared-cache-mode is ENABLE_SELECTIVE, only entries marked Cachable(true) are in the L2 cache<NEW_LINE>Ca... | (CacheEntityCacheableNot.class, testEntryId)); |
414,585 | public void unbindEIP() throws Exception {<NEW_LINE><MASK><NEW_LINE>String myPublicIP = null;<NEW_LINE>if (myInfo != null && myInfo.getDataCenterInfo().getName() == Name.Amazon) {<NEW_LINE>myPublicIP = ((AmazonInfo) myInfo.getDataCenterInfo()).get(MetaDataKey.publicIpv4);<NEW_LINE>if (myPublicIP == null) {<NEW_LINE>log... | InstanceInfo myInfo = applicationInfoManager.getInfo(); |
360,871 | protected DatabaseSnapshot createReferenceSnapshot(CommandScope commandScope) throws DatabaseException, InvalidExampleException {<NEW_LINE>CatalogAndSchema[] schemas;<NEW_LINE>CompareControl compareControl = commandScope.getArgumentValue(COMPARE_CONTROL_ARG);<NEW_LINE>Database targetDatabase = commandScope.getArgumentV... | snapshotTypes = commandScope.getArgumentValue(SNAPSHOT_TYPES_ARG); |
282,896 | public boolean updateProvider(AuthenticatedUser authenticatedUser, String authenticationProviderId, String persistentIdInProvider) {<NEW_LINE>try {<NEW_LINE>AuthenticatedUserLookup aul = em.createNamedQuery("AuthenticatedUserLookup.findByAuthUser", AuthenticatedUserLookup.class).setParameter(<MASK><NEW_LINE>aul.setAuth... | "authUser", authenticatedUser).getSingleResult(); |
66,051 | public void onMatch(RelOptRuleCall call) {<NEW_LINE>final Project project = call.rel(0);<NEW_LINE>final DruidQuery query = call.rel(1);<NEW_LINE>final RelOptCluster cluster = project.getCluster();<NEW_LINE>final RexBuilder rexBuilder = cluster.getRexBuilder();<NEW_LINE>if (!DruidQuery.isValidSignature(query.signature()... | name, e.getType()); |
1,297,693 | public final void restMethodDefinitionArgument() throws RecognitionException, TokenStreamException {<NEW_LINE>returnAST = null;<NEW_LINE>ASTPair currentAST = new ASTPair();<NEW_LINE>AST restMethodDefinitionArgument_AST = null;<NEW_LINE>AST tmp413_AST = null;<NEW_LINE>tmp413_AST = astFactory.create(LT(1));<NEW_LINE>astF... | (1), getFilename()); |
589,824 | // -------------------------------------------------------- Adapter Methods<NEW_LINE>@Override<NEW_LINE>public void service(org.glassfish.grizzly.http.server.Request req, org.glassfish.grizzly.http.server.Response res) throws Exception {<NEW_LINE>res.getResponse().setAllowCustomReasonPhrase(Constants.USE_CUSTOM_STATUS_... | (connector.getURIEncoding())); |
779,483 | final DescribeInputSecurityGroupResult executeDescribeInputSecurityGroup(DescribeInputSecurityGroupRequest describeInputSecurityGroupRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeInputSecurityGroupRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRe... | addHandlerContext(HandlerContextKey.SERVICE_ID, "MediaLive"); |
1,456,712 | protected DatabaseObject snapshotObject(DatabaseObject example, DatabaseSnapshot snapshot) throws DatabaseException {<NEW_LINE>if (BooleanUtil.isTrue(((Column) example).getComputed()) || BooleanUtil.isTrue(((Column) example).getDescending())) {<NEW_LINE>return example;<NEW_LINE>}<NEW_LINE>Database database = snapshot.g... | Schema schema = relation.getSchema(); |
896,058 | private void spawnNewTracksForNewKeyFrame(List<Track> visibleTracks) {<NEW_LINE>// System.out.println("addNewTracks() current frame="+frameCurrent.id);<NEW_LINE>long frameID = tracker.getFrameID();<NEW_LINE>int totalRejected = 0;<NEW_LINE>tracker.spawnTracks();<NEW_LINE>List<PointTrack> spawned = tracker.getNewTracks(n... | ), pixelTo3D.getW()); |
700,858 | protected boolean createKeys(List<Content> list) {<NEW_LINE>if (accounts == null || accounts.isEmpty()) {<NEW_LINE>return true;<NEW_LINE>}<NEW_LINE>CommunicationsManager communicationManager;<NEW_LINE>try {<NEW_LINE>communicationManager = Case.getCurrentCaseThrows().getSleuthkitCase().getCommunicationsManager();<NEW_LI... | Level.WARNING, "Failed to get communications manager from case.", ex); |
1,215,018 | private static String collectFailureReasons(MatchOperation root) {<NEW_LINE>StringBuilder sb = new StringBuilder();<NEW_LINE>sb.append("match failed: ").append(root.type).append('\n');<NEW_LINE>Collections.reverse(root.failures);<NEW_LINE>Iterator<MatchOperation> iterator = root.failures.iterator();<NEW_LINE>Set previo... | ()).append('\n'); |
865,610 | public void showComments(final RequestContext context) {<NEW_LINE>final Request request = context.getRequest();<NEW_LINE>final AbstractFreeMarkerRenderer renderer = new SkinRenderer(context, "admin/comments.ftl");<NEW_LINE>final Map<String, Object<MASK><NEW_LINE>final int pageNum = Paginator.getPage(request);<NEW_LINE>... | > dataModel = renderer.getDataModel(); |
1,330,407 | public io.kubernetes.client.proto.V1Autoscaling.HorizontalPodAutoscalerSpec buildPartial() {<NEW_LINE>io.kubernetes.client.proto.V1Autoscaling.HorizontalPodAutoscalerSpec result = new io.kubernetes.client.<MASK><NEW_LINE>int from_bitField0_ = bitField0_;<NEW_LINE>int to_bitField0_ = 0;<NEW_LINE>if (((from_bitField0_ & ... | proto.V1Autoscaling.HorizontalPodAutoscalerSpec(this); |
850,740 | private static void pointAddVar(boolean negate, PointExt p, PointExt q, PointExt r) {<NEW_LINE>int[] a = F.create();<NEW_LINE>int[] b = F.create();<NEW_LINE>int[] c = F.create();<NEW_LINE>int[] d = F.create();<NEW_LINE>int[] e = F.create();<NEW_LINE>int[] f = F.create();<NEW_LINE>int[] g = F.create();<NEW_LINE>int[] h ... | f, g, r.z); |
193,708 | private SortedSet<Violation> processFile(File file) throws CheckstyleException {<NEW_LINE>final SortedSet<Violation> fileMessages = new TreeSet<>();<NEW_LINE>try {<NEW_LINE>final FileText theText = new FileText(file.getAbsoluteFile(), charset);<NEW_LINE>for (final FileSetCheck fsc : fileSetChecks) {<NEW_LINE>fileMessag... | log.debug("IOException occurred.", ioe); |
766,305 | public MetricResult measureUserRecList(Recommender rec, TestUser user, int targetLength, List<Long> recs, Context context) {<NEW_LINE>int tp = 0;<NEW_LINE>LongSet items = goodItems.selectItems(context.universe, rec, user);<NEW_LINE>for (long item : recs) {<NEW_LINE>if (items.contains(item)) {<NEW_LINE>tp += 1;<NEW_LINE... | context.addUser(0, 0); |
837,255 | private Optional<OExecutionPlan> readExecutionPlan(OChannelDataInput network) throws IOException {<NEW_LINE>boolean present = network.readBoolean();<NEW_LINE>if (!present) {<NEW_LINE>return Optional.empty();<NEW_LINE>}<NEW_LINE>OInfoExecutionPlan result = new OInfoExecutionPlan();<NEW_LINE>OResult read = OMessageHelper... | "cost")).intValue()); |
756,148 | public static void reportProgress(@Nullable PlaybackController playbackController, BaseItemDto item, StreamInfo currentStreamInfo, Long position, boolean isPaused) {<NEW_LINE>if (item != null && currentStreamInfo != null) {<NEW_LINE>PlaybackProgressInfo info = new PlaybackProgressInfo();<NEW_LINE>info.setItemId(item.ge... | setAudioStreamIndex(playbackController.getAudioStreamIndex()); |
654,626 | public double adamicAdarSimilarity(@Name("node1") Node node1, @Name("node2") Node node2, @Name(value = "config", defaultValue = "{}") Map<String, Object> config) {<NEW_LINE>// https://en.wikipedia.org/wiki/Adamic/Adar_index<NEW_LINE>if (node1 == null || node2 == null) {<NEW_LINE>throw new RuntimeException("Nodes must n... | configuration.getDirection(Direction.BOTH); |
1,111,010 | private void drawDynamic(final Canvas canvas) {<NEW_LINE>final int viewWidth = getWidth() - getPaddingLeft() - getPaddingRight();<NEW_LINE>final int viewHalfWidth = getPaddingLeft() + viewWidth / 2;<NEW_LINE>final int viewBottom = getHeight();<NEW_LINE>final float density = getResources().getDisplayMetrics().density;<N... | int) (labelVisible * 255)); |
1,570,980 | public Invoice createInvoice(StockMove stockMove, Integer operationSelect, List<Map<String, Object>> stockMoveLineListContext) throws AxelorException {<NEW_LINE>Invoice invoice;<NEW_LINE>Map<Long, BigDecimal> qtyToInvoiceMap = new HashMap<>();<NEW_LINE>if (operationSelect == StockMoveRepository.INVOICE_PARTIALLY) {<NEW... | ("remainingQty").toString()); |
1,547,879 | private void sendFeedback() {<NEW_LINE>final <MASK><NEW_LINE>final Intent feedbackIntent = new Intent(Intent.ACTION_SENDTO);<NEW_LINE>feedbackIntent.setType("message/rfc822");<NEW_LINE>feedbackIntent.setData(Uri.parse("mailto:"));<NEW_LINE>feedbackIntent.putExtra(Intent.EXTRA_EMAIL, new String[] { CommonsApplication.FE... | String technicalInfo = commonsLogSender.getExtraInfo(); |
606,048 | public ViewerAnnotator createAnnotator(@Nonnull T viewer, @Nonnull Side side) {<NEW_LINE>TwosideViewerAnnotatorFactory<T> factory = this;<NEW_LINE>Project project = viewer.getProject();<NEW_LINE>assert project != null;<NEW_LINE>return new ViewerAnnotator() {<NEW_LINE><NEW_LINE>@Nonnull<NEW_LINE>@Override<NEW_LINE>publi... | viewer.getRequest(), side); |
88,525 | private static void configure(String propertiesFile) throws IOException {<NEW_LINE>FileInputStream inputStream = new FileInputStream(propertiesFile);<NEW_LINE>Properties properties = new Properties();<NEW_LINE>try {<NEW_LINE>properties.load(inputStream);<NEW_LINE>} finally {<NEW_LINE>inputStream.close();<NEW_LINE>}<NEW... | properties.getProperty(ConfigKeys.ZOOKEEPER_ENDPOINT_KEY); |
177,724 | private void loadTopRepositories(boolean force) {<NEW_LINE>RepositoryService service = ServiceFactory.get(RepositoryService.class, force, null, null, 5);<NEW_LINE>final Single<Response<MASK><NEW_LINE>Map<String, String> filterData = new HashMap<>();<NEW_LINE>filterData.put("sort", "pushed");<NEW_LINE>filterData.put("af... | <Page<Repository>>> observable; |
840,042 | protected void onCreate(Bundle savedInstanceState) {<NEW_LINE>super.onCreate(savedInstanceState);<NEW_LINE>updateEnabledWidgets();<NEW_LINE>mAudioOutTester = addAudioOutputTester();<NEW_LINE>mStartButton = (Button) findViewById(R.id.button_start_echo);<NEW_LINE>mStopButton = (Button) findViewById(R.id.button_stop_echo)... | findViewById(R.id.text_delay_time); |
386,814 | public void resolveStatements() {<NEW_LINE>super.resolveStatements();<NEW_LINE>if (this.arguments != null || this.receiver != null) {<NEW_LINE>this.scope.problemReporter().annotationMembersCannotHaveParameters(this);<NEW_LINE>}<NEW_LINE>if (this.typeParameters != null) {<NEW_LINE>this.scope.problemReporter().annotation... | this.sourceEnd, this.defaultValue); |
132,497 | public ResultStatus handleOrderDetail(OrderDO orderDO, OrderHandleBaseDTO orderHandleBaseDTO, String userName) {<NEW_LINE>OrderExtensionQuotaDTO extensionDTO = JSONObject.parseObject(orderDO.getExtensions(), OrderExtensionQuotaDTO.class);<NEW_LINE>OrderHandleQuotaDTO handleDTO = JSONObject.parseObject(orderHandleBaseDT... | setTopicName(extensionDTO.getTopicName()); |
471,433 | public static Map<String, QueryParameter> splitQuery(String query) {<NEW_LINE>if (query == null) {<NEW_LINE>return Collections.emptyMap();<NEW_LINE>}<NEW_LINE>Iterable<String> pairs = Splitter.on('&').split(query);<NEW_LINE>ImmutableListMultimap.Builder<String, String> builder = ImmutableListMultimap.builder();<NEW_LIN... | .substring(0, firstEqualsIndex)); |
1,412,320 | private void debugError(DocumentElementEvent e) {<NEW_LINE>StringBuffer sb = new StringBuffer();<NEW_LINE>sb.append("An inconsistency between XML navigator and XML DocumentModel occured when adding a new element in the XML DocumentModel! Please report the problem and add following debug messages to the issue along with... | .getChildren().iterator(); |
463,934 | public CodegenExpression evaluateCodegen(EPTypeClass requiredType, CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) {<NEW_LINE>CodegenMethod methodNode = codegenMethodScope.makeChild(ListParameter.<MASK><NEW_LINE>CodegenBlock block = methodNode.getBlock().de... | EPTYPE, ExprNumberSetList.class, codegenClassScope); |
1,010,815 | public void train(ClassificationDataSet dataSet, boolean parallel) {<NEW_LINE>if (dataSet.getNumNumericalVars() != 0)<NEW_LINE>throw new RuntimeException("ID3 only supports categorical data");<NEW_LINE>predicting = dataSet.getPredicting();<NEW_LINE>attributes = dataSet.getCategories();<NEW_LINE>List<DataPointPair<Integ... | IntSet(dataSet.getNumCategoricalVars()); |
1,288,758 | public void onActivityResult(int requestCode, int resultCode, Intent data) {<NEW_LINE>super.onActivityResult(requestCode, resultCode, data);<NEW_LINE>registerStartEventListener();<NEW_LINE>if (data != null) {<NEW_LINE>if (data.getStringExtra("url") != null)<NEW_LINE>Log.e(getClass().getName(), "data.getStringExtra(\"ur... | + data.getStringExtra("ex")); |
1,790,387 | protected Path[] selectTargets(ExecutionEvent event) {<NEW_LINE>Shell shell = HandlerUtil.getActiveShell(event);<NEW_LINE>FileDialog dialog = new FileDialog(shell, SWT.MULTI);<NEW_LINE>String contentTypeId = event.getParameter(COMMAND_PARAMETER_LINK_FILE_CONTENTTYPE);<NEW_LINE>if (contentTypeId != null) {<NEW_LINE>ICon... | Paths.get(filterPath, fileName); |
144,117 | public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle bundle) {<NEW_LINE>mBinding = DataBindingUtil.inflate(inflater, R.layout.import_keys_list_fragment, container, false);<NEW_LINE>mBinding.setStatus(STATUS_FIRST);<NEW_LINE>View view = mBinding.getRoot();<NEW_LINE>mActivity = getActivity();<NEW... | args.getBoolean(ARG_NON_INTERACTIVE, false); |
866,065 | public byte[] decrypt(final byte[] ciphertext, final byte[] associatedData) throws GeneralSecurityException {<NEW_LINE>int plaintextLength = ciphertext.length - ivSizeInBytes - TAG_SIZE_IN_BYTES;<NEW_LINE>if (plaintextLength < 0) {<NEW_LINE>throw new GeneralSecurityException("ciphertext too short");<NEW_LINE>}<NEW_LINE... | 2, ciphertext, ivSizeInBytes, plaintextLength); |
792,705 | protected void appendComponentSlot(XStringBuilder xsb, JsonStringBuilder jsb, SofaTracerSpan span) {<NEW_LINE>Map<String, String> tagWithStr = span.getTagsWithStr();<NEW_LINE>Map<String, Number> tagWithNum = span.getTagsWithNumber();<NEW_LINE>// protocol<NEW_LINE>xsb.append(tagWithStr.get(CommonSpanTags.PROTOCOL));<NEW... | tagWithNum.get(AttachmentKeyConstants.CLIENT_SERIALIZE_SIZE); |
649,490 | public ResourcePolicy unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ResourcePolicy resourcePolicy = new ResourcePolicy();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = context.getCurrentToken();<... | String currentParentElement = context.getCurrentParentElement(); |
1,148,474 | protected OrderedTensorType lazyGetType() {<NEW_LINE>if (!allInputTypesPresent(2))<NEW_LINE>return null;<NEW_LINE>OrderedTensorType dataType = inputs.get(0)<MASK><NEW_LINE>OrderedTensorType indicesType = inputs.get(1).type().get();<NEW_LINE>axis = (int) attributeMap.get("axis").orElse(DoubleValue.zero).asDouble();<NEW_... | .type().get(); |
433,234 | public static String toCTypeName(ResolvedJavaMethod method, ResolvedJavaType type, Optional<String> useSiteTypedef, boolean isConst, boolean isUnsigned, MetaAccessProvider metaAccess, NativeLibraries nativeLibs) {<NEW_LINE>boolean isNumericInteger = type.getJavaKind().isNumericInteger();<NEW_LINE>UserError.guarantee(is... | .class).isAssignableFrom(type); |
675,916 | protected BluetoothGatt connect(@NonNull final String address) {<NEW_LINE>if (!mBluetoothAdapter.isEnabled())<NEW_LINE>return null;<NEW_LINE>mConnectionState = STATE_CONNECTING;<NEW_LINE>logi("Connecting to the device...");<NEW_LINE>final BluetoothDevice <MASK><NEW_LINE>BluetoothGatt gatt;<NEW_LINE>if (Build.VERSION.SD... | device = mBluetoothAdapter.getRemoteDevice(address); |
1,590,338 | public void marshall(ApplicationDetail applicationDetail, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (applicationDetail == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(applicationDetail.getApplicationA... | applicationDetail.getApplicationStatus(), APPLICATIONSTATUS_BINDING); |
751,373 | private void loadChineseGenderNumberAnimacy(String file) {<NEW_LINE>String[] split = new String[8];<NEW_LINE>for (String line : IOUtils.readLines(file)) {<NEW_LINE>// ignore first row<NEW_LINE>if (line.startsWith("#WORD"))<NEW_LINE>continue;<NEW_LINE>StringUtils.splitOnChar(split, line, '\t');<NEW_LINE>String word = sp... | .parseInt(split[5]); |
1,259,500 | public void mouseDragged(MouseEvent evt) {<NEW_LINE>Point curr = evt.getPoint();<NEW_LINE>if (isDragEnabled()) {<NEW_LINE>// log.fine("testing drag enabled: " + curr + " " + start);<NEW_LINE>// log.fine("distance = " + curr.distance(start));<NEW_LINE>if (curr.distance(start) > 5) {<NEW_LINE>JXImageView.this.log.fine("s... | = curr.y - prev.y; |
512,935 | private MethodHandle generateInput(Type keyType, Type valueType, FunctionDependencies functionDependencies) throws ReflectiveOperationException {<NEW_LINE>MethodHandle input = lookup().findStatic(AbstractMinMaxBy.class, "input", methodType(void.class, MethodHandle.class, MethodHandle.class, MethodHandle.class, Nullable... | AccumulatorState> valueState = getStateClass(valueType); |
251,714 | public SessionManagerOutputUrl unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>SessionManagerOutputUrl sessionManagerOutputUrl = new SessionManagerOutputUrl();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken... | String currentParentElement = context.getCurrentParentElement(); |
433,339 | private I_M_MovementLine newMovementLine(final ProductId productId) {<NEW_LINE>final I_M_Movement movement = getOrCreateMovementHeader();<NEW_LINE>I_M_MovementLine movementLine = InterfaceWrapperHelper.newInstance(I_M_MovementLine.class, movement);<NEW_LINE>movementLine.setAD_Org_ID(movement.getAD_Org_ID());<NEW_LINE>m... | setM_Product_ID(productId.getRepoId()); |
544,939 | public OIndexCursor cursor() {<NEW_LINE>OResultSet result = getDatabase().indexQuery(getName(), String.format(QUERY_ENTRIES, name));<NEW_LINE>// TODO a raw array instead...?<NEW_LINE><MASK><NEW_LINE>result.forEachRemaining(x -> copy.add(x));<NEW_LINE>result.close();<NEW_LINE>return new OIndexAbstractCursor() {<NEW_LINE... | final OInternalResultSet copy = new OInternalResultSet(); |
1,012,786 | public void validateInputFields() {<NEW_LINE>if (analysisConfig == null) {<NEW_LINE>throw new IllegalArgumentException(Messages.getMessage(Messages.JOB_CONFIG_MISSING_ANALYSISCONFIG));<NEW_LINE>}<NEW_LINE>if (dataDescription == null) {<NEW_LINE>throw new IllegalArgumentException(Messages.getMessage(Messages.JOB_CONFIG_... | .getPreferredName(), resultsIndexName)); |
1,690,236 | private static void replaceGuardNode(LoopEx loop, GuardNode guard, ValueNode range, StructuredGraph graph, long scaleCon, ValueNode offset) {<NEW_LINE>final InductionVariable counter = loop.counted().getLimitCheckedIV();<NEW_LINE>ValueNode rangeLong = IntegerConvertNode.convert(range, StampFactory.forInteger(64), graph... | replaceAtUsagesAndDelete(combinedGuard.asNode()); |
1,625,390 | public void saveSortConsumption(InlongGroupInfo bizInfo, String topic, String consumerGroup) {<NEW_LINE><MASK><NEW_LINE>ConsumptionEntity exists = consumptionMapper.selectConsumptionExists(groupId, topic, consumerGroup);<NEW_LINE>if (exists != null) {<NEW_LINE>log.warn("consumption with groupId={}, topic={}, consumer g... | String groupId = bizInfo.getInlongGroupId(); |
672,380 | private CompiledQuery alterTableDropOrAttachPartition(TableReader reader, int action, SqlExecutionContext executionContext) throws SqlException {<NEW_LINE>final int pos = lexer.lastTokenPosition();<NEW_LINE>TableReaderMetadata readerMetadata = reader.getMetadata();<NEW_LINE>if (readerMetadata.getPartitionBy() == Partit... | (lexer, (QueryModel) null); |
1,445,488 | public void detect(T input) {<NEW_LINE>descs.reset();<NEW_LINE>featureRadiuses.reset();<NEW_LINE>featureAngles.reset();<NEW_LINE>location.reset();<NEW_LINE>if (orientation != null) {<NEW_LINE>orientation.setImage(input);<NEW_LINE>}<NEW_LINE>describe.setImage(input);<NEW_LINE>detector.detect(input);<NEW_LINE>int N = det... | p.x, p.y); |
1,270,473 | public void disconnect(final boolean force) {<NEW_LINE>interrupt();<NEW_LINE>Log.d(Config.LOGTAG, account.getJid().asBareJid() + ": disconnecting force=" + force);<NEW_LINE>if (force) {<NEW_LINE>forceCloseSocket();<NEW_LINE>} else {<NEW_LINE>final TagWriter currentTagWriter = this.tagWriter;<NEW_LINE>if (currentTagWrit... | e.getMessage() + ")"); |
999,440 | public void testFailure(Failure failure) throws Exception {<NEW_LINE>if (failure == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (isAssumptionFailed(failure)) {<NEW_LINE>this.testAssumptionFailure(failure);<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>notified.add(failure.getDescription());<NEW_LINE>ITestResult tr = m_finde... | setThrowable(failure.getException()); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.