idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,849,495 | public BDD computeFinalHeaderSpaceBdd(BDD initialHeaderSpaceBdd) {<NEW_LINE>BDD finalHeaderSpace = initialHeaderSpaceBdd;<NEW_LINE>BDD noDstIp = finalHeaderSpace.exist(_dstIpVars);<NEW_LINE>if (!noDstIp.equals(finalHeaderSpace)) {<NEW_LINE>// there's a constraint on dst Ip, so include nat pool Ips<NEW_LINE>BDD dstTrans... | (noDstIp.and(dstTransformationRange)); |
1,717,972 | public List<JavascriptResource> build(JavascriptGeneratorMode mode, boolean isCompat, String inputContent, String outputFileName) {<NEW_LINE>boolean minified = mode.getJavascriptWriter() == JavascriptWriter.CLOSURE_AURA_PROD;<NEW_LINE>boolean isProdDebug = ((mode == JavascriptGeneratorMode.PRODUCTIONDEBUG) || (mode == ... | (isProdDebug ? engineProdDebug : engine)); |
758,501 | public void rollbackPreparedTransaction(String xid) throws TransactionException, PersistenceException {<NEW_LINE>if (isAnyTracingEnabled() && tc.isEntryEnabled())<NEW_LINE>SibTr.entry(this, tc, "rollbackPreparedTransaction", xid);<NEW_LINE>if (_manager != null) {<NEW_LINE>try {<NEW_LINE>PersistentTranId pid = new Persi... | exit(this, tc, "rollbackPreparedTransaction"); |
521,797 | private static LoadBalancer create(@Nullable @JsonProperty(JSON_KEY_LOAD_BALANCER_ARN) String arn, @Nullable @JsonProperty(JSON_KEY_AVAILABILITY_ZONES) List<AvailabilityZone> availabilityZones, @Nullable @JsonProperty(JSON_KEY_DNS_NAME) String dnsName, @Nullable @JsonProperty(JSON_KEY_LOAD_BALANCER_NAME) String name, @... | checkNonNull(arn, JSON_KEY_LOAD_BALANCER_ARN, "LoadBalancer"); |
804,131 | public void check(Database database, DatabaseChangeLog changeLog, ChangeSet changeSet, ChangeExecListener changeExecListener) throws PreconditionFailedException, PreconditionErrorException {<NEW_LINE>try {<NEW_LINE>PrimaryKey example = new PrimaryKey();<NEW_LINE>Table table = new Table();<NEW_LINE>table.setSchema(new S... | PreconditionErrorException(e, changeLog, this); |
363,371 | public void onTagLoadSuccess(List<Tag> list) {<NEW_LINE>hideProgressDialog();<NEW_LINE>mTagList.add(new Tag(TagManager.TAG_FINISH, getString(<MASK><NEW_LINE>mTagList.add(new Tag(TagManager.TAG_CONTINUE, getString(R.string.comic_status_continue)));<NEW_LINE>mTagList.addAll(list);<NEW_LINE>int size = mTagList.size();<NEW... | R.string.comic_status_finish))); |
785,431 | public void runDemo() {<NEW_LINE>ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("META-INF/spring/integration/bootstrap-config/stubbed-loan-broker.xml");<NEW_LINE>LoanBrokerGateway broker = context.<MASK><NEW_LINE>LoanRequest loanRequest = new LoanRequest();<NEW_LINE>loanRequest.setCustomer(... | getBean("loanBrokerGateway", LoanBrokerGateway.class); |
1,222,839 | public void addRow(final KeyValue column) {<NEW_LINE>if (key == null) {<NEW_LINE><MASK><NEW_LINE>}<NEW_LINE>if (Bytes.memcmp(column.key(), key, Const.SALT_WIDTH(), key.length - Const.SALT_WIDTH()) != 0) {<NEW_LINE>throw new IllegalDataException("Attempt to add a different row=" + column + ", this=" + this);<NEW_LINE>}<... | throw new IllegalStateException("setRow was never called on " + this); |
1,295,624 | private Object toJsonValue_PrettyValues(@Nullable final Object value, @NonNull final KPIJsonOptions jsonOpts) {<NEW_LINE>if (value == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>if (valueType == KPIFieldValueType.Date) {<NEW_LINE>if (value instanceof String) {<NEW_LINE>final Date date = TimeUtil.as... | getLanguage(jsonOpts.getAdLanguage()); |
118,686 | public static Rectangle drawBoxedString(Graphics2D g, String string, int x, int y, int justification, ImageLabel background, Color foreground) {<NEW_LINE>if (string == null) {<NEW_LINE>string = "";<NEW_LINE>}<NEW_LINE>FontMetrics fm = g.getFontMetrics();<NEW_LINE>int strWidth = SwingUtilities.computeStringWidth(fm, str... | .getHeight() + BOX_PADDINGY * 2; |
1,647,012 | protected void initDisplay() {<NEW_LINE>display = NewtFactory.createDisplay(null);<NEW_LINE>display.addReference();<NEW_LINE>screen = NewtFactory.createScreen(display, 0);<NEW_LINE>screen.addReference();<NEW_LINE>GraphicsEnvironment environment = GraphicsEnvironment.getLocalGraphicsEnvironment();<NEW_LINE>GraphicsDevic... | + 1, awtDevices[i]); |
553,376 | public Single<FullIssue> refresh() {<NEW_LINE>return store.refreshIssue(repo, issueNumber).flatMap(issue -> {<NEW_LINE>if (issue.pullRequest() != null) {<NEW_LINE>return getPullRequest(repo.owner().login(), repo.name(), issueNumber).map(pullRequest -> issue.toBuilder().pullRequest(pullRequest).build());<NEW_LINE>}<NEW_... | ), issue.bodyHtml()); |
70,796 | public boolean currentlyInJavaEditor() {<NEW_LINE>// Get focused TopComponent<NEW_LINE>TopComponent top1 = WindowManager.getDefault().getRegistry().getActivated();<NEW_LINE>if (top1 == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>// Get most active editor<NEW_LINE>JTextComponent editor = EditorRegistry.lastFocuse... | fileObject = NbEditorUtilities.getFileObject(document); |
707,279 | private File downloadFile(String fileToDownload, String urlToDownload) throws IOException {<NEW_LINE>long range = 0;<NEW_LINE>String path = cacheDir + "/" + fileToDownload;<NEW_LINE>File outputFile = new File(path);<NEW_LINE>if (outputFile.isFile()) {<NEW_LINE>range = outputFile.length();<NEW_LINE>} else {<NEW_LINE>rem... | ) (range * 100 / fileLength); |
964,247 | public IamInstanceProfileAssociation unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>IamInstanceProfileAssociation iamInstanceProfileAssociation = new IamInstanceProfileAssociation();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>i... | ().unmarshall(context)); |
1,381,203 | ClusterModelStats populate(ClusterModel clusterModel, BalancingConstraint balancingConstraint, OptimizationOptions optimizationOptions) {<NEW_LINE>final SortedSet<Broker> brokers = clusterModel.brokers();<NEW_LINE>final Set<Broker> aliveBrokers = clusterModel.aliveBrokers();<NEW_LINE>Set<String> topics = clusterModel.t... | utilizationForResources(clusterModel, optimizationOptions, aliveBrokers); |
400,006 | final DescribeNetworkInterfaceAttributeResult executeDescribeNetworkInterfaceAttribute(DescribeNetworkInterfaceAttributeRequest describeNetworkInterfaceAttributeRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeNetworkInterfaceAttributeRequest);<NEW_LINE>AWSRequestMetrics awsRequest... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
128,312 | public boolean send(Object data, boolean close) throws IOException {<NEW_LINE>if (closedRan.get()) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>if (isWebSocket()) {<NEW_LINE>if (data instanceof Map) {<NEW_LINE>// only get the :body if map<NEW_LINE>Object tmp = ((Map<Keyword, Object>) data).get(BODY);<NEW_LINE>if (tmp !... | + data.getClass() + "), but only string, byte[], InputStream expected"; |
369,237 | public void write(JsonWriter out, CatAllOf value) throws IOException {<NEW_LINE>JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject();<NEW_LINE>obj.remove("additionalProperties");<NEW_LINE>// serialize additonal properties<NEW_LINE>if (value.getAdditionalProperties() != null) {<NEW_LINE>for (Map.Entry<String... | Boolean) entry.getValue()); |
1,589,479 | public static boolean isSubTypeOf(String typeA, ClassLoader loader, String... types) {<NEW_LINE>if (typeA == null || typeA.equals(Constants.OBJECT_INTERNAL)) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>if (types.length == 0) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>boolean internal = types[0].contains("/");<NEW_LI... | sTypesInfo = ci.getSupertypes(false); |
1,440,800 | private void readArchiveData() throws IOException {<NEW_LINE>// INDEX<NEW_LINE>// Pad<NEW_LINE>archiveIndexFile.readInt();<NEW_LINE>// UserData, should be 0<NEW_LINE>archiveIndexFile.readLong();<NEW_LINE>entryCount = archiveIndexFile.readInt();<NEW_LINE>entryOffset = archiveIndexFile.readInt();<NEW_LINE>hashOffset = ar... | .flags = archiveIndexFile.readInt(); |
1,627,377 | public void onAdLoaded(@NonNull InterstitialAd interstitialAd) {<NEW_LINE>// The mInterstitialAd reference will be null until<NEW_LINE>// an ad is loaded.<NEW_LINE>MyActivity.this.interstitialAd = interstitialAd;<NEW_LINE>Log.i(TAG, "onAdLoaded");<NEW_LINE>Toast.makeText(MyActivity.this, "onAdLoaded()", Toast.LENGTH_SH... | Log.d("TAG", "The ad was dismissed."); |
827,254 | final TagResourceResult executeTagResource(TagResourceRequest tagResourceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(tagResourceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTi... | HandlerContextKey.SIGNING_REGION, getSigningRegion()); |
1,745,737 | public void adjust(ByteBuf dataBuf, int numInputs, int numOutputs) {<NEW_LINE>// used to accumulate the updates for input vectors<NEW_LINE>float[] neu1e = new float[dim];<NEW_LINE>float[] inputUpdates = new float[numInputs * dim];<NEW_LINE>Int2IntOpenHashMap inputIndex = new Int2IntOpenHashMap();<NEW_LINE>Int2IntOpenHa... | float g = dataBuf.readFloat(); |
72,552 | public boolean apply(Game game, Ability source) {<NEW_LINE>Permanent permanent = game.getPermanent(source.getTargets().getFirstTarget());<NEW_LINE>Player player = game.getPlayer(source.getControllerId());<NEW_LINE>if (player == null || permanent == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>List<Permanent> <MAS... | attachments = new ArrayList<>(); |
782,894 | public ScaleneTriangle read(JsonReader in) throws IOException {<NEW_LINE>JsonObject jsonObj = elementAdapter.read(in).getAsJsonObject();<NEW_LINE>validateJsonObject(jsonObj);<NEW_LINE>// store additional fields in the deserialized instance<NEW_LINE>ScaleneTriangle instance = thisAdapter.fromJsonTree(jsonObj);<NEW_LINE>... | getValue().getAsString()); |
1,787,188 | private void extractDomainRoles(Content dataSource) {<NEW_LINE>try {<NEW_LINE>// Get web history blackboard artifacts<NEW_LINE>Collection<BlackboardArtifact> listArtifacts = currentCase.getSleuthkitCase().getBlackboard().getArtifacts(QUERY_ARTIFACTS, Arrays.asList<MASK><NEW_LINE>// NON-NLS<NEW_LINE>logger.log(Level.INF... | (dataSource.getId())); |
1,224,243 | protected Composite createDialogArea(Composite parent) {<NEW_LINE>Composite credGroup = super.createDialogArea(parent);<NEW_LINE>((GridLayout) credGroup.getLayout()).numColumns = 2;<NEW_LINE>CLabel infoLabel = UIUtils.createInfoLabel(credGroup, getTitle());<NEW_LINE>GridData gd = new GridData(GridData.FILL_HORIZONTAL);... | SWT.BORDER | SWT.PASSWORD); |
1,682,825 | private static void testDateTime() {<NEW_LINE>{<NEW_LINE>final Date now = Foo.now();<NEW_LINE>final <MASK><NEW_LINE>final DateFormat df = new SimpleDateFormat("MM/dd/yyyy HH:mm:ss");<NEW_LINE>System.out.println("now: " + df.format(now));<NEW_LINE>final Date today = Calendar.getInstance().getTime();<NEW_LINE>System.out.... | Date nowChrono = Foo.chrono_now(); |
1,821,299 | public static Properties baseStreamsConfig(final String bootstrapServers, final String stateDir, final String appId, final boolean enableEOS, final Properties defaultConfig) {<NEW_LINE>final Properties config = new Properties();<NEW_LINE>config.putAll(defaultConfig);<NEW_LINE>// Workaround for a known issue with RocksD... | put(StreamsConfig.COMMIT_INTERVAL_MS_CONFIG, 1); |
1,064,166 | private void jbInit() throws Exception {<NEW_LINE>this.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE);<NEW_LINE>this.setResizable(false);<NEW_LINE>this.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));<NEW_LINE>this.getContentPane().add(Box.createVerticalStrut(8), BorderLayout.NORTH);<NEW_LINE>t... | (8), BorderLayout.EAST); |
1,474,679 | final GetSessionEmbedUrlResult executeGetSessionEmbedUrl(GetSessionEmbedUrlRequest getSessionEmbedUrlRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getSessionEmbedUrlRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetri... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
632,720 | private HttpResponse tenantInvoice(RestApi.RequestContext requestContext) {<NEW_LINE>var tenantName = TenantName.from(requestContext.pathParameters().getStringOrThrow("tenant"));<NEW_LINE>var tenant = tenants.<MASK><NEW_LINE>var invoiceId = requestContext.pathParameters().getStringOrThrow("invoice");<NEW_LINE>var forma... | require(tenantName, CloudTenant.class); |
1,283,387 | protected mxRectangle revalidateState(mxCellState parentState, mxCellState state, double dx, double dy) {<NEW_LINE>mxRectangle dirty = null;<NEW_LINE>if (state != null) {<NEW_LINE>mxGraph graph = graphComponent.getGraph();<NEW_LINE>mxIGraphModel model = graph.getModel();<NEW_LINE>Object cell = state.getCell();<NEW_LINE... | dirty.getX() + dx); |
1,553,217 | protected JPanel instanceablePanel(Instanceable inst) {<NEW_LINE>JPanel panel = new JPanel(new MigLayout("fill"));<NEW_LINE>{<NEW_LINE>// Instance Count<NEW_LINE>panel.add(new JLabel(trans.get("RocketCompCfg.lbl.InstanceCount")));<NEW_LINE>IntegerModel countModel = new IntegerModel(component, "InstanceCount", 1);<NEW_L... | panel.add(separationSpinner, "growx"); |
1,093,327 | private void showNotification(String titleString, String statusString, int notificationId, boolean isOnGoing, int maximum, int progress, boolean isIndeterminate, boolean shouldForeground) {<NEW_LINE>NotificationCompat.Builder builder = new NotificationCompat.Builder(appContext, NOTIFICATION_CHANNEL_ID);<NEW_LINE>builde... | notificationId, builder.build()); |
887,450 | private void processRanges() {<NEW_LINE>if (ranges.size() == 1) {<NEW_LINE>// an optimization<NEW_LINE>Map.Entry<Double, Double<MASK><NEW_LINE>minX = rangeEntry.getValue();<NEW_LINE>maxX = rangeEntry.getKey();<NEW_LINE>} else {<NEW_LINE>// Find the biggest gap. Whenever we do, update minX & maxX for the rect opposite o... | > rangeEntry = ranges.firstEntry(); |
1,166,998 | public static void renameNonCodeUsages(@Nonnull Project project, @Nonnull NonCodeUsageInfo[] usages) {<NEW_LINE>PsiDocumentManager.getInstance(project).commitAllDocuments();<NEW_LINE>Map<Document, List<UsageOffset>> docsToOffsetsMap = new HashMap<Document, List<UsageOffset>>();<NEW_LINE>final PsiDocumentManager psiDocu... | ProperTextRange rangeInElement = usage.getRangeInElement(); |
780,467 | protected void printName0(String text) {<NEW_LINE>if (appender == null || text.length() == 0) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>if (printNameQuote) {<NEW_LINE>char c0 = text.charAt(0);<NEW_LINE>if (c0 == quote) {<NEW_LINE>this.appender.append(text);<NEW_LINE>} else if (c0 == '"' && text.charAt(text.... | this.appender.append(text); |
1,293,742 | private // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents<NEW_LINE>void initComponents() {<NEW_LINE>tvExpressions = new BeanTreeView();<NEW_LINE>lblPropertyExpressions = new javax.swing.JLabel();<NEW_LINE>jScrollPane2 = new javax.swing.JScrollPane();<NEW_LINE>tpDesc = new javax.s... | (AddPropertyDialog.class, "AddPropertyDialog.lblPropertyExpressions.text")); |
1,021,802 | final AssociateSkillWithUsersResult executeAssociateSkillWithUsers(AssociateSkillWithUsersRequest associateSkillWithUsersRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(associateSkillWithUsersRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
1,396,329 | public void create(ThreadLayoutCallback callback) {<NEW_LINE>this.callback = callback;<NEW_LINE>// View binding<NEW_LINE>loadView = findViewById(R.id.loadview);<NEW_LINE>replyButton = findViewById(R.id.reply_button);<NEW_LINE>LayoutInflater layoutInflater = LayoutInflater.from(getContext());<NEW_LINE>// Inflate ThreadL... | layout.layout_thread_error, this, false); |
1,280,908 | private static void jar(File src, String prefix, JarInfo info) throws IOException {<NEW_LINE>JarOutputStream jout = info.out;<NEW_LINE>if (src.isDirectory()) {<NEW_LINE>// create / init the zip entry<NEW_LINE>prefix = prefix + src.getName() + "/";<NEW_LINE>ZipEntry entry = new ZipEntry(prefix);<NEW_LINE>entry.setTime(s... | jar(file, prefix, info); |
884,712 | private void configureMenuItem(JMenuItem item, String containerCtx, String action, ActionProvider provider, Map context) {<NEW_LINE>// System.err.println("ConfigureMenuItem: " + containerCtx + "/" + action);<NEW_LINE>item.setName(action);<NEW_LINE><MASK><NEW_LINE>item.putClientProperty(KEY_CONTAINERCONTEXT, containerCt... | item.putClientProperty(KEY_ACTION, action); |
1,587,586 | private List<ThunkData> readThunks(NTHeader ntHeader, BinaryReader reader, long ptr, boolean isName) throws IOException {<NEW_LINE>List<ThunkData> thunkList <MASK><NEW_LINE>if (ptr == 0) {<NEW_LINE>return thunkList;<NEW_LINE>}<NEW_LINE>long thunkPtr = 0;<NEW_LINE>int offset = 0;<NEW_LINE>if (isUsingRVA()) {<NEW_LINE>th... | = new ArrayList<ThunkData>(); |
1,556,384 | public static GetTemplateResponse unmarshall(GetTemplateResponse getTemplateResponse, UnmarshallerContext _ctx) {<NEW_LINE>getTemplateResponse.setRequestId(_ctx.stringValue("GetTemplateResponse.RequestId"));<NEW_LINE>getTemplateResponse.setTemplateARN(_ctx.stringValue("GetTemplateResponse.TemplateARN"));<NEW_LINE>getTe... | (_ctx.stringValue("GetTemplateResponse.TemplateName")); |
1,108,638 | public TBigDecimal add(TBigDecimal augend, TMathContext mc) {<NEW_LINE>// operand with the largest unscaled value<NEW_LINE>TBigDecimal larger;<NEW_LINE>// operand with the smallest unscaled value<NEW_LINE>TBigDecimal smaller;<NEW_LINE>TBigInteger tempBI;<NEW_LINE>long diffScale = (long) this.scale - augend.scale;<NEW_L... | (augend).round(mc); |
129,433 | public void uploadChunk(String blockContext, long blockOffset, byte[] chunkData, long chunkOffset, boolean isAsync, final RequestProgressHandler progressHandler, final RequestCompleteHandler completeHandler) {<NEW_LINE>requestInfo.requestType = UploadRequestInfo.RequestTypeBput;<NEW_LINE>requestInfo.fileOffset = blockO... | .token.token : "")); |
1,113,518 | public void writeUTF(String s) throws IOException {<NEW_LINE>int numchars = s.length();<NEW_LINE>int numbytes = 0;<NEW_LINE>for (int i = 0; i < numchars; i++) {<NEW_LINE>int c = s.charAt(i);<NEW_LINE>if ((c >= 0x0001) && (c <= 0x007F))<NEW_LINE>numbytes++;<NEW_LINE>else if (c > 0x07FF)<NEW_LINE>numbytes += 3;<NEW_LINE>... | 0x80 | (c & 0x3F)); |
264,801 | final UpdateSafetyRuleResult executeUpdateSafetyRule(UpdateSafetyRuleRequest updateSafetyRuleRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(updateSafetyRuleRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | endClientExecution(awsRequestMetrics, request, response); |
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... | , ColumnType.TIMESTAMP, null)); |
710,264 | protected void startServer(RPCChannelInitializer channelInitializer) {<NEW_LINE>final ServerBootstrap bootstrap = new ServerBootstrap();<NEW_LINE>bootstrap.group(bossGroup, workerGroup).channel(NioServerSocketChannel.class).option(ChannelOption.SO_REUSEADDR, true).option(ChannelOption.SO_KEEPALIVE, true).option(Channel... | .getNode().getPort(); |
647,219 | public void adjustTargets(Ability ability, Game game) {<NEW_LINE>Player controller = game.getPlayer(ability.getControllerId());<NEW_LINE>if (controller == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>UUID opponentId = null;<NEW_LINE>if (game.getOpponents(controller.getId()).size() > 1) {<NEW_LINE>Target target = abilit... | getPermanent(target.getFirstTarget()); |
1,765,695 | private void updateKeywordListSettings() {<NEW_LINE>// Get the names of the current set of keyword lists.<NEW_LINE>List<KeywordList<MASK><NEW_LINE>List<String> currentListNames = new ArrayList<>();<NEW_LINE>for (KeywordList list : keywordLists) {<NEW_LINE>currentListNames.add(list.getName());<NEW_LINE>}<NEW_LINE>// Rem... | > keywordLists = keywordListsManager.getListsL(); |
292,148 | private static void addMonitoringPrefixedConfigs(final Properties config) {<NEW_LINE>if (config.containsKey("bootstrap.servers")) {<NEW_LINE>config.put(MONITORING_INTERCEPTOR_PREFIX + "bootstrap.servers", config.getProperty("bootstrap.servers"));<NEW_LINE>}<NEW_LINE>if (config.containsKey("security.protocol")) {<NEW_LI... | .getProperty(SslConfigs.SSL_ENDPOINT_IDENTIFICATION_ALGORITHM_CONFIG)); |
952,876 | public RT execute(@NonNull final Iterator<? extends IT> items) {<NEW_LINE>final boolean requiresNewTrxs = trxManager.isNull(processorCtx.getTrx());<NEW_LINE>trxConstraintsBL.saveConstraints();<NEW_LINE>final String threadTrxName = trxManager.getThreadInheritedTrxName();<NEW_LINE>try {<NEW_LINE>// If this executor will ... | ITrxConstraints trxConstraints = trxConstraintsBL.getConstraints(); |
1,807,541 | public static void main(String[] args) {<NEW_LINE>Exercise16 exercise16 = new Exercise16();<NEW_LINE>BinarySearchSymbolTable<Integer, String> binarySearchSymbolTable = exercise16.new BinarySearchSymbolTable<>();<NEW_LINE>binarySearchSymbolTable.put(5, "Value 5");<NEW_LINE>binarySearchSymbolTable.put(1, "Value 1");<NEW_... | binarySearchSymbolTable.put(99, "Value 99"); |
295,678 | void initSimpleEdge_(SweepComparator.SimpleEdge se, int vertex) {<NEW_LINE>se.m_segment = m_shape.getSegment(vertex);<NEW_LINE>se.m_b_curve = se.m_segment != null;<NEW_LINE>if (!se.m_b_curve) {<NEW_LINE>m_shape.queryLineConnector(vertex, se.m_line);<NEW_LINE>se.m_segment = se.m_line;<NEW_LINE>se.m_env.setCoordsNoNaN_(s... | se.m_line.getEndX()); |
1,678,594 | public void processNewResult(Object result) {<NEW_LINE>Database db = ResultUtil.findDatabase(result);<NEW_LINE>boolean nonefound = true;<NEW_LINE>List<OutlierResult> oresults = OutlierResult.getOutlierResults(result);<NEW_LINE>List<OrderingResult> orderings = ResultUtil.getOrderingResults(result);<NEW_LINE>// Outlier r... | filterResults(result, Database.class); |
198,580 | private static String fromUse(VariableTree tree, VisitorState state) {<NEW_LINE>VarSymbol sym = getSymbol(tree);<NEW_LINE>ImmutableList.Builder<TreePath> usesBuilder = ImmutableList.builder();<NEW_LINE>new TreePathScanner<Void, Void>() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public Void visitIdentifier(IdentifierTree t... | getArguments().get(0); |
1,339,549 | public // -------------------------------------------------------------<NEW_LINE>AwsProxyRequestBuilder alb() {<NEW_LINE>this.request.setRequestContext(new AwsProxyRequestContext());<NEW_LINE>this.request.getRequestContext().setElb(new AlbContext());<NEW_LINE>this.request.getRequestContext().getElb().setTargetGroupArn(... | ).replaceAll("%2C", ","); |
1,524,612 | private static Set<String> findDetectedObjectTypes(Optional<NAWelcomeEvent> eventOptional) {<NEW_LINE>Set<String> detectedObjectTypes = new TreeSet<>();<NEW_LINE>if (!eventOptional.isPresent()) {<NEW_LINE>return detectedObjectTypes;<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>if (NAWebhookCameraEvent.EventTypeEnum.MOVEMENT.toS... | NAWelcomeEvent event = eventOptional.get(); |
1,413,048 | public static boolean shouldRunAtThatTime(long now, String startTime, String endTime, Timestamp nextRunningTime) {<NEW_LINE>String[] startTimeSplit = startTime.split(":");<NEW_LINE>String[] endTimeSplit = endTime.split(":");<NEW_LINE>assert startTimeSplit.length == 2;<NEW_LINE>assert endTimeSplit.length == 2;<NEW_LINE>... | 60 + startTimeMin) * 60 * 1000; |
943,516 | public ListServiceProfilesResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ListServiceProfilesResult listServiceProfilesResult = new ListServiceProfilesResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement()... | JsonToken token = context.getCurrentToken(); |
161,614 | private QueryWrapper processComparison(ComparisonExpression compareExp, QueryState state) {<NEW_LINE>String field = getVariableName(compareExp.getLeft());<NEW_LINE>FieldAndType fat = getFieldAndType(field, state);<NEW_LINE>field = fat.getFieldName();<NEW_LINE>if (compareExp.getRight() instanceof QualifiedNameReference ... | get(i).getSource(); |
1,103,112 | public final int read(byte[] buffer, int offset, int length) throws IOException {<NEW_LINE>Assertions.checkState(sourceOpened);<NEW_LINE>while (true) {<NEW_LINE>FakeData fakeData = Util.castNonNull(this.fakeData);<NEW_LINE>if (currentSegmentIndex == fakeData.getSegments().size() || bytesRemaining == 0) {<NEW_LINE>retur... | current.exception).fillInStackTrace(); |
1,555,595 | protected void convertElementToJson(ObjectNode elementNode, ObjectNode propertiesNode, ActivityProcessor processor, BaseElement baseElement, CmmnModel cmmnModel, CmmnJsonConverterContext converterContext) {<NEW_LINE>ProcessTask processTask = (ProcessTask) ((PlanItem) baseElement).getPlanItemDefinition();<NEW_LINE>if (p... | propertiesNode.putObject(CmmnStencilConstants.PROPERTY_PROCESS_IN_PARAMETERS); |
860,218 | private Document loadDocument(ArtifactInfoHolder info, MavenEmbedder embedder) {<NEW_LINE>if (info.getArtifactId() != null && info.getGroupId() != null && info.getVersion() != null) {<NEW_LINE>// NOI18N<NEW_LINE>Artifact art = embedder.createArtifact(info.getGroupId(), info.getArtifactId(), info.<MASK><NEW_LINE>String ... | getVersion(), null, "jar"); |
1,044,507 | public static boolean hasInterestingMethod(ConstantPool cp, Collection<MethodDescriptor> methods) {<NEW_LINE>for (Constant c : cp.getConstantPool()) {<NEW_LINE>if (c instanceof ConstantMethodref || c instanceof ConstantInterfaceMethodref) {<NEW_LINE>ConstantCP desc = (ConstantCP) c;<NEW_LINE>ConstantNameAndType nameAnd... | getClassIndex(), Const.CONSTANT_Class); |
544,227 | protected void createFunctions() {<NEW_LINE>// NOI18N<NEW_LINE>LOGGER.log(Level.FINE, "Initializing functions in {0}", this);<NEW_LINE>Map<String, Function> newProcedures = new LinkedHashMap<String, Function>();<NEW_LINE>try {<NEW_LINE>ResultSet rs = // NOI18N<NEW_LINE>MetadataUtilities.// NOI18N<NEW_LINE>getFunctions(... | functions = Collections.unmodifiableMap(newProcedures); |
709,912 | private void parseStrategyRoute(Element element, StrategyReleaseEntity strategyReleaseEntity) {<NEW_LINE>List<StrategyRouteEntity> strategyRouteEntityList = strategyReleaseEntity.getStrategyRouteEntityList();<NEW_LINE>if (strategyRouteEntityList != null) {<NEW_LINE>throw new DiscoveryException("Allow only one element["... | Element childElement = elementIterator.next(); |
1,497,374 | private void validateFeature(FeatureBuilder builder, TestSuite suite) {<NEW_LINE>checkValue(suite, builder, SUBSYSTEM_MANIFEST_VERSION, "1");<NEW_LINE>checkValue(suite, builder, IBM_FEATURE_VERSION, "2");<NEW_LINE>checkValue(suite, builder, SUBSYSTEM_TYPE, OSGI_SUBSYSTEM_FEATURE);<NEW_LINE>checkSet(suite, builder, SUBS... | builder, SUBSYSTEM_LOCALIZATION, "OSGI-INF/l10n/" + symbolicName); |
1,602,599 | public long folderSize(Context context) {<NEW_LINE>long size = 0l;<NEW_LINE>switch(mode) {<NEW_LINE>case SFTP:<NEW_LINE>final Long returnValue = SshClientUtils.<Long>execute(new SFtpClientTemplate<Long>(path) {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public Long execute(SFTPClient client) throws IOException {<NEW_LINE>re... | folderSize(getFile(), null); |
1,367,121 | public OutlierResult run(Relation<? extends NumberVector> relation) {<NEW_LINE>final DBIDs ids = relation.getDBIDs();<NEW_LINE>ArrayList<ArrayDBIDs> subspaceIndex = buildOneDimIndexes(relation);<NEW_LINE>Set<HiCSSubspace> subspaces = calculateSubspaces(relation, subspaceIndex, rnd.getSingleThreadedRandom());<NEW_LINE>i... | results = new ArrayList<>(); |
608,812 | public void updateVmPriorityOnHost(HostInventory inv) {<NEW_LINE>List<String> vmUuids = Q.New(VmInstanceVO.class).select(VmInstanceVO_.uuid).eq(VmInstanceVO_.hostUuid, inv.getUuid()).eq(VmInstanceVO_.state, VmInstanceState.Running).eq(VmInstanceVO_.type, VmInstanceConstant.USER_VM_TYPE).listValues();<NEW_LINE>if (vmUui... | priorityConfigStructs = new ArrayList<>(); |
1,824,029 | public static void addFragment(FragmentActivity fragmentActivity, Fragment fragmentToAdd, String fragmentTag) {<NEW_LINE>if (fragmentActivity.isFinishing() || (fragmentActivity instanceof ConversationActivity && ((ConversationActivity) fragmentActivity).isActivityDestroyed)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (U... | singleFragmentTransitionResourceIds.popEnterTransitionFileResourceId, singleFragmentTransitionResourceIds.popExitTransitionFileResourceId); |
1,497,285 | public static Calendar strToCalendar(String val, String format) {<NEW_LINE>MysqlDateTime mysqlTime = strToMySQLTime(val, format);<NEW_LINE>if (mysqlTime == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>Calendar cal = Calendar.getInstance();<NEW_LINE>cal.clear();<NEW_LINE>cal.set(Calendar.YEAR, (int) mysqlTime.getYe... | int) mysqlTime.getSecond()); |
85,135 | final ListTrialComponentsResult executeListTrialComponents(ListTrialComponentsRequest listTrialComponentsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listTrialComponentsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | false), new ListTrialComponentsResultJsonUnmarshaller()); |
1,006,672 | public Object start(IApplicationContext context) throws Exception {<NEW_LINE>int port = -1;<NEW_LINE>try {<NEW_LINE>// Is an there any other instance running ?<NEW_LINE>port = PortManager.getRunningInstancePort();<NEW_LINE>if (port < 0) {<NEW_LINE>// Another instance is not running; launch the Product's application<NEW... | CommandlineLauncherPlugin.getDefault(), e); |
1,013,706 | synchronized public Props selectRampPropsForJob(@NotNull final String jobId, @NotNull final String jobType) {<NEW_LINE>Props selectedProps = new Props();<NEW_LINE>for (Map.Entry<String, Props> rampItem : rampPropsMap.entrySet()) {<NEW_LINE>String rampId = rampItem.getKey();<NEW_LINE>Props rampValue = rampItem.getValue(... | executableRampDependencyMap.getDefaultValue(dependency))); |
1,829,432 | public long preAppend(int len, boolean useBlank) {<NEW_LINE>MmapFile mappedFile = getLastMappedFile();<NEW_LINE>if (null == mappedFile || mappedFile.isFull()) {<NEW_LINE>mappedFile = getLastMappedFile(0);<NEW_LINE>}<NEW_LINE>if (null == mappedFile) {<NEW_LINE>logger.error("Create mapped file for {}", storePath);<NEW_LI... | logger.error("Create mapped file for {}", storePath); |
516,050 | private Reader transform(Reader in) throws IOException {<NEW_LINE>if (jqueryFiles == null || releaseNotesJavascript == null || baseCss == null || releaseNotesCss == null) {<NEW_LINE>throw new GradleException("filter isn't ready to transform");<NEW_LINE>}<NEW_LINE>Document document = Jsoup.parse(CharStreams.toString(in)... | StringReader(document.toString()); |
981,525 | public void onClick(View v) {<NEW_LINE>// If popup is not showing => emoji keyboard is not visible, we need to show it<NEW_LINE>if (!popup.isShowing()) {<NEW_LINE>// If keyboard is visible, simply show the emoji popup<NEW_LINE>if (popup.isKeyBoardOpen()) {<NEW_LINE>popup.showAtBottom();<NEW_LINE>changeEmojiKeyboardIcon... | emojiButton, R.drawable.ic_keyboard_black_24dp); |
614,228 | public static DescribeChangeOrderResponse unmarshall(DescribeChangeOrderResponse describeChangeOrderResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeChangeOrderResponse.setRequestId<MASK><NEW_LINE>describeChangeOrderResponse.setMessage(_ctx.stringValue("DescribeChangeOrderResponse.Message"));<NEW_LINE>describeCha... | (_ctx.stringValue("DescribeChangeOrderResponse.RequestId")); |
1,749,446 | /*<NEW_LINE>* <requestTiming slowRequestThreshold="9s" hungRequestThreshold="20s"><NEW_LINE>* <timing<NEW_LINE>* eventType="websphere.servlet.service"<NEW_LINE>* slowRequestThreshold="5s"<NEW_LINE>* hungRequestThreshold="7s"><NEW_LINE>* </timing><NEW_LINE>* </requestTiming><NEW_LINE>*/<NEW_LINE>@Test<NEW_LINE>@Mode(Tes... | writeLogMsg(Level.INFO, "$$$$ -----> Retry because no slow request warning found!"); |
1,034,630 | public void deletePublicIpById(String id) {<NEW_LINE>String resourceGroupName = <MASK><NEW_LINE>if (resourceGroupName == null) {<NEW_LINE>throw logger.logExceptionAsError(new IllegalArgumentException(String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));<NEW_LINE>}<NEW_LINE>St... | Utils.getValueFromIdByName(id, "resourceGroups"); |
1,697,277 | public void pressed(SWTSkinButtonUtility buttonUtility, SWTSkinObject skinObject, int stateMask) {<NEW_LINE>String sSavePath;<NEW_LINE>String sDefPath = cmbDataDir.getText();<NEW_LINE>File f = FileUtil.newFile(sDefPath);<NEW_LINE>if (sDefPath.length() > 0) {<NEW_LINE>while (!f.exists()) {<NEW_LINE>f = f.getParentFile()... | getShell(), SWT.SYSTEM_MODAL); |
990,471 | private void finishScene(String tag) {<NEW_LINE>FragmentManager fragmentManager = getSupportFragmentManager();<NEW_LINE>// Get scene<NEW_LINE>Fragment scene = fragmentManager.findFragmentByTag(tag);<NEW_LINE>if (scene == null) {<NEW_LINE>Log.<MASK><NEW_LINE>return;<NEW_LINE>}<NEW_LINE>// Get scene index<NEW_LINE>int in... | e(TAG, "finishScene: Can't find scene by tag: " + tag); |
149,257 | // Public Instance Methods ----------------------------------------------------------------<NEW_LINE>public boolean sendData() {<NEW_LINE>boolean isSuccess = false;<NEW_LINE>if (isWaitForCallback) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>isWaitForCallback = true;<NEW_LINE>LOG.info("Sending '" + data.length + "' byt... | (meshProxy, data, callbackResult)); |
1,284,471 | public SpanContext fromByteArray(byte[] bytes) throws SpanContextParseException {<NEW_LINE>checkNotNull(bytes, "bytes");<NEW_LINE>if (bytes.length == 0 || bytes[0] != VERSION_ID) {<NEW_LINE>throw new SpanContextParseException("Unsupported version.");<NEW_LINE>}<NEW_LINE>if (bytes.length < REQUIRED_FORMAT_LENGTH) {<NEW_... | traceId, spanId, traceOptions, TRACESTATE_DEFAULT); |
536,297 | public boolean checkIfItemOutdated(IndexItem item, java.text.DateFormat format) {<NEW_LINE>boolean outdated = false;<NEW_LINE>String sfName = item.getTargetFileName();<NEW_LINE>String indexActivatedDate = indexActivatedFileNames.get(sfName);<NEW_LINE>String indexFilesDate = indexFileNames.get(sfName);<NEW_LINE>item.set... | long itemSize = item.getContentSize(); |
1,173,749 | final ListDeliverabilityTestReportsResult executeListDeliverabilityTestReports(ListDeliverabilityTestReportsRequest listDeliverabilityTestReportsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listDeliverabilityTestReportsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionC... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "ListDeliverabilityTestReports"); |
1,106,036 | private Optional<String> read(Consumer<ParsingContext> rule) {<NEW_LINE>StringBuilder ret = new StringBuilder();<NEW_LINE>parse: while (true) {<NEW_LINE>if (input.length() < pos + 1) {<NEW_LINE>break;<NEW_LINE>}<NEW_LINE>ch = input.charAt(pos);<NEW_LINE>state = State.WantMore;<NEW_LINE>length = ret.length();<NEW_LINE>r... | fail("Character " + printable + " was not acceptable"); |
466,056 | public Request<StopInstancesRequest> marshall(StopInstancesRequest stopInstancesRequest) {<NEW_LINE>if (stopInstancesRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<StopInstancesRequest> request = new DefaultRequest<StopInstancesRequest>(... | request.setHttpMethod(HttpMethodName.POST); |
1,686,690 | private List<String> listProcessPlatformBundle(Business business, Model model) throws Exception {<NEW_LINE>EntityManager em = business.entityManagerContainer().get(WorkCompleted.class);<NEW_LINE>CriteriaBuilder cb = em.getCriteriaBuilder();<NEW_LINE>CriteriaQuery<String> cq = <MASK><NEW_LINE>Root<WorkCompleted> root = ... | cb.createQuery(String.class); |
940,468 | 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.getApplicationN... | applicationDetail.getApplicationARN(), APPLICATIONARN_BINDING); |
124,227 | public Request<UpdateIndexingConfigurationRequest> marshall(UpdateIndexingConfigurationRequest updateIndexingConfigurationRequest) {<NEW_LINE>if (updateIndexingConfigurationRequest == null) {<NEW_LINE>throw new AmazonClientException("Invalid argument passed to marshall(UpdateIndexingConfigurationRequest)");<NEW_LINE>}<... | ThingIndexingConfiguration thingIndexingConfiguration = updateIndexingConfigurationRequest.getThingIndexingConfiguration(); |
1,666,995 | public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {<NEW_LINE>final View view = inflater.inflate(R.layout.page_n, container, false);<NEW_LINE>page = getArguments().getInt(POS);<NEW_LINE>text = (TextView) view.findViewById(R.id.text1);<NEW_LINE>image = (PageImaveView) view.... | getPriority(), "counter", count); |
346,575 | private ArgumentBuilder buildArgs(StringToStringMap values, Interface modelItem) {<NEW_LINE><MASK><NEW_LINE>values.put(XSBTARGET, Tools.ensureDir(values.get(XSBTARGET), ""));<NEW_LINE>values.put(SRCTARGET, Tools.ensureDir(values.get(SRCTARGET), ""));<NEW_LINE>builder.startScript("scomp", ".cmd", "");<NEW_LINE>builder.a... | ArgumentBuilder builder = new ArgumentBuilder(values); |
520,992 | @Path("{username}/rules")<NEW_LINE>@Operation(summary = "Create a new rule", responses = { @ApiResponse(responseCode = "200", description = "OK") })<NEW_LINE>public Response postNewRule(@Context UriInfo uri, @PathParam("username") @Parameter(description = "username") String username, String body) {<NEW_LINE>if (!userMa... | uri, HueResponse.INVALID_JSON, "Invalid request: No name or actions or conditons!"); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.