idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,216,804 | public FlowRegistrar stubFlowRegistrar(ConfigurableListableBeanFactory beanFactory, BatchStubRunner batchStubRunner) {<NEW_LINE>Map<StubConfiguration, Collection<Contract>> contracts = batchStubRunner.getContracts();<NEW_LINE>for (Entry<StubConfiguration, Collection<Contract>> entry : contracts.entrySet()) {<NEW_LINE>S... | > value = entry.getValue(); |
1,048,265 | private void consumeClassOrRecordHeaderName1(boolean isRecord) {<NEW_LINE>TypeDeclaration typeDecl = new TypeDeclaration(this.compilationUnit.compilationResult);<NEW_LINE>if (this.nestedMethod[this.nestedType] == 0) {<NEW_LINE>if (this.nestedType != 0) {<NEW_LINE>typeDecl.bits |= ASTNode.IsMemberType;<NEW_LINE>}<NEW_LI... | .intStack[this.intPtr--]; |
1,541,896 | // Fully invalidate user including consents and federatedIdentity links.<NEW_LINE>public void fullUserInvalidation(String userId, String username, String email, String realmId, boolean identityFederationEnabled, Map<String, String> federatedIdentities, Set<String> invalidations) {<NEW_LINE>userUpdatedInvalidations(user... | (UserCacheSession.getConsentCacheKey(userId)); |
1,403,830 | public int compare(final Object o1, final Object o2) {<NEW_LINE>if (o1 instanceof Model && o2 instanceof Model) {<NEW_LINE>final Model c1 = (Model) o1;<NEW_LINE><MASK><NEW_LINE>return c1.getName().compareTo(c2.getName());<NEW_LINE>} else if (o1 instanceof Module && o2 instanceof Module) {<NEW_LINE>final Module m1 = (Mo... | final Model c2 = (Model) o2; |
413,403 | public void replaceUserOnSession(final String targetName, final UserSession session) {<NEW_LINE>final String policiesString = session.getOptions().getOption(ExecConstants.IMPERSONATION_POLICY_VALIDATOR);<NEW_LINE>if (!policiesString.equals(this.policiesString)) {<NEW_LINE>try {<NEW_LINE>impersonationPolicies = deserial... | , targetName).build(logger); |
1,160,144 | public static CloneNacosConfigResponse unmarshall(CloneNacosConfigResponse cloneNacosConfigResponse, UnmarshallerContext _ctx) {<NEW_LINE>cloneNacosConfigResponse.setRequestId(_ctx.stringValue("CloneNacosConfigResponse.RequestId"));<NEW_LINE>cloneNacosConfigResponse.setHttpStatusCode(_ctx.integerValue("CloneNacosConfig... | (_ctx.booleanValue("CloneNacosConfigResponse.Success")); |
97,526 | public static String rightPad(final String str, final int size, String padStr) {<NEW_LINE>if (str == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>if (StringUtils.isEmpty(padStr)) {<NEW_LINE>padStr = " ";<NEW_LINE>}<NEW_LINE>int padLen = padStr.length();<NEW_LINE><MASK><NEW_LINE>int pads = size - strLen;<NEW_LINE>i... | int strLen = str.length(); |
1,843,035 | protected Object computeValueAt(int row, int col) {<NEW_LINE>int index = ((Integer) filteredToFullIndexes.get<MASK><NEW_LINE>switch(col) {<NEW_LINE>case 0:<NEW_LINE>return sortedClassNames[index];<NEW_LINE>case 1:<NEW_LINE>// return new Long(totalAllocObjectsSize[index]);<NEW_LINE>return (nTotalBytes == 0) ? 0 : (doubl... | (row)).intValue(); |
802,188 | public MetricData unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>MetricData metricData = new MetricData();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = context.getCurrentToken();<NEW_LINE>if (tok... | String currentParentElement = context.getCurrentParentElement(); |
1,387,755 | private Expr parseSimpleExpr() {<NEW_LINE>if (isSimpleExprDisabled()) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>int length = _stringValue.length();<NEW_LINE>int index = _index + 1;<NEW_LINE>int offset = index;<NEW_LINE>StringBuilder expr = new StringBuilder();<NEW_LINE>for (; index < length; index++) {<NEW_LINE>char ... | c = _stringValue.charAt(index); |
1,606,744 | private BOMLine toCostingBOMLine(final I_PP_Order_BOMLine orderBOMLineRecord, final PPOrderCosts orderCosts) {<NEW_LINE>final ProductId productId = ProductId.ofRepoId(orderBOMLineRecord.getM_Product_ID());<NEW_LINE>final AttributeSetInstanceId asiId = AttributeSetInstanceId.ofRepoIdOrNone(orderBOMLineRecord.getM_Attrib... | throw new AdempiereException("Component type not supported: " + componentType); |
1,840,233 | public ConfirmCustomerAgreementResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ConfirmCustomerAgreementResult confirmCustomerAgreementResult = new ConfirmCustomerAgreementResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalD... | String currentParentElement = context.getCurrentParentElement(); |
1,476,235 | public static Image createFromRGB(int[] argb, int width, int height, boolean jpeg) {<NEW_LINE>Image i = Image.<MASK><NEW_LINE>ImageIO io = ImageIO.getImageIO();<NEW_LINE>if (io != null) {<NEW_LINE>String format;<NEW_LINE>if (jpeg) {<NEW_LINE>if (!io.isFormatSupported(ImageIO.FORMAT_JPEG)) {<NEW_LINE>return i;<NEW_LINE>... | createImage(argb, width, height); |
1,086,744 | public TypeSpec poetClass() {<NEW_LINE>TypeSpec.Builder builder = TypeSpec.classBuilder(className()).addModifiers(PUBLIC, FINAL).addJavadoc(documentation()).addAnnotation(SdkInternalApi.class).addAnnotation(AnnotationSpec.builder(Generated.class).addMember("value", "$S", "software.amazon.awssdk:codegen").build()).addMe... | .addField(addHttpDefaultsFieldForMode(entry)); |
1,381,345 | protected Component buildToolbar() {<NEW_LINE>JXToolBar toolbar = UISupport.createToolbar();<NEW_LINE>// TODO: the action should be disabled by default if the corresponding component (button)<NEW_LINE>// is supposed to be disabled by default.<NEW_LINE>if (showEditableButtons) {<NEW_LINE>toolbar.add(UISupport.createTool... | .createToolbarButton(movePropertyDownAction, false)); |
403,532 | public void run(RegressionEnvironment env) {<NEW_LINE>RegressionPath path = new RegressionPath();<NEW_LINE><MASK><NEW_LINE>String[] fields = new String[] { "val0", "val1" };<NEW_LINE>env.compileDeploy("@Name('s0') context SegmentedByString " + "select intPrimitive as val0, prior(1, intPrimitive) as val1 from SupportBea... | env.compileDeploy("@Name('context') @public create context SegmentedByString partition by theString from SupportBean", path); |
1,352,145 | private void drawBeforeAfterPath(Canvas canvas, RotatedTileBox tb) {<NEW_LINE>canvas.rotate(-tb.getRotate(), tb.getCenterPixelX(), tb.getCenterPixelY());<NEW_LINE>List<TrkSegment> before = editingCtx.getBeforeSegments();<NEW_LINE>List<TrkSegment> after = editingCtx.getAfterSegments();<NEW_LINE>if (before.size() > 0 || ... | pt.lat, pt.lon); |
79,025 | public boolean save() {<NEW_LINE>m_saveErrorMessage = null;<NEW_LINE>log.info("BP.Value=" + m_bp.getValue() + ", Name=" + m_bp.getName());<NEW_LINE>try {<NEW_LINE>// check if BPartner exists ***********************************<NEW_LINE>if (m_bp.getC_BPartner_ID() == 0) {<NEW_LINE>String sql = "SELECT * FROM C_BPartner ... | setC_Location_ID(m_loc.getC_Location_ID()); |
1,434,395 | final UntagResourceResult executeUntagResource(UntagResourceRequest untagResourceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(untagResourceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.Clien... | addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig); |
1,716,960 | protected void addObjectModifyActions(DBRProgressMonitor monitor, DBCExecutionContext executionContext, List<DBEPersistAction> actionList, ObjectChangeCommand command, Map<String, Object> options) throws DBException {<NEW_LINE>final GenericTableColumn column = command.getObject();<NEW_LINE>String prefix = "ALTER TABLE ... | + column.getDefaultValue())); |
726,020 | static // some sources have Monday is holiday when Tuesday is, and Friday is holiday when Thursday is (not applying this)<NEW_LINE>ImmutableHolidayCalendar generateParis() {<NEW_LINE>List<LocalDate> holidays = new ArrayList<>(2000);<NEW_LINE>for (int year = 1950; year <= 2099; year++) {<NEW_LINE>// new year<NEW_LINE>ho... | (1999, 12, 31)); |
485,863 | public static Usericon createTwitchBadge(String id, String version, String urlString, String url2String, String channel, String title, String description, String clickUrl) {<NEW_LINE>try {<NEW_LINE>URL url = new URL(Helper.checkHttpUrl(urlString));<NEW_LINE>URL url2 = new URL(Helper.checkHttpUrl(url2String));<NEW_LINE>... | b.setBadgeType(id, version); |
95,842 | final DescribeConnectorProfilesResult executeDescribeConnectorProfiles(DescribeConnectorProfilesRequest describeConnectorProfilesRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeConnectorProfilesRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequest... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
940,649 | private void deleteOnSize() throws IOException {<NEW_LINE>final Set<String> nonTerminalJobIds = new HashSet<>();<NEW_LINE>final Sets.SetView<JobStatus> nonTerminalStatuses = Sets.difference(Set.of(JobStatus.values()), JobStatus.TERMINAL_STATUSES);<NEW_LINE>for (final JobStatus nonTerminalStatus : nonTerminalStatuses) {... | final FileTime ft1 = getFileTime(o1); |
178,689 | private void changeSortOrder() {<NEW_LINE>int position = mOrderByAdapter.getSelectedPosition();<NEW_LINE>// check if there are any fields in the order by recycler view<NEW_LINE>if (position >= 0 && position < mOrderByList.size()) {<NEW_LINE>// get the field and order and remove it from recycler view<NEW_LINE>String fie... | Toast.LENGTH_LONG).show(); |
27,867 | public static void processLists(Project project, boolean explicitly, Collection<LocalChangeList> allLists, ChangeListRemoveConfirmation ask) {<NEW_LINE>List<String> allIds = ContainerUtil.map(allLists, LocalChangeList::getId);<NEW_LINE>Set<String> confirmationAsked = new HashSet<>();<NEW_LINE>Set<String> doNotRemove = ... | it)), manager::getChangeList); |
1,015,696 | public double distance(NumberVector v1, NumberVector v2) {<NEW_LINE>// Dimensionality, and last valid value in second vector:<NEW_LINE>final int dim1 = v1.getDimensionality(), dim2 = v2.getDimensionality();<NEW_LINE>final int m2 = dim2 - 1;<NEW_LINE>// bandsize is the maximum allowed distance to the diagonal<NEW_LINE>f... | , v2.doubleValue(j)); |
266,355 | public void onUpdateMoveHelper() {<NEW_LINE>if (!entity.getNavigator().noPath()) {<NEW_LINE>double xDelta = posX - entity.posX;<NEW_LINE>double yDelta = posY - entity.posY;<NEW_LINE>double zDelta = posZ - entity.posZ;<NEW_LINE>float moveFactor = 1;<NEW_LINE>float moveSpeed = (float) (speed * entity.getEntityAttribute(S... | Math.max(0.1, yDelta); |
1,175,354 | public void updateRequest(final boolean force, boolean useCache, @javax.annotation.Nullable final ScrollToPolicy scrollToChangePolicy) {<NEW_LINE>if (isDisposed())<NEW_LINE>return;<NEW_LINE>final Change change = myCurrentChange;<NEW_LINE>DiffRequest cachedRequest = loadRequestFast(change, useCache);<NEW_LINE>if (cached... | request = loadRequest(change, indicator); |
1,224,999 | public static final void create(final ITool tool) {<NEW_LINE>final CostModelCreator collector = new CostModelCreator(tool);<NEW_LINE>// TODO Start from the ModuleNode similar to how the Explorer works. It is<NEW_LINE>// unclear how to lookup the corresponding subtree in the global CM graph<NEW_LINE>// in getNextState a... | cms.get(nextAction.pred); |
621,250 | private void populateFuncSignature(BLangFunction bLFunction, FunctionSignatureNode funcSignature) {<NEW_LINE>// Set Parameters<NEW_LINE>for (ParameterNode child : funcSignature.parameters()) {<NEW_LINE>SimpleVariableNode param = (SimpleVariableNode) child.apply(this);<NEW_LINE>if (child instanceof RestParameterNode) {<... | applyAll(returnType.annotations()); |
709,016 | public LaunchDetails unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>LaunchDetails launchDetails = new LaunchDetails();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<... | class).unmarshall(context)); |
1,282,558 | private void createSubmenu(JMenu menu) {<NEW_LINE>Node[] nodes = getActivatedNodes();<NEW_LINE>if (nodes != null && nodes.length == 1) {<NEW_LINE>RADComponentCookie radCookie = nodes[0].getCookie(RADComponentCookie.class);<NEW_LINE>RADComponent comp = (radCookie != null) ? radCookie.getRADComponent() : null;<NEW_LINE>i... | add(it.previous()); |
773,835 | void rewrapConnection(Connection connection) throws IllegalAccessException {<NEW_LINE>assert connection != null;<NEW_LINE>if (jboss && connection.getClass().getSimpleName().startsWith("WrappedConnection")) {<NEW_LINE>// pour jboss,<NEW_LINE>// result instance de WrappedConnectionJDK6 ou WrappedConnectionJDK5<NEW_LINE>/... | JdbcWrapperHelper.getFieldValue(connection, conFieldName); |
1,609,218 | public static MapValue convert(ExecutionPlanDescription plan) {<NEW_LINE>boolean hasProfilerStatistics = plan.hasProfilerStatistics();<NEW_LINE>int size = hasProfilerStatistics ? 10 : 4;<NEW_LINE>MapValueBuilder out = new MapValueBuilder(size);<NEW_LINE>out.add("operatorType", utf8Value(plan.getName()));<NEW_LINE>out.a... | (profile.getTime())); |
684,715 | public GeneratorResult generateJava() {<NEW_LINE>CompilationUnit cu = new CompilationUnit();<NEW_LINE>if (!pkg.isEmpty()) {<NEW_LINE>cu.setPackageDeclaration(pkg);<NEW_LINE>}<NEW_LINE>ClassOrInterfaceDeclaration clz = cu.addClass(className);<NEW_LINE>clz.addAnnotation(new SingleMemberAnnotationExpr(new Name("io.fabric8... | storage + " , served = " + served))); |
797,512 | private void printExtractBandInterleaved() {<NEW_LINE>String singleName = imageType.getSingleBandName();<NEW_LINE>String interleavedName = imageType.getInterleavedName();<NEW_LINE>out.print("\tpublic static void extractBand( " + interleavedName + " input, int band, " + singleName + " output ) {\n" + "\t\tfinal int numB... | "\t\t\t}\n" + "\t\t}\n" + "\t\t//CONCURRENT_ABOVE });\n" + "\t}\n\n"); |
1,109,559 | public void selected(MenuItem menu, Object target) {<NEW_LINE>SimpleTextEntryWindow entryWindow = new SimpleTextEntryWindow("enter.url", "enter.website");<NEW_LINE>entryWindow.prompt(new UIInputReceiverListener() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void UIInputReceiverClosed(UIInputReceiver receiver) {<NEW_L... | map.put("data_source", key); |
1,082,006 | private HdfsBlobStore createBlobstore(URI uri, String path, Settings repositorySettings) {<NEW_LINE>Configuration hadoopConfiguration = new Configuration(repositorySettings.getAsBoolean("load_defaults", true));<NEW_LINE>hadoopConfiguration.setClassLoader(HdfsRepository.class.getClassLoader());<NEW_LINE>hadoopConfigurat... | , confSettings.get(key)); |
127,363 | private void checkUpdatingExistingTestClass() {<NEW_LINE>if (tfClassName == null) {<NEW_LINE>setMessage(Bundle.MSG_UPDATE_ALL_TEST_CLASSES(), MSG_TYPE_UPDATE_ALL_TEST_CLASSES);<NEW_LINE>} else {<NEW_LINE>FileObject locationFO = getTargetFolder();<NEW_LINE>if (locationFO != null) {<NEW_LINE>String targetFolderPath = Fil... | className.substring(0, index); |
1,823,345 | protected void loadTree() {<NEW_LINE>final Map<SdkType, List<Sdk>> map = new HashMap<>();<NEW_LINE>for (Sdk sdk : mySdksModel.getModifiedSdksMap().values()) {<NEW_LINE>SdkType sdkType = (SdkType) sdk.getSdkType();<NEW_LINE>if (sdkType instanceof UnknownSdkType) {<NEW_LINE>sdkType = ourUnknownSdkType;<NEW_LINE>}<NEW_LIN... | new MyNode(configurable), groupNode); |
1,170,025 | public JsonCloseInvoiceCandidatesResponse closeInvoiceCandidates(final JsonCloseInvoiceCandidatesRequest request) {<NEW_LINE>if (request.getInvoiceCandidates().isEmpty()) {<NEW_LINE>throw new InvalidEntityException(TranslatableStrings.constant("The request's invoiceCandidates array may not be empty"));<NEW_LINE>}<NEW_L... | fromJson(request.getInvoiceCandidates()); |
855,692 | public Result doChangePassword() {<NEW_LINE>com.feth.play.module.pa.controllers.Authenticate.noCache(response());<NEW_LINE>final Form<Account.PasswordChange> filledForm = PASSWORD_CHANGE_FORM.bindFromRequest();<NEW_LINE>if (filledForm.hasErrors()) {<NEW_LINE>// User did not select whether to link or not link<NEW_LINE>r... | = filledForm.get().password; |
1,684,475 | public void validate(JobParameters theJobParameters) throws JobParametersInvalidException {<NEW_LINE>if (theJobParameters == null) {<NEW_LINE>throw new JobParametersInvalidException(Msg.code(793) + "This job needs Parameters: [readChunkSize], [jobUUID], [filters], [outputFormat], [resourceTypes]");<NEW_LINE>}<NEW_LINE>... | theJobParameters.getLong(BatchConstants.READ_CHUNK_PARAMETER); |
468,115 | public static boolean executeCommand(String message) {<NEW_LINE>if (message.isEmpty()) {<NEW_LINE>// Nothing to process<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>if (message.charAt(0) != PREFIX) {<NEW_LINE>// Incorrect prefix, won't execute anything.<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>// The in... | MinecraftClient client = MinecraftClient.getInstance(); |
1,243,339 | public int removeAllByProfileHandle(final String profileHandle, final long timeout) throws IOException, SpaceExceededException {<NEW_LINE>// first find a list of url hashes that shall be deleted<NEW_LINE>final long terminate = timeout == Long.MAX_VALUE ? Long.MAX_VALUE : (timeout > 0) ? System.currentTimeMillis() + tim... | > i = depthStack.rows(); |
95,397 | public double[] transformToDoubleValuesSV(ProjectionBlock projectionBlock) {<NEW_LINE>int numDocs = projectionBlock.getNumDocs();<NEW_LINE>if (_doubleValuesSV == null || _doubleValuesSV.length < numDocs) {<NEW_LINE>_doubleValuesSV = new double[numDocs];<NEW_LINE>}<NEW_LINE>double[] values = _arguments.get(0).transformT... | j], values[j]); |
1,616,949 | public CopyCommand unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>CopyCommand copyCommand = new CopyCommand();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE... | class).unmarshall(context)); |
968,027 | protected void parseBindingConfig(String bindingConfigs, SamsungTvBindingConfig config) throws BindingConfigParseException {<NEW_LINE>String bindingConfig = StringUtils.substringBefore(bindingConfigs, ",");<NEW_LINE>String bindingConfigTail = StringUtils.substringAfter(bindingConfigs, ",");<NEW_LINE>String[] configPart... | trim().split(":"); |
81,821 | private <T> T[] allocateNewEntries(final T[] existingEntries, final T newEntry) {<NEW_LINE>if (existingEntries != null) {<NEW_LINE>for (T input : existingEntries) {<NEW_LINE>boolean found;<NEW_LINE>if (input instanceof CatalogEntity) {<NEW_LINE>found = ((CatalogEntity) input).getName().equals(((CatalogEntity) newEntry)... | newEntries.length - 1] = newEntry; |
630,668 | public static void vertical7(Kernel1D_S32 kernel, GrayS16 input, GrayI16 output, int skip) {<NEW_LINE>final short[] dataSrc = input.data;<NEW_LINE>final short[] dataDst = output.data;<NEW_LINE>final int k1 = kernel.data[0];<NEW_LINE>final int <MASK><NEW_LINE>final int k3 = kernel.data[2];<NEW_LINE>final int k4 = kernel... | k2 = kernel.data[1]; |
82,816 | public boolean addInv(Item item) {<NEW_LINE>if (fastForward && item.getType().equals(InventoryType.TRX)) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>if (item.getType().equals(InventoryType.TRX) && trxCache.getIfPresent(item) != null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>if (item.getType().equals(InventoryType.... | item, System.currentTimeMillis()); |
1,536,953 | byte[] compile(String name, String source, CompilerSettings settings, Printer debugStream) {<NEW_LINE>String scriptName = Location.computeSourceName(name);<NEW_LINE>ScriptClassInfo scriptClassInfo <MASK><NEW_LINE>SClass root = Walker.buildPainlessTree(scriptName, source, settings);<NEW_LINE>ScriptScope scriptScope = ne... | = new ScriptClassInfo(painlessLookup, scriptClass); |
1,429,248 | public Runnable prepareForChangeDeletion(final Collection<Change> changes) {<NEW_LINE>final Map<String, LocalChangeList> lists = new HashMap<>();<NEW_LINE>final Map<<MASK><NEW_LINE>synchronized (myDataLock) {<NEW_LINE>map = myWorker.listsForChanges(changes, lists);<NEW_LINE>}<NEW_LINE>return () -> {<NEW_LINE>Applicatio... | String, List<Change>> map; |
1,158,122 | protected JFreeChart createTimeSeriesChart() throws JRException {<NEW_LINE>String timeAxisLabel = evaluateTextExpression(((JRTimeSeriesPlot) getPlot()).getTimeAxisLabelExpression());<NEW_LINE>String valueAxisLabel = evaluateTextExpression(((JRTimeSeriesPlot) getPlot()).getValueAxisLabelExpression());<NEW_LINE>ChartFact... | ? true : timeSeriesPlot.getShowLines(); |
1,508,560 | private static List<Chunk> loadHttp(String id) {<NEW_LINE>System.out.println("loading http chunk " + id);<NEW_LINE>ArrayList<Chunk> list = new ArrayList<>();<NEW_LINE>BufferedReader br = null;<NEW_LINE>try {<NEW_LINE>DownloadEntry ent = XDMApp.getInstance().getEntry(id);<NEW_LINE>if (ent == null) {<NEW_LINE>return null... | = new File(folder, id); |
149,864 | public MessagesUUIDSResponse sendMessageResultGETRequest(SyncUrl syncUrl) {<NEW_LINE>MessagesUUIDSResponse response;<NEW_LINE>String newEndPointURL = syncUrl.getUrl().concat(TASK_RESULT_URL_PARAM);<NEW_LINE>final String urlSecret = syncUrl.getSecret();<NEW_LINE>if (!TextUtils.isEmpty(urlSecret)) {<NEW_LINE>String urlSe... | " " + e.getMessage()); |
1,417,133 | private void convertMultiANewArrayInsn(MultiANewArrayInsnNode insn) {<NEW_LINE>StackFrame frame = getFrame(insn);<NEW_LINE>Operand[] out = frame.out();<NEW_LINE>Operand opr;<NEW_LINE>if (out == null) {<NEW_LINE>ArrayType t = (ArrayType) AsmUtil.toJimpleType(insn.desc, Optional.fromNullable(this.body.getMethod().getDecl... | , Arrays.asList(sizeVals)); |
595,941 | public void fmlInit(FMLInitializationEvent evt) {<NEW_LINE>NetworkRegistry.INSTANCE.registerGuiHandler(instance, new FactoryGuiHandler());<NEW_LINE>BCRegistry.INSTANCE.registerTileEntity(TileMiningWell.class, "buildcraft.factory.MiningWell", "MiningWell");<NEW_LINE>BCRegistry.INSTANCE.registerTileEntity(TileAutoWorkben... | TilePump.class, "buildcraft.factory.Pump", "net.minecraft.src.buildcraft.factory.TilePump"); |
975,928 | public boolean areAckedBookiesAdheringToPlacementPolicy(Set<BookieId> ackedBookies, int writeQuorumSize, int ackQuorumSize) {<NEW_LINE>HashSet<String> rackCounter = new HashSet<>();<NEW_LINE>int minWriteQuorumNumRacksPerWriteQuorum = Math.min(writeQuorumSize, minNumRacksPerWriteQuorum);<NEW_LINE>ReentrantReadWriteLock.... | ReadLock readLock = rwLock.readLock(); |
1,445,343 | private Invocable invokeScriptImpl(ScriptWrapper script) {<NEW_LINE>ScriptEngine se = script.getEngine().getEngine();<NEW_LINE>Writer writer = getWriters(script);<NEW_LINE>se.getContext().setWriter(writer);<NEW_LINE>// Set the script name as a context attribute - this is used for script level variables<NEW_LINE>se.getC... | getName(), ScriptContext.ENGINE_SCOPE); |
285,510 | private static void addInterfaceBgpNeighbor(Configuration c, CumulusNcluConfiguration vsConfig, BgpInterfaceNeighbor neighbor, @Nullable Long localAs, BgpVrf bgpVrf, org.batfish.datamodel.BgpProcess newProc, Warnings w) {<NEW_LINE>BgpPeerConfig<MASK><NEW_LINE>// if an interface neighbor has only one address and that ad... | .Builder<?, ?> peerConfigBuilder; |
675,130 | public String computeAddressStr(Address address) {<NEW_LINE>StringBuilder addressString = new StringBuilder();<NEW_LINE>if (address == null) {<NEW_LINE>return "";<NEW_LINE>}<NEW_LINE>if (address.getAddressL2() != null) {<NEW_LINE>addressString.append(address.getAddressL2()).append("\n");<NEW_LINE>}<NEW_LINE>if (address... | getAddressL7Country().getName()); |
313,288 | private void visitAppImpl(final Concrete.AppExpression expr, Precedence prec) {<NEW_LINE>Concrete.Expression fun = expr.getFunction();<NEW_LINE>List<Concrete.Argument> args = expr.getArguments();<NEW_LINE>if (fun instanceof Concrete.ReferenceExpression && ((ReferenceExpression) fun).getReferent() instanceof GlobalRefer... | (Concrete.AppExpression.PREC)); |
1,668,346 | private void sendServiceDiscoveryItems(final Jid server) {<NEW_LINE>mPendingServiceDiscoveries.incrementAndGet();<NEW_LINE>final IqPacket iq = new IqPacket(IqPacket.TYPE.GET);<NEW_LINE>iq.setTo(server.getDomain());<NEW_LINE>iq.query("http://jabber.org/protocol/disco#items");<NEW_LINE>this.sendIqPacket(iq, (account, pac... | asBareJid() + ": could not query disco items of " + server); |
490,734 | public void onAction(Context context, String action, Message message, Object object, Map<String, Object> replyMetadata) {<NEW_LINE>switch(action) {<NEW_LINE>case AlRichMessage.SEND_GUEST_LIST:<NEW_LINE>List<ALGuestCountModel> guestCountModels = (List<ALGuestCountModel>) object;<NEW_LINE>sendGuestListMessage(guestCountM... | ) object, getStringMap(replyMetadata)); |
1,444,062 | // ========================================<NEW_LINE>// MouseListener method(s)<NEW_LINE>// ========================================<NEW_LINE>@Override<NEW_LINE>public void mouseClicked(MouseEvent e) {<NEW_LINE>if (UIUtils.isRightMouseClick(e)) {<NEW_LINE>if (e.getSource() == runList.getJList()) {<NEW_LINE>if (runList.... | .getFile().getAbsolutePath(); |
377,396 | public void createVmDataCommandForVMs(final DomainRouterVO router, final Commands cmds, final long guestNetworkId) {<NEW_LINE>final List<UserVmVO> vms = _userVmDao.listByNetworkIdAndStates(guestNetworkId, VirtualMachine.State.Running, VirtualMachine.State.Migrating, VirtualMachine.State.Stopping);<NEW_LINE>final DataCe... | guestNetworkId, vm.getId()); |
1,319,408 | public static void main(String[] args) {<NEW_LINE>String filename = null;<NEW_LINE>int instance = -1;<NEW_LINE>boolean full = false;<NEW_LINE>if (args.length < 2) {<NEW_LINE>usage();<NEW_LINE>}<NEW_LINE>if (args.length == 2) {<NEW_LINE>filename = args[0];<NEW_LINE>instance = Integer.parseInt(args[1]);<NEW_LINE>full = f... | true, instance, HAS_CACHE_VALUE, hdc); |
1,126,117 | public Expr visitNot(Not not, PlanTranslatorContext context) {<NEW_LINE>if (not.child() instanceof InPredicate) {<NEW_LINE>InPredicate inPredicate = (InPredicate) not.child();<NEW_LINE>List<Expr> inList = inPredicate.getOptions().stream().map(e -> translate(e, context)).collect(Collectors.toList());<NEW_LINE>return new... | , context), inList, true); |
593,425 | public void testSelfInterruptingTask() throws Throwable {<NEW_LINE>FailingTask task = new FailingTask(1);<NEW_LINE>task.failByInterrupt = true;<NEW_LINE>List<Future<Integer>> futures = xsvcNoContext.invokeAll(Collections.singleton(task), TIMEOUT, TimeUnit.MILLISECONDS);<NEW_LINE>Future<Integer> future = futures.get(0);... | throw new Exception("invokeAll: Future for task that interrupts itself should not return result " + result); |
1,678,053 | final UpdateLogPatternResult executeUpdateLogPattern(UpdateLogPatternRequest updateLogPatternRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(updateLogPatternRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | addHandlerContext(HandlerContextKey.SERVICE_ID, "Application Insights"); |
595,464 | private void computeCellInfos(XWPFTableRow row) {<NEW_LINE>if (nbColumns == null) {<NEW_LINE>nbColumns = XWPFTableUtil.computeColWidths(row.getTable()).length;<NEW_LINE>}<NEW_LINE>int rowIndex = table.getRows().indexOf(row);<NEW_LINE>boolean firstRow = rowIndex == 0;<NEW_LINE>boolean lastRow = rowIndex == (table.getRow... | cellIndex = getCellIndex(cellIndex, cell); |
1,452,948 | public void run() {<NEW_LINE>// ============================================================<NEW_LINE>// Deploy to app 1 through zip deploy<NEW_LINE>System.out.<MASK><NEW_LINE>app.deploy().withPackageUri("https://raw.githubusercontent.com/Azure/azure-sdk-for-java/main/sdk/resourcemanager/azure-resourcemanager-samples/s... | println("Deploying coffeeshop.war to " + appName + " through web deploy..."); |
863,935 | private static boolean areDataSchemaEqual(JsonNode actual, JsonNode expected) {<NEW_LINE>JsonNode actualColumnNames = actual.get(FIELD_RESULT_TABLE).get(FIELD_DATA_SCHEMA).get(FIELD_COLUMN_NAMES);<NEW_LINE>JsonNode expectedColumnNames = expected.get(FIELD_RESULT_TABLE).get(FIELD_DATA_SCHEMA).get(FIELD_COLUMN_NAMES);<NE... | () + actualColumnDataTypes.toString(); |
1,039,597 | public void print_info(ObjectInfoPanel p_window, java.util.Locale p_locale) {<NEW_LINE>java.util.ResourceBundle resources = java.util.ResourceBundle.getBundle("app.freerouting.board.ObjectInfoPanel", p_locale);<NEW_LINE>p_window.append_bold(resources.getString("pin") + ": ");<NEW_LINE>p_window.append(resources.getStrin... | get_center().to_float()); |
688,200 | protected Model findMetadata(String configPath) {<NEW_LINE>if (configPath == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>// Make a temporary file manager to look for the metadata file<NEW_LINE>FileManager fm = FileManager.create();<NEW_LINE>fm.addLocatorFile();<NEW_LINE>fm.addLocatorURL();<NEW_LINE>fm.addLocatorC... | in = fm.openNoMap(uri); |
417,663 | public void emitGlobalRequestMetrics(UaaMetrics metrics) {<NEW_LINE>// global request statistics<NEW_LINE>MetricsQueue globals = JsonUtils.readValue(metrics.getGlobals(), MetricsQueue.class);<NEW_LINE>String prefix = "requests.global.";<NEW_LINE><MASK><NEW_LINE>statsDClient.gauge(prefix + "completed.time", (long) total... | RequestMetricSummary totals = globals.getTotals(); |
1,558,375 | protected Object decode(Channel channel, SocketAddress remoteAddress, Object msg) throws Exception {<NEW_LINE>FullHttpRequest request = (FullHttpRequest) msg;<NEW_LINE>Document document = documentBuilder.parse(new ByteBufferBackedInputStream(request.content().nioBuffer()));<NEW_LINE>NodeList nodes = (NodeList) messageE... | evaluate(document, XPathConstants.NODESET); |
1,342,208 | private static boolean hasOverlappingRanges(LongRange[] ranges) {<NEW_LINE>if (ranges.length == 0) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>// Copy before sorting so we don't mess with the caller's original ranges:<NEW_LINE>LongRange[] sortedRanges = new LongRange[ranges.length];<NEW_LINE>System.arraycopy(ranges, 0... | previousMax = sortedRanges[0].max; |
596,018 | private URLConnection connection(String name, boolean cacheMetadata) throws IOException {<NEW_LINE>LOG.log(Level.FINE, "metadata in {0}: {1}", new Object[] { baseURL, name });<NEW_LINE>URLConnection conn = new ConnectionBuilder().job(job).url(new URL(baseURL, Utilities.uriEncode(name))).timeout(TIMEOUT).connection();<N... | "unknown content length for " + name + " in " + baseURL); |
560,486 | private CompoundTag readChunk(int x, int z) {<NEW_LINE>try {<NEW_LINE>CompoundTag rslt = cps.chunkMap.readChunk(<MASK><NEW_LINE>if (rslt != null) {<NEW_LINE>if (rslt.contains("Level")) {<NEW_LINE>rslt = rslt.getCompound("Level");<NEW_LINE>}<NEW_LINE>// Don't load uncooked chunks<NEW_LINE>String stat = rslt.getString("S... | new ChunkPos(x, z)); |
377,823 | public void run() {<NEW_LINE>if (!myProject.isInitialized() || myProject.isDisposed())<NEW_LINE>return;<NEW_LINE>final List<VcsDirectoryMapping<MASK><NEW_LINE>final List<VcsDirectoryMapping> added = newLinkedList(copy);<NEW_LINE>added.removeAll(myDirectoryMappingWatches.keySet());<NEW_LINE>final List<VcsDirectoryMappin... | > copy = myNewMappings.getDirectoryMappings(); |
1,082,973 | public static void closeAllConsumers() {<NEW_LINE>try {<NEW_LINE>// Shutdown all consumers<NEW_LINE>synchronized (KafkaStreamLevelConsumerManager.class) {<NEW_LINE>LOGGER.info("Trying to shutdown all the kafka consumers");<NEW_LINE>Iterator<KafkaConsumer> consumerIterator = CONSUMER_FOR_CONFIG_KEY.values().iterator();<... | KafkaConsumer kafkaConsumer = consumerIterator.next(); |
504,487 | private List<AnAction> mergeConsoleActions(@Nonnull List<AnAction> actions1, @Nonnull Collection<AnAction> actions2) {<NEW_LINE>return ContainerUtil.map(actions1, action1 -> {<NEW_LINE>final AnAction action2 = ContainerUtil.find(actions2, action -> action1.getClass() == action.getClass() && StringUtil.equals(action1.ge... | action1), (ToggleAction) action2); |
471,528 | private List<String> removeImpl(final int removalCount, final boolean returnValues, final boolean forward) throws LocalDBException {<NEW_LINE>if (removalCount < 1) {<NEW_LINE>return Collections.emptyList();<NEW_LINE>}<NEW_LINE>final List<String> removalKeys = new ArrayList<>(removalCount);<NEW_LINE>final List<String> r... | ? loopPosition : loopPosition.previous(); |
1,105,547 | public int[][] dfs() {<NEW_LINE>int n = graph.length;<NEW_LINE>int[] cc = new int[n];<NEW_LINE>Arrays.fill(cc, -1);<NEW_LINE>int id = 0;<NEW_LINE>for (int i = 0; i < n; i++) {<NEW_LINE>if (cc[i] == -1) {<NEW_LINE>dfs(i, cc, id++);<NEW_LINE>}<NEW_LINE>}<NEW_LINE>int[] size = new int[id];<NEW_LINE>for (int i = 0; i < n; ... | .sort(components[i]); |
768,807 | Person parse(GroupableDslContext context, Tokens tokens) {<NEW_LINE>// person <name> [description] [tags]<NEW_LINE>if (tokens.hasMoreThan(TAGS_INDEX)) {<NEW_LINE>throw new RuntimeException("Too many tokens, expected: " + GRAMMAR);<NEW_LINE>}<NEW_LINE>if (!tokens.includes(NAME_INDEX)) {<NEW_LINE>throw new RuntimeExcepti... | description = tokens.get(DESCRIPTION_INDEX); |
1,754,379 | public static void fillRectangle(InterleavedI8 image, int value, int x0, int y0, int width, int height) {<NEW_LINE>int x1 = x0 + width;<NEW_LINE>int y1 = y0 + height;<NEW_LINE>if (x0 < 0)<NEW_LINE>x0 = 0;<NEW_LINE>if (x1 > image.width)<NEW_LINE>x1 = image.width;<NEW_LINE>if (y0 < 0)<NEW_LINE>y0 = 0;<NEW_LINE>if (y1 > i... | .stride + _x0 * image.numBands; |
788,688 | public com.amazonaws.services.ssmcontacts.model.DataEncryptionException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.ssmcontacts.model.DataEncryptionException dataEncryptionException = new com.amazonaws.services.ssmcontacts.model.DataEncryptionException(null)... | int originalDepth = context.getCurrentDepth(); |
1,097,327 | public void onChatMessage(ChatMessage event) {<NEW_LINE>if (event.getType() != ChatMessageType.GAMEMESSAGE && event.getType() != ChatMessageType.SPAM) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>// remove color and linebreaks<NEW_LINE>String chatMsg = Text.removeTags(event.getMessage());<NEW_LINE>if (chatMsg.startsWith(CHAT... | setTask(taskName, taskAmount, initialAmount); |
1,335,036 | public static CloneModelFromCommitResponse unmarshall(CloneModelFromCommitResponse cloneModelFromCommitResponse, UnmarshallerContext _ctx) {<NEW_LINE>cloneModelFromCommitResponse.setRequestId(_ctx.stringValue("CloneModelFromCommitResponse.RequestId"));<NEW_LINE>Data data = new Data();<NEW_LINE>data.setAppId(_ctx.string... | (_ctx.stringValue("CloneModelFromCommitResponse.Data.LinkModelId")); |
148,558 | void processHop() {<NEW_LINE>checkState(_steps.isEmpty(), "Steps must be empty when processHop is called");<NEW_LINE>checkState(_hops.size() == _breadcrumbs.size(), "Must have equal number of hops and breadcrumbs");<NEW_LINE>String currentNodeName = _currentNode.getName();<NEW_LINE>// Trace was received on a source int... | _steps.add(buildOriginateStep()); |
1,271,421 | public void run(RegressionEnvironment env) {<NEW_LINE>RegressionPath path = new RegressionPath();<NEW_LINE>env.compileDeploy("@public @buseventtype create objectarray schema MyEvent(c0 int)", path);<NEW_LINE>env.compileDeploy("@public create table windowAndTotal (" + "thewindow window(*) @type(MyEvent), thetotal sum(in... | , path).addListener("s0"); |
139,797 | public AlsTrainBatchOp linkFrom(BatchOperator<?>... inputs) {<NEW_LINE>final String userColName = getUserCol();<NEW_LINE>final String itemColName = getItemCol();<NEW_LINE>BatchOperator<?> in;<NEW_LINE>if (inputs.length == 1) {<NEW_LINE>in = inputs[0];<NEW_LINE>Tuple2<BatchOperator<?>, BatchOperator<?>> factors = HugeMf... | setOutputTable(model.getOutputTable()); |
1,529,419 | private void updateViewRow(OElement viewRow, OResult origin, OView view, ODatabaseDocumentInternal db) {<NEW_LINE>OStatement stm = OStatementCache.get(view.getQuery(), db);<NEW_LINE>if (stm instanceof OSelectStatement) {<NEW_LINE>OProjection projection = ((OSelectStatement) stm).getProjection();<NEW_LINE>if (projection... | viewRow.setProperty(s, value); |
1,034,529 | private boolean updateLastCallMessage(ViewHolderChatList holder, MegaChatListItem chat) {<NEW_LINE>if (holder == null || megaChatApi.getNumCalls() == 0)<NEW_LINE>return false;<NEW_LINE>MegaChatCall call = megaChatApi.getChatCall(chat.getChatId());<NEW_LINE>if (call == null || !isStatusConnected(context, chat.getChatId(... | .R.attr.textColorSecondary)); |
1,224,088 | public static List<AppClusterServerStateWrapVO> wrapToAppClusterServerState(List<ClusterUniversalStatePairVO> list) {<NEW_LINE>if (list == null || list.isEmpty()) {<NEW_LINE>return new ArrayList<>();<NEW_LINE>}<NEW_LINE>Map<String, AppClusterServerStateWrapVO> map = new HashMap<>();<NEW_LINE>Set<String> tokenServerSet ... | .getClientConfig().getServerPort(); |
1,289,785 | private void checkMappedByOneToOne(DeployBeanPropertyAssocOne<?> prop) {<NEW_LINE>// check that the mappedBy property is valid and read<NEW_LINE>// its associated join information if it is available<NEW_LINE>String mappedBy = prop.getMappedBy();<NEW_LINE>// get the mappedBy property<NEW_LINE>DeployBeanDescriptor<?> tar... | DeployTableJoin otherTableJoin = mappedAssocOne.getTableJoin(); |
842,909 | public void drawU(final UGraphic ug) {<NEW_LINE>final StringBounder stringBounder = ug.getStringBounder();<NEW_LINE>final TextBlock phalanx = getPhalanx();<NEW_LINE>final Dimension2D dimPhalanx = phalanx.calculateDimension(stringBounder);<NEW_LINE>if (drawPhalanx) {<NEW_LINE>final double posY = -getPhalanxThickness(str... | ()), p1, p2); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.