idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
254,837 | private static void printReport(List<JUnitResult> results) {<NEW_LINE>Iterator<String> it = targetClasses.iterator();<NEW_LINE>Criterion[] criterion = Properties.CRITERION;<NEW_LINE>while (it.hasNext()) {<NEW_LINE>String targetClass = it.next();<NEW_LINE>// restart variables<NEW_LINE>totalGoals = 0;<NEW_LINE>totalCover... | ) + "Target class " + Properties.TARGET_CLASS); |
424,418 | private CompletableFuture<SubscriptionDescription> putSubscriptionAsync(SubscriptionDescription subscriptionDescription, boolean isUpdate) {<NEW_LINE>if (subscriptionDescription == null) {<NEW_LINE>throw new IllegalArgumentException("queueDescription passed cannot be null");<NEW_LINE>}<NEW_LINE>SubscriptionDescriptionS... | ), subscriptionDescription.getSubscriptionName()); |
763,875 | public Application adapt(Container root, OverlayContainer rootOverlay, ArtifactContainer artifactContainer, Container containerToAdapt) throws UnableToAdaptException {<NEW_LINE>String containerPath = artifactContainer.getPath();<NEW_LINE>Application appDD = cacheGet(rootOverlay, containerPath, Application.class);<NEW_L... | containerPath, ApplicationRef.class, appDDRef); |
1,399,800 | private CodegenExpression codegenGet(EPTypeClass requiredType, CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) {<NEW_LINE>if (returnType == null) {<NEW_LINE>return constantNull();<NEW_LINE>}<NEW_LINE>EPTypeClass castTargetType = getCodegenReturnType(require... | CodegenBlock block = method.getBlock(); |
1,077,021 | public void doWork() {<NEW_LINE>long start = System.currentTimeMillis();<NEW_LINE>logger.info("Start to move abi");<NEW_LINE>AbiStore abiStore = chainBaseManager.getAbiStore();<NEW_LINE>ContractStore contractStore = chainBaseManager.getContractStore();<NEW_LINE>Iterator<Map.Entry<byte[], ContractCapsule>> it = contract... | count, System.currentTimeMillis()); |
43,847 | private static int forwardViterbiInitial(int pos, double[][] linearConstraints, int[] tagNum, int[] productSizes, double[][] windowScore, double[][] score, int[][] trace) {<NEW_LINE>// initial spot:<NEW_LINE>for (int product = 0, products = productSizes[pos]; product < products; product++) {<NEW_LINE>// Local copies, t... | final int tagNum_pos = tagNum[pos]; |
1,643,356 | public void buildReader(ParquetRecordReader reader, OutputMutator output) throws Exception {<NEW_LINE>if (totalNumRecordsToRead == 0) {<NEW_LINE>// there is no need to spend resources to init readers, when schema will be output<NEW_LINE>for (ParquetColumnMetadata columnMetadata : schema.getColumnMetadata()) {<NEW_LINE>... | = new VarLenBinaryReader(reader, varLengthColumns); |
342,766 | private static void addRoutingTable(RoutingSpec routing, RoutingTableSpec from) {<NEW_LINE>RoutingTableSpec to = getRoutingTable(routing, from.getProtocol());<NEW_LINE>if (to != null) {<NEW_LINE>Set<String> names = new HashSet<>();<NEW_LINE>for (int i = 0, len = to.getNumHops(); i < len; ++i) {<NEW_LINE>names.add(to.ge... | (i).getName()); |
750,691 | public ContentTypeProfiles unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>ContentTypeProfiles contentTypeProfiles = new ContentTypeProfiles();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (context.isStartOfDocument())<NEW_LINE... | ().unmarshall(context)); |
1,045,326 | public TubeMQResult brokerMethodProxy(@RequestParam String method, @RequestBody String req) throws Exception {<NEW_LINE>switch(method) {<NEW_LINE>case TubeConst.CLONE:<NEW_LINE>return nodeService.cloneBrokersWithTopic(gson.fromJson(req, CloneBrokersReq.class));<NEW_LINE>case TubeConst.ADD:<NEW_LINE>return masterService... | (req, BrokerSetReadOrWriteReq.class)); |
1,104,814 | private RibDelta<AnnotatedRoute<AbstractRoute>> processSideEffects(AnnotatedRoute<AbstractRoute> route, RibDelta<AnnotatedRoute<AbstractRoute>> initialDelta) {<NEW_LINE>if (initialDelta.isEmpty()) {<NEW_LINE>return RibDelta.empty();<NEW_LINE>}<NEW_LINE>assert initialDelta.getRoutes().contains(route);<NEW_LINE>RibDelta.... | (processAffectedRoute(nextRoute, affectedRoutes)); |
1,022,850 | public void call(CuratorRepository.CuratorFrameworkOp curatorFrameworkOp) throws SaturnJobConsoleException {<NEW_LINE>JobStatus js = jobService.getJobStatus(namespace, jobName);<NEW_LINE>if (!JobStatus.READY.equals(js)) {<NEW_LINE>throw new SaturnJobConsoleHttpException(HttpStatus.BAD_REQUEST.value(), String.format(JOB... | JobNodePath.getRunOneTimePath(jobName, executorName); |
1,628,487 | public int compare(final IBindingSet bs1, final IBindingSet bs2) {<NEW_LINE>if ((n++ % 1000) == 1) {<NEW_LINE>if (Thread.interrupted())<NEW_LINE>throw new RuntimeException(new InterruptedException());<NEW_LINE>}<NEW_LINE>for (int i = 0; i < sortOrder.length; i++) {<NEW_LINE>final ISortOrder<E> o = sortOrder[i];<NEW_LIN... | , v.get(bs2)); |
895,707 | public void discoverChildren() {<NEW_LINE>try {<NEW_LINE>ArrayList<SubtitleItem> subtitleItems = OpenSubtitle.<MASK><NEW_LINE>if (subtitleItems == null || subtitleItems.isEmpty()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Collections.sort(subtitleItems, new SubSort(getDefaultRenderer()));<NEW_LINE>reduceSubtitles(subtitle... | findSubtitles(originalResource, getDefaultRenderer()); |
561,384 | public void handleRequest(InputStream inputStream, OutputStream outputStream, Context context) throws IOException {<NEW_LINE>BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream));<NEW_LINE>JSONObject responseJson = new JSONObject();<NEW_LINE>AmazonDynamoDB client = AmazonDynamoDBClientBuilder.d... | responseBody.put("message", "New item created"); |
1,625,672 | protected void updateVariableInspector(ThreadReference t) {<NEW_LINE>if (!t.isSuspended()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>if (t.frameCount() == 0) {<NEW_LINE>// TODO: needs to be handled in a better way:<NEW_LINE>log("call stack empty");<NEW_LINE>} else {<NEW_LINE>// first get data<NEW_LINE>final... | getThisFields(t, 0, false); |
871,205 | public void onBindViewHolder(@NonNull FlairViewHolder holder, int position) {<NEW_LINE>if (flairs.get(holder.getBindingAdapterPosition()).isEditable()) {<NEW_LINE>holder.editFlairImageView.setVisibility(View.VISIBLE);<NEW_LINE>holder.editFlairImageView.setOnClickListener(view -> {<NEW_LINE>View dialogView = ((Activity)... | ()).getText()); |
147,966 | public void onDrawOver(@NonNull Canvas c, @NonNull RecyclerView parent, @NonNull RecyclerView.State state) {<NEW_LINE>super.onDrawOver(c, parent, state);<NEW_LINE>final int childCount = parent.getChildCount();<NEW_LINE>for (int i = 0; i < childCount; i++) {<NEW_LINE>final View child = parent.getChildAt(i);<NEW_LINE>int... | = (position + 1) % mSpanCount; |
1,200,691 | /*<NEW_LINE>Method to check for test inactivity, and terminate idle sessions<NEW_LINE>*/<NEW_LINE>@VisibleForTesting<NEW_LINE>public void terminateIdleSessions() {<NEW_LINE>String currentName = Thread.currentThread().getName();<NEW_LINE>Thread.currentThread().setName(getProxyName());<NEW_LINE>for (TestSlot testSlot : g... | ).toString(), executionTime); |
303,715 | public Object lookup(Name name) throws NamingException {<NEW_LINE>if (name.isEmpty()) {<NEW_LINE>// Asking to look up this context itself. Create and return<NEW_LINE>// a new instance with its own independent environment.<NEW_LINE>return cloneCtx();<NEW_LINE>}<NEW_LINE>// Extract components that belong to this namespa... | throw new NotContextException(atom + " does not name a context"); |
1,341,731 | static void vpx_d63_helper(FullAccessIntArrPointer dst, int stride, short... vals) {<NEW_LINE>dst = dst.shallowCopy();<NEW_LINE>dst.set(vals[0]);<NEW_LINE>dst.setRel(1, dst.setRel(2 * stride, vals[1]));<NEW_LINE>dst.setRel(2, dst.setRel(1 + 2 * stride, vals[2]));<NEW_LINE>dst.setRel(3, dst.setRel(2 + 2 * stride, vals[3... | * stride, vals[9]); |
1,751,253 | Proximity2DResult multiPathGetNearestCoordinate(MultiPath geom, Point2D inputPoint, boolean bTestPolygonInterior, boolean bCalculateLeftRightSide) {<NEW_LINE>if (geom.getType() == Geometry.Type.Polygon && bTestPolygonInterior) {<NEW_LINE>Envelope2D env = new Envelope2D();<NEW_LINE>geom.queryEnvelope2D(env);<NEW_LINE>do... | bRight, geom, closestVertexIndex, closestPathIndex); |
821,084 | protected JFreeChart createBubbleChart() throws JRException {<NEW_LINE>ChartFactory.setChartTheme(StandardChartTheme.createLegacyTheme());<NEW_LINE>JFreeChart jfreeChart = ChartFactory.createBubbleChart(evaluateTextExpression(getChart().getTitleExpression()), evaluateTextExpression(((JRBubblePlot) getPlot()).getXAxisLa... | XYBubbleRenderer bubbleRenderer = new XYBubbleRenderer(scaleType); |
1,408,940 | final GetLayerVersionPolicyResult executeGetLayerVersionPolicy(GetLayerVersionPolicyRequest getLayerVersionPolicyRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getLayerVersionPolicyRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>... | false), new GetLayerVersionPolicyResultJsonUnmarshaller()); |
1,581,768 | public Description matchMethod(MethodTree tree, VisitorState state) {<NEW_LINE>Type stringType = state.getSymtab().stringType;<NEW_LINE>boolean isFormatMethod = ASTHelpers.hasAnnotation(ASTHelpers.getSymbol(tree<MASK><NEW_LINE>boolean foundFormatString = false;<NEW_LINE>boolean foundString = false;<NEW_LINE>for (Variab... | ), FormatMethod.class, state); |
1,539,278 | final GetLogGroupFieldsResult executeGetLogGroupFields(GetLogGroupFieldsRequest getLogGroupFieldsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getLogGroupFieldsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.st... | addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint); |
1,152,252 | public static void onReceive(TermuxApiReceiver apiReceiver, Context context, Intent intent) {<NEW_LINE>Logger.logDebug(LOG_TAG, "onReceive");<NEW_LINE>String method = intent.getStringExtra("safmethod");<NEW_LINE>if (method == null) {<NEW_LINE><MASK><NEW_LINE>return;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>switch(method) {<N... | Logger.logError(LOG_TAG, "safmethod extra null"); |
971,488 | public static Memory register(Environment env, Memory... args) {<NEW_LINE>String code = args[0].toString();<NEW_LINE>String className = args[1].toString();<NEW_LINE>if (code.isEmpty()) {<NEW_LINE>throw new IllegalArgumentException("Argument 1 (code) must be not empty");<NEW_LINE>}<NEW_LINE>if (!code.matches("^[A-Za-z0-... | ), classEntity.getName()); |
467,032 | public Action visitApplyFilter(ApplyFilter applyFilter) {<NEW_LINE>IpAccessList acl = _availableAcls.get(applyFilter.getFilter());<NEW_LINE>Flow flow = _currentFlow.build();<NEW_LINE>FilterResult filterResult = acl.filter(flow, _srcInterface, _availableAcls, _namedIpSpaces);<NEW_LINE>boolean denied = filterResult.getAc... | .DENIED : StepAction.PERMITTED)); |
1,264,854 | private Object findPath(String string, XDebuggerTreeNode node, boolean checkChildren) {<NEW_LINE>TreePath path = node.getPath();<NEW_LINE>if (isMatchingElement(path, string)) {<NEW_LINE>return path;<NEW_LINE>}<NEW_LINE>XDebuggerTreeNode parent = ObjectUtil.tryCast(node.getParent(), XDebuggerTreeNode.class);<NEW_LINE>in... | result = findInChildren(node, string); |
345,901 | public ChangeApplier prepareChange(@Nonnull List<? extends VFileEvent> events) {<NEW_LINE>List<VirtualFile> toRecompute = new ArrayList<>();<NEW_LINE>Map<VirtualFile, Document> strongRefsToDocuments = new HashMap<>();<NEW_LINE>List<VFileContentChangeEvent> contentChanges = ContainerUtil.findAll(events, VFileContentChan... | strongRefsToDocuments, event.getFile()); |
119,786 | private <T> StructuredQuery exampleToQuery(Example<T> example, DatastoreQueryOptions queryOptions, boolean keyQuery) {<NEW_LINE>validateExample(example);<NEW_LINE>T probe = example.getProbe();<NEW_LINE>FullEntity.Builder<IncompleteKey> probeEntityBuilder = Entity.newBuilder();<NEW_LINE>this.datastoreEntityConverter.wri... | persistentProperty.getFieldName(), value); |
311,401 | public void paintInstance(InstancePainter painter) {<NEW_LINE>final var g = painter.getGraphics();<NEW_LINE>final var b = painter.getBounds();<NEW_LINE>final var x = b.getX();<NEW_LINE>final var y = b.getY();<NEW_LINE>final var height = (byte) b.getHeight();<NEW_LINE>final var width = (byte) b.getWidth();<NEW_LINE><MAS... | g.setColor(Color.DARK_GRAY); |
1,683,842 | void visitClass(Node classNode) {<NEW_LINE>String <MASK><NEW_LINE>Node classMembers = NodeUtil.getClassMembers(classNode);<NEW_LINE>Map<String, Node> setterDefByName = new LinkedHashMap<>();<NEW_LINE>Map<String, Node> getterDefByName = new LinkedHashMap<>();<NEW_LINE>// Collect static setters and getters.<NEW_LINE>for ... | className = NodeUtil.getName(classNode); |
1,013,909 | public void route(String path, Class<?> clazz, String methodName, HttpMethod httpMethod) {<NEW_LINE>try {<NEW_LINE>Assert.notNull(path, "Route path not is null!");<NEW_LINE><MASK><NEW_LINE>Assert.notNull(methodName, "Method name not is null");<NEW_LINE>Assert.notNull(httpMethod, "Request Method not is null");<NEW_LINE>... | Assert.notNull(clazz, "Route type not is null!"); |
1,403,283 | public PinotQueryGeneratorContext withTopN(LinkedHashMap<VariableReferenceExpression, SortOrder> orderByColumnOrderingMap, long limit) {<NEW_LINE>checkSupported(!hasLimit(), "Limit already exists. Pinot doesn't support order by limit on top of another limit");<NEW_LINE>if (!useSqlSyntax) {<NEW_LINE>checkSupported(!hasA... | orderByColumnInformation = new LinkedHashMap<>(); |
1,532,899 | public static DescribeTransferDomainsResponse unmarshall(DescribeTransferDomainsResponse describeTransferDomainsResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeTransferDomainsResponse.setRequestId(_ctx.stringValue("DescribeTransferDomainsResponse.RequestId"));<NEW_LINE>describeTransferDomainsResponse.setTotalCou... | (_ctx.longValue("DescribeTransferDomainsResponse.PageNumber")); |
1,803,222 | public void write(org.apache.thrift.protocol.TProtocol prot, bulkImport_args struct) throws org.apache.thrift.TException {<NEW_LINE>org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;<NEW_LINE>java.util.BitSet optionals = new java.util.BitSet();<NEW_LINE>if (struct.isSetT... | oprot.writeI64(struct.tid); |
194,714 | private void bind() {<NEW_LINE>if (Networking.EPOLL_AVAILABLE) {<NEW_LINE>ConsoleMessages.Info.NativeTransport.EPOLL.log();<NEW_LINE>} else if (Networking.KQUEUE_AVAILABLE) {<NEW_LINE>ConsoleMessages.Info.NativeTransport.KQUEUE.log();<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>ProtocolProvider protocolProvider = new ProtocolP... | CountDownLatch latch = new CountDownLatch(3); |
1,217,297 | public FetchRewrite rewriteToFetch(TableStats tableStats, Collection<Symbol> usedColumns) {<NEW_LINE>HashSet<Symbol> allUsedColumns = new HashSet<>(usedColumns);<NEW_LINE>allUsedColumns.addAll(orderBy.orderBySymbols());<NEW_LINE>FetchRewrite fetchRewrite = source.rewriteToFetch(tableStats, allUsedColumns);<NEW_LINE>if ... | > replacedOutputs = fetchRewrite.replacedOutputs(); |
192,897 | static RestLiResponseData<?> buildErrorResponseData(ResourceMethod method, RestLiServiceException exception, Map<String, String> headers, List<HttpCookie> cookies) {<NEW_LINE>switch(method) {<NEW_LINE>case GET:<NEW_LINE>return new RestLiResponseDataImpl<>(new GetResponseEnvelope(exception), headers, cookies);<NEW_LINE>... | (exception), headers, cookies); |
1,563,462 | public ResourceRef resolve(String resource) {<NEW_LINE>ResourceRef result = null;<NEW_LINE>// map script argument to script file<NEW_LINE>File probe = null;<NEW_LINE>try {<NEW_LINE>probe = Util.getCwd().resolve(resource).normalize().toFile();<NEW_LINE>} catch (InvalidPathException e) {<NEW_LINE>// Ignore<NEW_LINE>}<NEW... | extension(probe.getName()); |
745,820 | public Pair<Long, Object> peekNextNotNullValue(long nextStartTime, long nextEndTime) throws IOException {<NEW_LINE>try {<NEW_LINE>if (preCachedData != null && preCachedData.hasCurrent()) {<NEW_LINE>// save context<NEW_LINE>int readCurArrayIndex = preCachedData.getReadCurArrayIndex();<NEW_LINE>int readCurListIndex = pre... | (0).getResult()); |
53,714 | public static byte[] toBytes(Object obj) {<NEW_LINE>if (obj instanceof byte[]) {<NEW_LINE>return (byte[]) obj;<NEW_LINE>} else if (obj instanceof ByteBuffer) {<NEW_LINE>return Bufs.buf2bytes((ByteBuffer) obj);<NEW_LINE>} else if (obj instanceof InputStream) {<NEW_LINE>return IO<MASK><NEW_LINE>} else if (obj instanceof ... | .loadBytes((InputStream) obj); |
1,796,053 | public int LAPACKE_cbbcsd_work(int arg0, byte arg1, byte arg2, byte arg3, byte arg4, byte arg5, int arg6, int arg7, int arg8, FloatBuffer arg9, FloatBuffer arg10, FloatBuffer arg11, int arg12, FloatBuffer arg13, int arg14, FloatBuffer arg15, int arg16, FloatBuffer arg17, int arg18, FloatBuffer arg19, FloatBuffer arg20,... | arg25, arg26, arg27, arg28); |
702,549 | private void doLayout() {<NEW_LINE>setContentView(R.layout.layout_main);<NEW_LINE>setTitle(R.string.app_name);<NEW_LINE>Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);<NEW_LINE>setSupportActionBar(toolbar);<NEW_LINE>mDrawer = (DrawerLayout) <MASK><NEW_LINE>mTxtOrbotLog = (TextView) findViewById(R.id.orbotLog);<... | findViewById(R.id.drawer_layout); |
124,190 | public MenuTree createPrimaryContextMenu(JsonTree node) {<NEW_LINE>MenuTree primaryTree = new MenuTree(null);<NEW_LINE>JsonTreeValue.Type type = node.getValue().getType();<NEW_LINE>// Create the ADD_EXTENDED level.<NEW_LINE>if ((type == JsonTreeValue.Type.ARRAY && !"contents".equals(node.getValue().getKey())) || type =... | .get(OPTION_PASTE), node); |
860,286 | public Iterator<Entity> iterator() {<NEW_LINE>// TODO Don't loop through them all up front<NEW_LINE>LinkedList<Entity> entities = new LinkedList<>();<NEW_LINE>TraversalBranch branch = start;<NEW_LINE>while (branch.length() > 0) {<NEW_LINE>entities.addFirst(branch.endNode());<NEW_LINE>entities.addFirst(branch.lastRelati... | add(branch.lastRelationship()); |
991,738 | protected void update(PresentationData presentation) {<NEW_LINE>Object newElement = updateElement();<NEW_LINE>if (getElement() != newElement) {<NEW_LINE>presentation.setChanged(true);<NEW_LINE>}<NEW_LINE>if (newElement == null)<NEW_LINE>return;<NEW_LINE>ColorValue oldColor = myColor;<NEW_LINE>String oldName = myName;<N... | oldName, oldFragments, oldColor })); |
1,346,476 | public void shortReportLineTo(PrintWriter w) {<NEW_LINE>Map<String, Object> map = shortReportMap();<NEW_LINE>w.print(map.get("toeCount"));<NEW_LINE>w.print(" threads: ");<NEW_LINE>LinkedList<String> sortedSteps = (LinkedList<String>) map.get("steps");<NEW_LINE>{<NEW_LINE>Iterator<String> iter = sortedSteps.iterator();<... | print(iter.next()); |
742,398 | public TableAnswerElement answerDiff(NetworkSnapshot snapshot, NetworkSnapshot reference) {<NEW_LINE>DifferentialReachabilityParameters parameters = parameters(snapshot, reference);<NEW_LINE>DifferentialReachabilityResult result = _batfish.bddDifferentialReachability(snapshot, reference, parameters);<NEW_LINE>Set<Flow>... | new TableAnswerElement(metadata(true)); |
490,171 | private I_C_Mail toMailRecord(final InboundEMail email) {<NEW_LINE>final I_C_Mail mailRecord = InterfaceWrapperHelper.newInstance(I_C_Mail.class);<NEW_LINE>mailRecord.setIsInboundEMail(true);<NEW_LINE>mailRecord.setEMail_From(email.getFrom());<NEW_LINE>mailRecord.setEMail_To(Joiner.on(", ").join(email.getTo()));<NEW_LI... | Services.get(IUserDAO.class); |
147,511 | public Request<DescribeAnalysisSchemesRequest> marshall(DescribeAnalysisSchemesRequest describeAnalysisSchemesRequest) {<NEW_LINE>if (describeAnalysisSchemesRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<DescribeAnalysisSchemesRequest> r... | request.setHttpMethod(HttpMethodName.POST); |
231,931 | private Collection<String> findHintStrategyTables(final SQLStatementContext<?> sqlStatementContext) {<NEW_LINE>Collection<String> result = new HashSet<>();<NEW_LINE>for (String each : sqlStatementContext.getTablesContext().getTableNames()) {<NEW_LINE>Optional<TableRule> tableRule = rule.findTableRule(each);<NEW_LINE>if... | = databaseHintStrategy instanceof NoneShardingStrategyConfiguration && tableHintStrategy instanceof HintShardingStrategyConfiguration; |
901,218 | public AddressPicker createAddressPicker(Node node) {<NEW_LINE>Config config = node.getConfig();<NEW_LINE>MemberAddressProviderConfig memberAddressProviderConfig = getActiveMemberNetworkConfig(config).getMemberAddressProviderConfig();<NEW_LINE>final ILogger addressPickerLogger = <MASK><NEW_LINE>if (!memberAddressProvid... | node.getLogger(AddressPicker.class); |
1,823,018 | public void removeNode(Long nodeId, String xSdsAuthToken) throws ApiException {<NEW_LINE>Object localVarPostBody = null;<NEW_LINE>// verify the required parameter 'nodeId' is set<NEW_LINE>if (nodeId == null) {<NEW_LINE>throw new ApiException(400, "Missing the required parameter 'nodeId' when calling removeNode");<NEW_L... | HashMap<String, Object>(); |
1,116,872 | private CostDetailCreateResult createIssueOrReceipt(final CostDetailCreateRequest request) {<NEW_LINE>final AcctSchema acctSchema = acctSchemasRepo.getById(request.getAcctSchemaId());<NEW_LINE>final CurrentCost currentCosts = getCurrentCost(request);<NEW_LINE>final CostPrice price = currentCosts.getCostPrice();<NEW_LIN... | CostDetailPreviousAmounts.of(currentCosts))); |
919,722 | public static void main(String[] args) {<NEW_LINE>List<Integer> fList = List.list(<MASK><NEW_LINE>List<Boolean> evenList = fList.map(isEven);<NEW_LINE>Show.listShow(Show.booleanShow).println(evenList);<NEW_LINE>fList = fList.map(i -> i + 1);<NEW_LINE>Show.listShow(Show.intShow).println(fList);<NEW_LINE>Array<Integer> a... | 3, 4, 5, 6); |
1,323,214 | private void applyRenderingRule(ImageServiceRaster imageServiceRaster, int index) {<NEW_LINE>// clear all rasters<NEW_LINE>mMapView.getMap().getOperationalLayers().clear();<NEW_LINE>// get the rendering rule info at the selected index<NEW_LINE>RenderingRuleInfo renderRuleInfo = imageServiceRaster.getServiceInfo().getRe... | getOperationalLayers().add(rasterLayer); |
1,236,277 | public File writeFile(File outdirFile, String fileName) throws IOException {<NEW_LINE>fileName += RestConstants.SNAPSHOT_FILENAME_EXTENTION;<NEW_LINE>final File file = new File(outdirFile, fileName);<NEW_LINE>try (JsonBuilder jsonBuilder = new JsonBuilder(JsonBuilder.Pretty.INDENTED, new FileWriter(file))) {<NEW_LINE>S... | <NamedDataSchema> models = generateModelList(); |
1,412,701 | public static LogResult postLog(@NonNull final Geocache cache, @NonNull final LogType logType, @NonNull final Calendar date, @NonNull final String log, @Nullable final String logPassword, @NonNull final OCApiConnector connector, @NonNull final ReportProblemType reportProblem) {<NEW_LINE>final Parameters params = new Pa... | params.add("password", logPassword); |
754,869 | private static void writePropertyRecord(WritableChannel channel, PropertyRecord record) throws IOException {<NEW_LINE>byte flags = bitFlags(bitFlag(record.inUse(), Record.IN_USE.byteValue()), bitFlag(record.getRelId() != -1, Record.REL_PROPERTY.byteValue()), bitFlag(record.requiresSecondaryUnit(), Record.REQUIRE_SECOND... | putLong(record.getSecondaryUnitId()); |
300,653 | Single<FilterableStreamingHttpConnection> newFilterableConnection(final ResolvedAddress resolvedAddress, final TransportObserver observer) {<NEW_LINE>assert config.h2Config() != null;<NEW_LINE>// This state is read only, so safe to keep a copy across Subscribers<NEW_LINE>final ReadOnlyTcpClientConfig tcpConfig = withSs... | .allowDropTrailersReadFromTransport()), observer); |
320,913 | public void run() {<NEW_LINE>TcpProxy tcp = TcpProxy.getTcpProxy(serverId);<NEW_LINE>final List<AlertData> dataList = new ArrayList<AlertData>();<NEW_LINE>try {<NEW_LINE>MapPack param = new MapPack();<NEW_LINE>param.put("date", yyyymmdd);<NEW_LINE>param.put("stime", stime);<NEW_LINE>param.put("etime", etime);<NEW_LINE>... | param.put("object", object); |
188,031 | public RequestCommitIndexResponse requestCommitIndex(RaftNode header) throws TException {<NEW_LINE>long commitIndex;<NEW_LINE>long commitTerm;<NEW_LINE>long curTerm;<NEW_LINE>synchronized (member.getTerm()) {<NEW_LINE>commitIndex = member<MASK><NEW_LINE>commitTerm = member.getLogManager().getCommitLogTerm();<NEW_LINE>c... | .getLogManager().getCommitLogIndex(); |
897,813 | private IType[] searchForOuterTypesOfReferences(IMethod[] newNameMethods, IProgressMonitor pm) throws CoreException {<NEW_LINE>final Set<IType> outerTypesOfReferences = new HashSet<>();<NEW_LINE>SearchPattern pattern = RefactoringSearchEngine.createOrPattern(newNameMethods, IJavaSearchConstants.REFERENCES);<NEW_LINE>IJ... | [outerTypesOfReferences.size()]); |
961,221 | public void aboutToShow(@Named(IServiceConstants.ACTIVE_PART) MPart part, List<MMenuElement> items, IEclipseContext context) {<NEW_LINE>if (!MenuHelper.getActiveClientInput(part, false).isPresent())<NEW_LINE>return;<NEW_LINE>PortfolioPart portfolioPart = (PortfolioPart) part.getObject();<NEW_LINE>items.add(create(portf... | , AccountTransaction.Type.TAXES)); |
95,281 | protected Index basicGetJandexIndex() {<NEW_LINE>String useJandexIndexPath = getJandexIndexPath();<NEW_LINE>if (tc.isDebugEnabled()) {<NEW_LINE>Tr.debug(tc, MessageFormat.format("[ {0} ] Looking for JANDEX [ {1} ] in [ {2} ]", new Object[] { getHashText(), useJandexIndexPath, getContainer().getPhysicalPath() }));<NEW_L... | "JANDEX_INDEX_READ_EXCEPTION", useJandexIndexPath, getCanonicalName()); |
1,819,067 | // ------------------------------------------------------------------------------<NEW_LINE>// Method: RecoveryLog.createRecoverableUnit<NEW_LINE>// ------------------------------------------------------------------------------<NEW_LINE>@Override<NEW_LINE>public synchronized RecoverableUnit createRecoverableUnit(Failure... | _logName + "' created a new RecoverableUnit with id '" + identity + "'"); |
907,843 | public boolean update(BookmarkBase bookmark) {<NEW_LINE>// start a transaction<NEW_LINE>SQLiteDatabase db = getWritableDatabase();<NEW_LINE>db.beginTransaction();<NEW_LINE>// bookmark settings<NEW_LINE>ContentValues values = new ContentValues();<NEW_LINE>values.put(BookmarkDB.DB_KEY_BOOKMARK_LABEL, bookmark.getLabel())... | (), null) == 1); |
1,723,437 | private void shareLogs() {<NEW_LINE>try {<NEW_LINE>String fileName = "MBW-" + dateFormat.format(new Date()) + ".txt";<NEW_LINE>File logsExport = DataExport.getLogsExport(getFormattedLogs(<MASK><NEW_LINE>PackageManager packageManager = Preconditions.checkNotNull(this.getPackageManager());<NEW_LINE>PackageInfo packageInf... | null), getFileStreamPath(fileName)); |
356,041 | public boolean open() {<NEW_LINE>try {<NEW_LINE>updateSerialProperties(m_devName);<NEW_LINE>CommPortIdentifier ci = CommPortIdentifier.getPortIdentifier(m_devName);<NEW_LINE>CommPort cp = ci.open(m_appName, 1000);<NEW_LINE>if (cp instanceof SerialPort) {<NEW_LINE>m_port = (SerialPort) cp;<NEW_LINE>} else {<NEW_LINE>thr... | logger.debug("setting port speed to {}", m_speed); |
1,206,614 | final PutMetricAlarmResult executePutMetricAlarm(PutMetricAlarmRequest putMetricAlarmRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(putMetricAlarmRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "PutMetricAlarm"); |
1,313,613 | // Inspired by {@code GrizzlyHttpContainer.GrizzlyBinder} from Jersey to Grizzly integration.<NEW_LINE>@Override<NEW_LINE>protected void configure() {<NEW_LINE>bindFactory(WebServerRequestReferencingFactory.class).to(ServerRequest.class).proxy(true).proxyForSameScope(false).in(RequestScoped.class);<NEW_LINE>bindFactory... | ).in(RequestScoped.class); |
1,789,655 | private // /////////////////////////////////////////////////////////////////////////////////////////<NEW_LINE>GridPane createInfoPopover() {<NEW_LINE>GridPane infoGridPane = new GridPane();<NEW_LINE>infoGridPane.setHgap(5);<NEW_LINE>infoGridPane.setVgap(5);<NEW_LINE>infoGridPane.setPadding(new Insets(10, 10, 10, 10));<... | (separator, 1, i++); |
1,372,113 | public static ChannelDescriptionChangedEvent createChannelDescriptionStateOptionsChangedEvent(ChannelUID channelUID, Set<String> linkedItemNames, List<StateOption> options, @Nullable List<StateOption> oldOptions) {<NEW_LINE>checkNotNull(linkedItemNames, "linkedItemNames");<NEW_LINE>checkNotNull(channelUID, "channelUID"... | channelUID, linkedItemNames, stateOptionsPayload, oldStateOptionsPayload); |
1,590,806 | private void validate(APIAddAccessControlListEntryMsg msg) {<NEW_LINE>List<String> listenerUuids = Q.New(LoadBalancerListenerACLRefVO.class).select(LoadBalancerListenerACLRefVO_.listenerUuid).eq(LoadBalancerListenerACLRefVO_.aclUuid, msg.getAclUuid()).listValues();<NEW_LINE>if (listenerUuids.isEmpty()) {<NEW_LINE>retur... | collect(Collectors.toList()); |
298,537 | public static DescribeInstancesResponse unmarshall(DescribeInstancesResponse describeInstancesResponse, UnmarshallerContext context) {<NEW_LINE>describeInstancesResponse.setRequestId(context.stringValue("DescribeInstancesResponse.RequestId"));<NEW_LINE>describeInstancesResponse.setTotalCount(context.integerValue("Descr... | ("DescribeInstancesResponse.Instances[" + i + "].CreateTime")); |
413,251 | final DescribeApiDestinationResult executeDescribeApiDestination(DescribeApiDestinationRequest describeApiDestinationRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeApiDestinationRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_... | HandlerContextKey.SIGNING_REGION, getSigningRegion()); |
1,637,899 | public void process() {<NEW_LINE>EjbBundleDescriptorImpl bundle = ctx.getModuleMetaData(EjbBundleDescriptorImpl.class);<NEW_LINE>ResourceReferenceDescriptor cmpResource = bundle.getCMPResourceReference();<NEW_LINE>// If this bundle's beans are not created by Java2DB, there is nothing to do.<NEW_LINE>if (!DeploymentHelp... | createTables = helper.getCreateTables(userCreateTables); |
1,142,860 | private RectangleNode mergeOneToOne() {<NEW_LINE>long x_min = Long.MAX_VALUE, y_min = Long.MAX_VALUE;<NEW_LINE>long x_max = Long.MIN_VALUE, y_max = Long.MIN_VALUE;<NEW_LINE>SegmentNode p = header[GeometricManager.ONE_TO_ONE];<NEW_LINE>header[GeometricManager.ONE_TO_ONE] = null;<NEW_LINE>size[GeometricManager.ONE_TO_ONE... | = p.I1 + p.L; |
63,260 | private void processHeaderData(ZipModel zipModel, OutputStream outputStream) throws IOException {<NEW_LINE>int currentSplitFileCounter = 0;<NEW_LINE>if (outputStream instanceof OutputStreamWithSplitZipSupport) {<NEW_LINE>zipModel.getEndOfCentralDirectoryRecord().setOffsetOfStartOfCentralDirectory(((OutputStreamWithSpli... | ) outputStream).getFilePointer()); |
266,398 | public static void createMarkers(final IJavaProject javaProject, final SortedBugCollection theCollection, final ISchedulingRule rule, IProgressMonitor monitor) {<NEW_LINE>if (monitor.isCanceled()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>final List<MarkerParameter> bugParameters = <MASK><NEW_LINE>if (monitor.isCanceled()... | createBugParameters(javaProject, theCollection, monitor); |
1,285,988 | public void close() throws DocumentException, IOException {<NEW_LINE>if (!hasSignature) {<NEW_LINE>if (cleanMetadata && stamper.xmpMetadata == null) {<NEW_LINE>ByteArrayOutputStream baos = new ByteArrayOutputStream();<NEW_LINE>try {<NEW_LINE>XmpWriter writer = new XmpWriter(baos, moreInfo);<NEW_LINE>writer.close();<NEW... | ] buf = new byte[8192]; |
830,168 | private static void throwForSettersWithTheAnnotation(List<AnnotatedSetter> setters, Class<? extends Annotation> annotationClass) {<NEW_LINE>if (setters.size() == 1) {<NEW_LINE>AnnotatedSetter setter = setters.get(0);<NEW_LINE>throw new IllegalArgumentException(String.format("Expected setter for property [%s] to not be ... | IllegalArgumentException(builder.toString()); |
412,570 | protected String doIt() throws Exception {<NEW_LINE>final I_M_Product product = InterfaceWrapperHelper.create(getCtx(), getRecord_ID(), <MASK><NEW_LINE>if (product == null) {<NEW_LINE>return "@NotFound@" + "@M_Product_ID@";<NEW_LINE>}<NEW_LINE>final I_M_Product targetProduct = InterfaceWrapperHelper.create(getCtx(), p_... | I_M_Product.class, getTrxName()); |
1,245,086 | protected void deployResourcesInternal(String deploymentNameHint, Resource[] resources, EventRegistryEngine engine) {<NEW_LINE>EventRepositoryService repositoryService = engine.getEventRepositoryService();<NEW_LINE>// Create a deployment for each distinct parent folder using the name hint as a prefix<NEW_LINE>final Map... | enableDuplicateFiltering().name(deploymentName); |
912,218 | protected final void addTableCacheConfig(final ITableCacheConfig cacheConfig, final boolean override) {<NEW_LINE>if (!Adempiere.isUnitTestMode()) {<NEW_LINE>final POInfo poInfo = POInfo.<MASK><NEW_LINE>if (!poInfo.isSingleKeyColumnName()) {<NEW_LINE>logger.warn("Skip adding {} because the table does not have a single p... | getPOInfo(cacheConfig.getTableName()); |
598,904 | public Tensor reshape(int[] newShape) {<NEW_LINE>int sum = Tensor.shapeSum(newShape);<NEW_LINE>if (sum != elements.length) {<NEW_LINE>throw new IllegalArgumentException("Invalid shape " + Arrays.toString(newShape) + ", expected something with " + elements.length + " elements.");<NEW_LINE>}<NEW_LINE>if (newShape.length ... | 0], newShape[1]); |
208,017 | public void process(JCas passagesView) throws AnalysisEngineProcessException {<NEW_LINE>List<PassScore> passages = new LinkedList<PassScore>();<NEW_LINE>for (Passage passage : JCasUtil.select(passagesView, Passage.class)) {<NEW_LINE>PassageFV fv = new PassageFV(passage);<NEW_LINE>int clueWeight_i = PassageFV.featureInd... | PassageFV.featureIndex(PF_AboutClueWeight.class); |
465,022 | public Request<ListSSHPublicKeysRequest> marshall(ListSSHPublicKeysRequest listSSHPublicKeysRequest) {<NEW_LINE>if (listSSHPublicKeysRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<ListSSHPublicKeysRequest> request = new DefaultRequest<Li... | (listSSHPublicKeysRequest.getUserName())); |
1,741,867 | public static Predicate<HUEditorRow> toPredicate(@NonNull final HUEditorRowFilter filter) {<NEW_LINE>Predicate<HUEditorRow> predicate = Predicates.alwaysTrue();<NEW_LINE>if (filter == HUEditorRowFilter.ALL) {<NEW_LINE>return predicate;<NEW_LINE>}<NEW_LINE>// Filter by row type<NEW_LINE>final Select rowType = filter.get... | (row.getHuId())); |
972,564 | public Statement apply(final Statement base, final Description description) {<NEW_LINE>return new Statement() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void evaluate() throws Throwable {<NEW_LINE>try {<NEW_LINE>base.evaluate();<NEW_LINE>} catch (Throwable t) {<NEW_LINE>log.info("Test failed. Attempting to create a... | ).getScreenshotAs(OutputType.FILE); |
191,647 | private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, String resourceName) {<NEW_LINE>if (this.client.getEndpoint() == null) {<NEW_LINE>return Mono.error(new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));<NEW_LINE>}<NEW_LINE>if (this.client.get... | error(new IllegalArgumentException("Parameter this.client.getSubscriptionId() is required and cannot be null.")); |
718,881 | private void scaleJobsUpNow(int counter) {<NEW_LINE>// if another scale-up was scheduled after this one, ignore this one<NEW_LINE>if (scaleUpScheduledCount.get() != counter) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>// if we can't start jobs yet, we also won't tear them down<NEW_LINE>if (!shouldStartJobs()) {<NEW_LINE>sch... | getMembers(DATA_MEMBER_SELECTOR).size(); |
1,167,344 | public boolean canExchangeTo(ClientModel authorizedClient, ClientModel to) {<NEW_LINE>if (!authorizedClient.equals(to)) {<NEW_LINE>ResourceServer server = resourceServer(to);<NEW_LINE>if (server == null) {<NEW_LINE>logger.debug("No resource server set up for target client");<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>R... | logger.debug(TOKEN_EXCHANGE + " not initialized"); |
652,143 | private void writeEnum(XmlWriter writer, Enum enuum) {<NEW_LINE>XmlAttributes attrs = new XmlAttributes();<NEW_LINE>attrs.addAttribute("NAME", enuum.getDisplayName());<NEW_LINE>attrs.addAttribute("NAMESPACE", enuum.getCategoryPath().getPath());<NEW_LINE>attrs.addAttribute("SIZE", <MASK><NEW_LINE>writer.startElement("EN... | enuum.getLength(), true); |
761,648 | public WebResourceResponse intercept(String url) {<NEW_LINE>WebResourceResponse res = null;<NEW_LINE>String postData = mPrefs.getPostData();<NEW_LINE>if (mPrefs.isMirrorEnabled() && postData != null) {<NEW_LINE>LoungeData loungeData = <MASK><NEW_LINE>if (loungeData.isDisconnected()) {<NEW_LINE>mExoRootInterceptor.getTw... | LoungeData.parse(postData, url); |
975,878 | private Message<?> doPostProcessResult(Object result, String targetPrefix) {<NEW_LINE>// result instanceof Message ? (Message<?>) result : null;<NEW_LINE>Message<?> resultMessage = null;<NEW_LINE>CloudEventMessageBuilder<?> messageBuilder;<NEW_LINE>if (result instanceof Message) {<NEW_LINE>if (CloudEventMessageUtils.is... | getClass().getName()); |
1,085,705 | private void browseForIcons() {<NEW_LINE>GhidraFileChooser iconFileChooser = new GhidraFileChooser(getComponent());<NEW_LINE>iconFileChooser.setFileSelectionMode(GhidraFileChooser.FILES_ONLY);<NEW_LINE>iconFileChooser.setTitle("Choose Icon");<NEW_LINE>iconFileChooser.setApproveButtonToolTipText("Choose Icon");<NEW_LINE... | File file = iconFileChooser.getSelectedFile(); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.