idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
829,149 | private static org.netbeans.modules.html.editor.lib.api.elements.Node findNode(org.netbeans.modules.web.webkit.debugging.api.dom.Node node, org.netbeans.modules.web.webkit.debugging.api.dom.Node domParent, org.netbeans.modules.html.editor.lib.api.elements.Node sourceParent) {<NEW_LINE>List<org.netbeans.modules.web.webk... | parentChain.add(0, parent); |
1,160,434 | public void updateFactLineFromDimension(final I_Fact_Acct fa, final AccountDimension dim) {<NEW_LINE>if (dim.getAcctSchemaId() != null) {<NEW_LINE>fa.setC_AcctSchema_ID(dim.getAcctSchemaId().getRepoId());<NEW_LINE>}<NEW_LINE>if (dim.isSegmentValueSet(AcctSegmentType.Client)) {<NEW_LINE>// fa.setAD_Client_ID(dim.getAD_C... | setC_LocFrom_ID(dim.getC_LocFrom_ID()); |
1,731,370 | public static Object typeToStream(Object iFieldValue, OType iType, final ODatabaseObject db, final ODocument iRecord) {<NEW_LINE>if (iFieldValue == null)<NEW_LINE>return null;<NEW_LINE>if (iFieldValue instanceof Proxy)<NEW_LINE>return getDocument((Proxy) iFieldValue);<NEW_LINE>if (!OType.isSimpleType(iFieldValue) || iF... | iFieldValue, iType, db, iRecord); |
503,780 | // Virtual machine image specific fluent methods<NEW_LINE>//<NEW_LINE>@Override<NEW_LINE>public VirtualMachineImpl withStoredWindowsImage(String imageUrl) {<NEW_LINE>VirtualHardDisk userImageVhd = new VirtualHardDisk();<NEW_LINE>userImageVhd.withUri(imageUrl);<NEW_LINE>this.innerModel().storageProfile().osDisk().withCr... | osDisk().withImage(userImageVhd); |
1,672,096 | public WorkspaceResource listResource(String groupId, String type) {<NEW_LINE>Group group = groupMapper.selectByPrimaryKey(groupId);<NEW_LINE>String workspaceId = group.getScopeId();<NEW_LINE>WorkspaceResource resource = new WorkspaceResource();<NEW_LINE>if (StringUtils.equals(UserGroupType.WORKSPACE, type)) {<NEW_LINE... | Criteria pc = projectExample.createCriteria(); |
304,478 | protected RecordSetInner prepareForUpdate(RecordSetInner resource) {<NEW_LINE>if (resource.soaRecord() == null) {<NEW_LINE>resource.withSoaRecord(new SoaRecord());<NEW_LINE>}<NEW_LINE>if (innerModel().soaRecord().email() != null) {<NEW_LINE>resource.soaRecord().withEmail(innerModel().soaRecord().email());<NEW_LINE>}<NE... | soaRecord().minimumTtl()); |
793,970 | public void encrypt(HybridEncryptRequest request, StreamObserver<HybridEncryptResponse> responseObserver) {<NEW_LINE>HybridEncryptResponse response;<NEW_LINE>try {<NEW_LINE>KeysetHandle publicKeysetHandle = CleartextKeysetHandle.read(BinaryKeysetReader.withBytes(request.getPublicKeyset().toByteArray()));<NEW_LINE>Hybri... | getContextInfo().toByteArray()); |
1,039,686 | private int[] createCircularMask(int shift, double radius, int[] offset) {<NEW_LINE>// if (radius<=2.0) {<NEW_LINE>// this.width= ((int)(radius+shift+0.5))*2 ;<NEW_LINE>// offset= SWGRAD;<NEW_LINE>// }<NEW_LINE>// else<NEW_LINE>this.width = (((int) (radius + shift + 0.5)) * 2) + 1;<NEW_LINE>// this.width= ((int)(radiu... | = (width / 2.0) - 0.5; |
542,451 | public boolean apply(Game game, Ability source) {<NEW_LINE>UUID opponentId = (UUID) this.getValue("PsychicSurgeryOpponent");<NEW_LINE>Player controller = game.getPlayer(source.getControllerId());<NEW_LINE>Player opponent = game.getPlayer(opponentId);<NEW_LINE>if (controller != null && opponent != null) {<NEW_LINE>Cards... | source, null, cards, game); |
1,413,456 | private Mono<Response<RedisAccessKeysInner>> regenerateKeyWithResponseAsync(String resourceGroupName, String name, RedisRegenerateKeyParameters parameters, Context context) {<NEW_LINE>if (this.client.getEndpoint() == null) {<NEW_LINE>return Mono.error(new IllegalArgumentException("Parameter this.client.getEndpoint() is... | error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.")); |
1,418,343 | Mono<Response<QueueProperties>> updateQueueWithResponse(QueueProperties queue, Context context) {<NEW_LINE>if (queue == null) {<NEW_LINE>return monoError(LOGGER, new NullPointerException("'queue' cannot be null"));<NEW_LINE>} else if (context == null) {<NEW_LINE>return monoError(LOGGER, new NullPointerException("'conte... | (response -> deserializeQueue(response)); |
1,085,702 | public void save(final OutputStream os, final Object obj) {<NEW_LINE>final EncogWriteHelper out = new EncogWriteHelper(os);<NEW_LINE>final PrgPopulation pop = (PrgPopulation) obj;<NEW_LINE>out.addSection("BASIC");<NEW_LINE>out.addSubSection("PARAMS");<NEW_LINE>out.addProperties(pop.getProperties());<NEW_LINE>out.addSub... | addColumn(mapping.getEnumType()); |
21,072 | public void generatePlacementInfoPB(CatalogEntityInfo.PlacementInfoPB.Builder placementInfoPB, Cluster cluster) {<NEW_LINE>PlacementInfo placementInfo = cluster.placementInfo;<NEW_LINE>for (PlacementCloud placementCloud : placementInfo.cloudList) {<NEW_LINE>Provider cloud = Provider.<MASK><NEW_LINE>for (PlacementRegion... | find.byId(placementCloud.uuid); |
1,158,125 | protected void buildLR0Machine() {<NEW_LINE>AssemblyProduction sp = grammar.productionsOf(grammar.getStart()).iterator().next();<NEW_LINE>AssemblyParseStateItem startItem = new AssemblyParseStateItem(sp, 0);<NEW_LINE>AssemblyParseState startState = new AssemblyParseState(grammar, startItem);<NEW_LINE>states.add(startSt... | state = states.get(curState); |
394,751 | protected void initToolbar(Toolbar toolbar, Commands commands) {<NEW_LINE>urlBox_ = new Label("");<NEW_LINE>Style style = urlBox_<MASK><NEW_LINE>style.setColor("#606060");<NEW_LINE>urlBox_.addStyleName(ThemeStyles.INSTANCE.selectableText());<NEW_LINE>urlBox_.getElement().getStyle().setMarginRight(7, Unit.PX);<NEW_LINE>... | .getElement().getStyle(); |
131,448 | public Answer execute(final GetStorageStatsCommand command, final CitrixResourceBase citrixResourceBase) {<NEW_LINE>final Connection conn = citrixResourceBase.getConnection();<NEW_LINE>try {<NEW_LINE>final Set<SR> srs = SR.getByNameLabel(conn, command.getStorageId());<NEW_LINE>if (srs.size() != 1) {<NEW_LINE>final Stri... | return new GetStorageStatsAnswer(command, msg); |
94,701 | private void displayCancellingProgressMessages() {<NEW_LINE>if (usingNetBeansGUI) {<NEW_LINE>SwingUtilities.invokeLater(() -> {<NEW_LINE>if (dataSourceIngestProgressBar != null) {<NEW_LINE>dataSourceIngestProgressBar.setDisplayName(NbBundle.getMessage(getClass(), "IngestJob.progress.dataSourceIngest.initialDisplayName"... | (getClass(), "IngestJob.progress.cancelling")); |
531,253 | // MRI: str_null_check without trailing null check (JVM arrays do not null terminate)<NEW_LINE>public static RubyString strNullCheck(IRubyObject ptr) {<NEW_LINE>final RubyString s = ptr.convertToString();<NEW_LINE>ByteList sByteList = s.getByteList();<NEW_LINE>byte[] sBytes = sByteList.unsafeBytes();<NEW_LINE>int beg =... | Encoding enc = s.getEncoding(); |
1,201,822 | public Result process(CvPipeline pipeline) throws Exception {<NEW_LINE>Mat mat = pipeline.getWorkingImage();<NEW_LINE>List<Point> <MASK><NEW_LINE>byte[] rowData = new byte[mat.cols()];<NEW_LINE>for (int row = 0, rows = mat.rows(); row < rows; row++) {<NEW_LINE>mat.get(row, 0, rowData);<NEW_LINE>for (int col = 0, cols =... | points = new ArrayList<>(); |
346,591 | private boolean remove(double x, double y, T item) {<NEW_LINE>if (this.mChildren != null) {<NEW_LINE>if (y < mBounds.midY) {<NEW_LINE>if (x < mBounds.midX) {<NEW_LINE>// top left<NEW_LINE>return mChildren.get(0).remove(x, y, item);<NEW_LINE>} else {<NEW_LINE>// top right<NEW_LINE>return mChildren.get(1).remove(x, y, it... | remove(x, y, item); |
1,252,393 | private void delegateToMethod(MethodHolder callingMethod, MethodHolder delegateMethod) {<NEW_LINE>CodeGenerator.generateMethodSignature(codeWriter, context.getNames(), callingMethod.getReference(), callingMethod.hasModifier(ElementModifier.STATIC), true);<NEW_LINE>codeWriter.println(" {").indent();<NEW_LINE>if (calling... | outdent().println("}"); |
1,481,928 | public Request<ListCallAnalyticsCategoriesRequest> marshall(ListCallAnalyticsCategoriesRequest listCallAnalyticsCategoriesRequest) {<NEW_LINE>if (listCallAnalyticsCategoriesRequest == null) {<NEW_LINE>throw new AmazonClientException("Invalid argument passed to marshall(ListCallAnalyticsCategoriesRequest)");<NEW_LINE>}<... | <ListCallAnalyticsCategoriesRequest>(listCallAnalyticsCategoriesRequest, "AmazonTranscribe"); |
1,480,035 | private List<PropertyElement> processLambdas(Index index, JSScope globals, IParseNode node, URI location, IProgressMonitor monitor) {<NEW_LINE>List<PropertyElement> result = Collections.emptyList();<NEW_LINE>try {<NEW_LINE>Object queryResult = (LAMBDAS_IN_SCOPE != null) ? LAMBDAS_IN_SCOPE.evaluate(node) : null;<NEW_LIN... | functions.size() * 11); |
1,286,167 | public String prepareReceiveMediaFrom(Participant sender) {<NEW_LINE>final String senderName = sender.getParticipantPublicId();<NEW_LINE>log.info("PARTICIPANT {}: Request to prepare receive media from {} in room {}", this.getParticipantPublicId(), senderName, this.session.getSessionId());<NEW_LINE>if (senderName.equals... | ().closingLock.readLock(); |
1,775,701 | public org.python.Object expandtabs(org.python.Object tabsize) {<NEW_LINE>int tabsize_int = 8;<NEW_LINE>if (tabsize != null) {<NEW_LINE>tabsize_int = (int) ((org.python.types.Int) tabsize).value;<NEW_LINE>}<NEW_LINE>if (this.value == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>java.lang.StringBuilder buf = new ja... | Str(buf.toString()); |
650,416 | private static void pointLookup(int block, int index, PointPrecomp p) {<NEW_LINE>// assert 0 <= block && block < PRECOMP_BLOCKS;<NEW_LINE>// assert 0 <= index && index < PRECOMP_POINTS;<NEW_LINE>int off = block * PRECOMP_POINTS * 3 * F.SIZE;<NEW_LINE>for (int i = 0; i < PRECOMP_POINTS; ++i) {<NEW_LINE>int cond = ((i ^ ... | index) - 1) >> 31; |
1,191,658 | public static TreePathHandle create(Element element, CompilationInfo info) throws IllegalArgumentException {<NEW_LINE>URL u = null;<NEW_LINE>String qualName = null;<NEW_LINE>Symbol.ClassSymbol clsSym;<NEW_LINE>if (element instanceof Symbol.ClassSymbol) {<NEW_LINE>clsSym = (Symbol.ClassSymbol) element;<NEW_LINE>} else {... | .toUri().toURL(); |
610,594 | public Map<String, Object> toMap(final String filter) {<NEW_LINE>final Map<String, Object> map = new HashMap<>();<NEW_LINE>final String prefix = filter.substring(0<MASK><NEW_LINE>if ("dos".equals(prefix)) {<NEW_LINE>map.put("hidden", isHidden());<NEW_LINE>map.put("archive", isArchive());<NEW_LINE>map.put("system", isSy... | , filter.indexOf(":")); |
959,618 | private void insert(String data) throws IoTDBConnectionException, StatementExecutionException {<NEW_LINE>String[] dataArray = data.split(",");<NEW_LINE>String device = dataArray[0];<NEW_LINE>long time = Long.parseLong(dataArray[1]);<NEW_LINE>List<String> measurements = Arrays.asList(dataArray[2].split(":"));<NEW_LINE>L... | values = new ArrayList<>(); |
953,151 | private BindableValue bindableValueFor(JsonToken token) {<NEW_LINE>if (!JsonTokenType.STRING.equals(token.getType()) && !JsonTokenType.UNQUOTED_STRING.equals(token.getType()) && !JsonTokenType.REGULAR_EXPRESSION.equals(token.getType())) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>boolean isRegularExpression = token.get... | matcher = PARAMETER_BINDING_PATTERN.matcher(tokenValue); |
1,799,941 | public static void printMountInfo(Map<String, MountPointInfo> mountTable) {<NEW_LINE>for (Map.Entry<String, MountPointInfo> entry : mountTable.entrySet()) {<NEW_LINE>String mMountPoint = entry.getKey();<NEW_LINE>MountPointInfo mountPointInfo = entry.getValue();<NEW_LINE>long capacityBytes = mountPointInfo.getUfsCapacit... | ) (100.0 * usedBytes / capacityBytes); |
1,220,653 | private Mono<Response<Void>> simulateEvictionWithResponseAsync(String resourceGroupName, String vmName, Context context) {<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_LIN... | error(new IllegalArgumentException("Parameter vmName is required and cannot be null.")); |
785,226 | private static DeserializedAst deserialize(AbstractCompiler compiler, SourceFile syntheticExterns, ImmutableMap<String, SourceFile> scriptSourceFiles, Optional<ColorPool.Builder> colorPool, InputStream typedAstStream, Mode mode, boolean includeTypeInformation) {<NEW_LINE>checkArgument(colorPool.isPresent() == (mode.equ... | RUNTIME_LIBRARY_ONLY) && includeTypeInformation), "ColorPool.Builder required iff deserializing runtime libraries & including types"); |
815,765 | public String readMemory(String address, long offset, int length) {<NEW_LINE>MIRecord memory;<NEW_LINE>String offsetArg;<NEW_LINE>if (offset != 0) {<NEW_LINE>offsetArg = "-o " + offset + " ";<NEW_LINE>} else {<NEW_LINE>offsetArg = "";<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>memory = sendAndGet("-data-read-memory-bytes " + <... | offsetArg + address + " " + length); |
996,483 | final Optional<ServerInterceptor> rateMeteringInterceptor() {<NEW_LINE>return getCustomRateMeteringInterceptor(coreApi.getConfig().appDataDir, this.getClass()).or(() -> Optional.of(CallRateMeteringInterceptor.valueOf(new HashMap<>() {<NEW_LINE><NEW_LINE>{<NEW_LINE>put(getGetOfferCategoryMethod().getFullMethodName(), ne... | new GrpcCallRateMeter(1, SECONDS)); |
610,892 | protected void exec() throws Exception {<NEW_LINE>super.verifyArtifacts();<NEW_LINE>// Define the distribution file paths<NEW_LINE>Path api = getRelativeFile("dist/" + formatVersion(ARTIFACT_API));<NEW_LINE>Path standalone = getRelativeFile("dist/" + formatVersion(ARTIFACT_STANDALONE));<NEW_LINE>Path unoptimized = getR... | ("dist/" + formatVersion(ARTIFACT_FORGE_API)); |
498,943 | private static ExplosionEvent.Detonate createAndPostExplosionEventDetonate(CauseStackManager.StackFrame frame, ForgeToSpongeEventData eventData) {<NEW_LINE>ExplosionEvent.Detonate spongeEvent;<NEW_LINE>final net.minecraftforge.event.world.ExplosionEvent.Detonate forgeEvent = (net.minecraftforge.event.world.ExplosionEve... | api.entity.Entity) entity); |
267,891 | public GetFindingsReportAccountSummaryResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>GetFindingsReportAccountSummaryResult getFindingsReportAccountSummaryResult = new GetFindingsReportAccountSummaryResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE... | String currentParentElement = context.getCurrentParentElement(); |
1,217,967 | private void process(final byte[] nonce, ByteBuffer output, ByteBuffer input) throws GeneralSecurityException {<NEW_LINE>if (nonce.length != nonceSizeInBytes()) {<NEW_LINE>throw new GeneralSecurityException("The nonce length (in bytes) must be " + nonceSizeInBytes());<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>int numBlocks =... | int length = input.remaining(); |
1,098,661 | public void generateSyntheticFinalFieldInitialization(CodeStream codeStream) {<NEW_LINE>if (this.synthetics == null || this.synthetics[SourceTypeBinding.FIELD_EMUL] == null)<NEW_LINE>return;<NEW_LINE>Collection<FieldBinding> syntheticFields = this.synthetics[SourceTypeBinding.FIELD_EMUL].values();<NEW_LINE>for (FieldBi... | Opcodes.OPC_putstatic, field, null); |
486,312 | private ByteBuf deserialize(ImmutableList<Cookie> sessionCookies) throws Exception {<NEW_LINE>if (sessionCookies.isEmpty()) {<NEW_LINE>return Unpooled.EMPTY_BUFFER;<NEW_LINE>}<NEW_LINE>StringBuilder sessionCookie = new StringBuilder();<NEW_LINE>for (Cookie cookie : sessionCookies) {<NEW_LINE>sessionCookie.append(cookie... | toString().split(SESSION_SEPARATOR); |
1,717,556 | private PackageLookupValue computeExternalPackageLookupValue(SkyKey skyKey, Environment env, PackageIdentifier packageIdentifier) throws PackageLookupFunctionException, InterruptedException {<NEW_LINE>PackageIdentifier id = (PackageIdentifier) skyKey.argument();<NEW_LINE>SkyKey repositoryKey = RepositoryDirectoryValue.... | ()), Transience.PERSISTENT); |
761,605 | private Mono<PagedResponse<UsageInner>> listSinglePageAsync(String location, Context context) {<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 (location == null) {<N... | error(new IllegalArgumentException("Parameter this.client.getSubscriptionId() is required and cannot be null.")); |
720,785 | public void save(RowBasedPartition part, MatrixPartitionMeta partMeta, PSMatrixSaveContext saveContext, DataOutputStream output) throws IOException {<NEW_LINE>List<Integer> rowIds = saveContext.getRowIndexes();<NEW_LINE>ServerRowsStorage rows = part.getRowsStorage();<NEW_LINE>if (rowIds == null || rowIds.isEmpty()) {<N... | SaveType.DENSE.getTypeId()); |
141,353 | private CommonResponse handleStaticResource(String path, CommonRequest request) throws IOException {<NEW_LINE>URL url = getSecureUrlForPath(RESOURCE_BASE + path);<NEW_LINE>if (url == null) {<NEW_LINE>// log at debug only since this is typically just exploit bot spam<NEW_LINE>logger.debug("unexpected path: {}", path);<N... | mediaType, "found extension under %s with no media type: %s", RESOURCE_BASE, extension); |
218,075 | public DBClusterRole unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>DBClusterRole dBClusterRole = new DBClusterRole();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (context.isStartOfDocument())<NEW_LINE>targetDepth += 1;<NEW_L... | XMLEvent xmlEvent = context.nextEvent(); |
184,773 | public Map<String, Object> assignUserAccess(Map<String, String> params) throws Exception {<NEW_LINE>final WebContext ctx = WebContextFactory.get();<NEW_LINE>final HttpServletRequest request = ctx.getHttpServletRequest();<NEW_LINE>final HttpServletResponse response = ctx.getHttpServletResponse();<NEW_LINE>final UserAPI ... | save(userToModify, loggedInUser, false); |
352,066 | public static ClientMessage encodeRequest(java.lang.String name, com.hazelcast.internal.serialization.Data key, com.hazelcast.internal.serialization.Data value, long threadId, long ttl, long maxIdle) {<NEW_LINE>ClientMessage clientMessage = ClientMessage.createForEncode();<NEW_LINE>clientMessage.setRetryable(false);<NE... | initialFrame.content, TYPE_FIELD_OFFSET, REQUEST_MESSAGE_TYPE); |
1,609,940 | public Document toDocument(AggregationOperationContext context) {<NEW_LINE>Document graphLookup = new Document();<NEW_LINE>graphLookup.put("from", from);<NEW_LINE>List<Object> mappedStartWith = new ArrayList<Object>(startWith.size());<NEW_LINE>for (Object startWithElement : startWith) {<NEW_LINE>if (startWithElement in... | "connectFromField", connectFrom.getTarget()); |
615,646 | public HiveMQExtensionEvent loadEmbeddedExtension(@NotNull final EmbeddedExtension embeddedExtension) {<NEW_LINE>final HiveMQEmbeddedExtensionImpl extension = new HiveMQEmbeddedExtensionImpl(embeddedExtension.getId(), embeddedExtension.getVersion(), embeddedExtension.getName(), embeddedExtension.getAuthor(), embeddedEx... | ), e.getMessage()); |
924,833 | void validateTemplateInjectionPoints(TemplateFilePathsBuildItem filePaths, List<TemplatePathBuildItem> templatePaths, ValidationPhaseBuildItem validationPhase, BuildProducer<ValidationErrorBuildItem> validationErrors) {<NEW_LINE>for (InjectionPointInfo injectionPoint : validationPhase.getContext().getInjectionPoints())... | .value().asString(); |
1,596,762 | private static String resolveSpecialTypes(String paramInfo, final BaseFunctionElement element, TypeNameResolver typeNameResolver, final ParameterElement param) {<NEW_LINE>String parameterInfo = paramInfo;<NEW_LINE>if (// NOI18N<NEW_LINE>parameterInfo.startsWith(Type.SELF + " ") && element instanceof TypeMemberElement) ... | resolveSpecialTypesInUnionType(parameterInfo, element, typeNameResolver); |
1,002,095 | private void findTablesByMask(JDBCSession session, GenericCatalog catalog, GenericSchema schema, String tableNameMask, int maxResults, List<DBSObjectReference> objects) throws SQLException, DBException {<NEW_LINE>final GenericMetaObject tableObject = getDataSource().getMetaObject(GenericConstants.OBJECT_TABLE);<NEW_LIN... | dbResult, JDBCConstants.REMARKS))); |
626,279 | public com.amazonaws.services.dataexchange.model.InternalServerException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.dataexchange.model.InternalServerException internalServerException = new com.amazonaws.services.<MASK><NEW_LINE>int originalDepth = context.g... | dataexchange.model.InternalServerException(null); |
1,231,686 | public final // JPA2.g:506:1: boolean_literal : ( 'true' | 'false' );<NEW_LINE>JPA2Parser.boolean_literal_return boolean_literal() throws RecognitionException {<NEW_LINE>JPA2Parser.boolean_literal_return <MASK><NEW_LINE>retval.start = input.LT(1);<NEW_LINE>Object root_0 = null;<NEW_LINE>Token set592 = null;<NEW_LINE>Ob... | retval = new JPA2Parser.boolean_literal_return(); |
1,234,271 | TableView<Pair<String, String>> createTable(final Set<Pair<String, String>> props) {<NEW_LINE>final TableView<Pair<String, String>> table = new TableView<>();<NEW_LINE>final TableColumn<Pair<String, String>, String> colName = new TableColumn<>("Name");<NEW_LINE>final TableColumn<Pair<String, String>, String> colValue =... | final ClipboardContent clipboardContent = new ClipboardContent(); |
1,474,728 | public List<JoinResponseTimeBo> decodeValues(Buffer valueBuffer, ApplicationStatDecodingContext decodingContext) {<NEW_LINE>final String id = decodingContext.getApplicationId();<NEW_LINE>final long baseTimestamp = decodingContext.getBaseTimestamp();<NEW_LINE>final <MASK><NEW_LINE>final long initialTimestamp = baseTimes... | long timestampDelta = decodingContext.getTimestampDelta(); |
294,011 | static // [START securitycenter_add_finding_security_marks]<NEW_LINE>SecurityMarks addToFinding(FindingName findingName) {<NEW_LINE>// FindingName findingName = FindingName.of(/*organization=*/"123234324",<NEW_LINE>// /*source=*/"423432321", /*findingId=*/"samplefindingid2");<NEW_LINE>try (SecurityCenterClient client =... | throw new RuntimeException("Couldn't create client.", e); |
1,704,354 | private void translateTab(int scrollY, boolean animated) {<NEW_LINE>int flexibleSpaceImageHeight = getResources().getDimensionPixelSize(R.dimen.flexible_space_image_height);<NEW_LINE>int tabHeight = getResources().<MASK><NEW_LINE>View imageView = findViewById(R.id.image);<NEW_LINE>View overlayView = findViewById(R.id.o... | getDimensionPixelSize(R.dimen.tab_height); |
266,690 | private String uploadFile(String sourceFile, String destinationUrl) throws IOException, URISyntaxException {<NEW_LINE>Common.logger.add(new LogEntry(LogEntry.PB_LOG_DEBUG, "Start"));<NEW_LINE>String result = ERROR;<NEW_LINE>httpClient = createHttpsClient();<NEW_LINE>HttpParams params = httpClient.getParams();<NEW_LINE>... | HttpPost(url.toURI()); |
832,018 | public Object calculate(Context ctx) {<NEW_LINE>MessageManager mm = EngineMessage.get();<NEW_LINE>if (param == null || param.isLeaf()) {<NEW_LINE>throw new RQException("FCoups:" + mm.getMessage("function.missingParam"));<NEW_LINE>}<NEW_LINE>Object[] result = new Object[2];<NEW_LINE>for (int i = 0; i < 2; i++) {<NEW_LIN... | maturity, settlement, frequency, basis); |
1,158,044 | public List<Fact> createFacts(final AcctSchema as) {<NEW_LINE>setC_Currency_ID(as.getCurrencyId());<NEW_LINE>final ArrayList<Fact> <MASK><NEW_LINE>final CostCollectorType costCollectorType = getCostCollectorType();<NEW_LINE>if (CostCollectorType.MaterialReceipt.equals(costCollectorType)) {<NEW_LINE>facts.addAll(createF... | facts = new ArrayList<>(); |
71,451 | public List<CompletableFuture<Long>> executeBulk(TransactionContext txnCtx) {<NEW_LINE>Iterable<NodeOperation> nodeOperations = nodeOperationTrees.stream().flatMap(opTree -> opTree.nodeOperations().stream())::iterator;<NEW_LINE>Map<String, Collection<NodeOperation>> operationByServer = NodeOperationGrouper.groupByServe... | >(nodeOperationTrees.size()); |
609,360 | private void generateNormalVirtualCall(MethodReference reference, List<? extends Expr> arguments) {<NEW_LINE>VirtualTable vtable = context.getVirtualTableProvider().lookup(reference.getClassName());<NEW_LINE>String vtableClass = null;<NEW_LINE>if (vtable != null) {<NEW_LINE>VirtualTable containingVt = vtable.findMethod... | receiverArg = arguments.get(0); |
1,131,213 | protected Query doToQuery(SearchExecutionContext searchExecutionContext) throws IOException {<NEW_LINE>// TODO: should we be passing activeFeatures here?<NEW_LINE>LtrQueryContext context = new LtrQueryContext(searchExecutionContext);<NEW_LINE>if (StoredFeature.TYPE.equals(element.type())) {<NEW_LINE>Feature feature = (... | ) element).compile(factory); |
1,046,244 | private void classNameChanged(ActionEvent ac) {<NEW_LINE>final String s = source.getText().trim();<NEW_LINE>if (s.equals(oldText)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (loaderSelect.getSelectedItem() == LoaderPolicy.SYSTEM) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>class UT extends UserTask implements ClasspathInfo.P... | ("text/x-java", new UT()); |
83,958 | private PreparedStatement createQueryStatement(Connection conn, OracleTriggerMonitoredSourceInfo source, long sinceScn, int currentFetchSize, boolean useChunking) throws SQLException {<NEW_LINE><MASK><NEW_LINE>String eventQuery = null;<NEW_LINE>ChunkingType type = _chunkingType;<NEW_LINE>if (!useChunking || (!type.isCh... | boolean debugEnabled = _log.isDebugEnabled(); |
1,779,699 | public static ErrorDescription apply(HintContext hc) {<NEW_LINE>if (hc.isCanceled()) {<NEW_LINE>// NOI18N<NEW_LINE>// we pass only if it is an annotation<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>final JPAProblemContext ctx = ModelUtils.getOrCreateCachedContext(hc);<NEW_LINE>if (ctx == null || hc.isCanceled()) {<NEW_LI... | .ENTITY, JPAAnnotations.MAPPED_SUPERCLASS)); |
1,141,524 | // @Override<NEW_LINE>public void updated(String pid, Dictionary<String, ?> properties) throws ConfigurationException {<NEW_LINE>System.out.println("Updating configuration properties:" + properties);<NEW_LINE>String id = (String) properties.get("id");<NEW_LINE>_properties = cloneDictionary(properties);<NEW_LINE>System.... | Object> serviceProps = cloneDictionary(properties); |
1,099,896 | private HoldingContainer visitBooleanOr(BooleanOperator op, ClassGenerator<?> generator) {<NEW_LINE>HoldingContainer out = generator.declare(op.getMajorType());<NEW_LINE>JLabel label = generator.getEvalBlockLabel("OrOP");<NEW_LINE>JBlock eval = generator.createInnerEvalBlock();<NEW_LINE>// enter into nested block.<NEW_... | , JExpr.lit(0)); |
1,140,428 | public Request<SetIdentityDkimEnabledRequest> marshall(SetIdentityDkimEnabledRequest setIdentityDkimEnabledRequest) {<NEW_LINE>if (setIdentityDkimEnabledRequest == null) {<NEW_LINE>throw new AmazonClientException("Invalid argument passed to marshall(SetIdentityDkimEnabledRequest)");<NEW_LINE>}<NEW_LINE>Request<SetIdent... | <SetIdentityDkimEnabledRequest>(setIdentityDkimEnabledRequest, "AmazonSimpleEmailService"); |
330,540 | public void show(final String date) {<NEW_LINE>dialog = setDialogLayout();<NEW_LINE>UIUtil.setDialogDefaultFunctions(dialog);<NEW_LINE>ExUtil.asyncRun(new Runnable() {<NEW_LINE><NEW_LINE>public void run() {<NEW_LINE>ObjectPack objectPack = null;<NEW_LINE>TcpProxy proxy = TcpProxy.getTcpProxy(serverId);<NEW_LINE>try {<N... | getServer(serverId).getCounterEngine(); |
248,437 | private boolean returnsNormalizedAbstractValueType(ExecutableElement validationMethodCandidate) {<NEW_LINE>Optional<DeclaringType<MASK><NEW_LINE>if (!declaringType.isPresent()) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>TypeStringProvider provider = new TypeStringProvider(reporter, validationMethodCandidate, resolveR... | > declaringType = protoclass.declaringType(); |
1,774,778 | public static FromChannelCredentialsResult from(ChannelCredentials creds) {<NEW_LINE>if (creds instanceof TlsChannelCredentials) {<NEW_LINE>TlsChannelCredentials tlsCreds = (TlsChannelCredentials) creds;<NEW_LINE>Set<TlsChannelCredentials.Feature> incomprehensible = tlsCreds.incomprehensible(understoodTlsFeatures);<NEW... | SslContextBuilder builder = GrpcSslContexts.forClient(); |
1,714,781 | public void write(org.apache.thrift.protocol.TProtocol prot, UpdateErrors 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.isSetFail... | getKey().write(oprot); |
517,776 | protected String toJson() {<NEW_LINE>JsonObject json = new JsonObject();<NEW_LINE>json.addProperty("sessionId", this.sessionId);<NEW_LINE>json.addProperty("createdAt", this.createdAt);<NEW_LINE>json.addProperty("recording", this.recording);<NEW_LINE>// Add keys from SessionProperties<NEW_LINE>JsonObject sessionProperti... | = this.properties.toJson(); |
1,839,097 | static String addLineNumbers(final String javaSource) {<NEW_LINE>final StringBuilder sb = new StringBuilder(javaSource);<NEW_LINE>sb.insert(0, "<a name=1 href=#1>1</a> ");<NEW_LINE>int line = 2;<NEW_LINE>int index = sb.indexOf(BR);<NEW_LINE>while (index != -1) {<NEW_LINE>final int offset <MASK><NEW_LINE>final String st... | = index + BR.length(); |
1,589,559 | protected void addStandardClassSources(String moduleUri, ClassLoader rootClassLoader, ClassSource_Aggregate classSource) throws ClassSource_Exception {<NEW_LINE>String useApplicationLibPath = getApplicationLibraryPath();<NEW_LINE>List<String> applicationLibJarPaths;<NEW_LINE>if (useApplicationLibPath != null) {<NEW_LIN... | <String> manifestJarPaths = getManifestJarPaths(); |
1,039,056 | public void checkEmptyPeriod(Timesheet timesheet) throws AxelorException {<NEW_LINE>LeaveService leaveService = Beans.get(LeaveService.class);<NEW_LINE>PublicHolidayHrService publicHolidayHrService = Beans.get(PublicHolidayHrService.class);<NEW_LINE>User user = timesheet.getUser();<NEW_LINE>Employee employee = user.get... | ), user.getName()); |
373,860 | public void init(List<TransformFunction> arguments, Map<String, DataSource> dataSourceMap) {<NEW_LINE>Preconditions.checkArgument(arguments.size() == 3 || arguments.size() == 2, "Transform function %s requires 2 or 3 arguments", getName());<NEW_LINE>if (arguments.size() == 3) {<NEW_LINE>TransformFunction transformFunct... | transformFunction = arguments.get(1); |
1,311,817 | private void drawDocumentBox(Point[] points, Size stdSize) {<NEW_LINE>Path path = new Path();<NEW_LINE>HUDCanvasView hud = mMainActivity.getHUD();<NEW_LINE>// ATTENTION: axis are swapped<NEW_LINE>float previewWidth = (float) stdSize.height;<NEW_LINE>float <MASK><NEW_LINE>path.moveTo(previewWidth - (float) points[0].y, ... | previewHeight = (float) stdSize.width; |
725,520 | @ApiOperation("Removes a token for a user")<NEW_LINE>@AuditEvent(type = AuditEventTypes.USER_ACCESS_TOKEN_DELETE)<NEW_LINE>public void revokeToken(@ApiParam(name = "userId", required = true) @PathParam("userId") String userId, @ApiParam(name = "idOrToken", required = true) @PathParam("idOrToken") String idOrToken) {<NE... | String username = user.getName(); |
56,730 | protected PluginWrapper loadPluginFromPath(Path pluginPath) {<NEW_LINE>// Test for plugin path duplication<NEW_LINE>String pluginId = idForPath(pluginPath);<NEW_LINE>if (pluginId != null) {<NEW_LINE>throw new PluginAlreadyLoadedException(pluginId, pluginPath);<NEW_LINE>}<NEW_LINE>// Retrieve and validate the plugin des... | pluginWrapper.setPluginState(PluginState.DISABLED); |
1,521,326 | private static JCExpression cloneType0(JavacTreeMaker maker, JCTree in) {<NEW_LINE>if (in == null)<NEW_LINE>return null;<NEW_LINE>if (in instanceof JCPrimitiveTypeTree) {<NEW_LINE>return maker.TypeIdent(TypeTag.typeTag(in));<NEW_LINE>}<NEW_LINE>if (in instanceof JCIdent) {<NEW_LINE>return maker.Ident((<MASK><NEW_LINE>}... | (JCIdent) in).name); |
313,654 | protected void openInt(UsbDeviceConnection connection) throws IOException {<NEW_LINE>if (!connection.claimInterface(mDevice.getInterface(mPortNumber), true)) {<NEW_LINE>throw new IOException("Could not claim interface " + mPortNumber);<NEW_LINE>}<NEW_LINE>if (mDevice.getInterface(mPortNumber).getEndpointCount() < 2) {<... | (mPortNumber).getEndpoint(0); |
727,785 | public FileHeader generateFileHeader(ZipParameters zipParameters, boolean isSplitZip, int currentDiskNumberStart, Charset charset, RawIO rawIO) throws ZipException {<NEW_LINE>FileHeader fileHeader = new FileHeader();<NEW_LINE><MASK><NEW_LINE>fileHeader.setVersionMadeBy(determineVersionMadeBy(zipParameters, rawIO));<NEW... | fileHeader.setSignature(HeaderSignature.CENTRAL_DIRECTORY); |
972,299 | public static void main(String[] args) {<NEW_LINE>final String USAGE = "\n" + "Usage: " + "CreateBrokerActiveMQ <engineType> <brokerName>\n\n" + "Where:\n" + " engineType - Required. RABBITMQ or ACTIVEMQ for broker's engine type.\n" + " brokerName - Optional. The name of the Amazon MQ for ActiveMQ broker.\n\n";<NEW_L... | + "-" + System.currentTimeMillis(); |
1,160,044 | public com.amazonaws.services.eventbridge.model.ManagedRuleException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>com.amazonaws.services.eventbridge.model.ManagedRuleException managedRuleException = new com.amazonaws.services.eventbridge.model.ManagedRuleException(null);<NEW_LINE>i... | String currentParentElement = context.getCurrentParentElement(); |
7,774 | protected String buildNonAjaxRequest(FacesContext context, UIComponent component, UIComponent form, String decodeParam, Map<String, List<String>> parameters, boolean submit) {<NEW_LINE>StringBuilder request = SharedStringBuilder.get(context, SB_BUILD_NON_AJAX_REQUEST);<NEW_LINE>String formId = form.getClientId(context)... | Collectors.joining(","))); |
487,106 | public void onNext(final T element) {<NEW_LINE>if (subscription == null) {<NEW_LINE>// Technically this check is not needed, since we are expecting Publishers to conform to the spec<NEW_LINE>(new IllegalStateException("Publisher violated the Reactive Streams rule 1.09 signalling onNext prior to onSubscribe.")).printSta... | ).printStackTrace(System.err); |
806,187 | private long insert(GlobalId globalId, Session session) {<NEW_LINE>InsertBuilder insert = null;<NEW_LINE>if (globalId instanceof ValueObjectId) {<NEW_LINE>insert = session.insert("ValueObjectId");<NEW_LINE>ValueObjectId valueObjectId = (ValueObjectId) globalId;<NEW_LINE>long ownerFk = getOrInsertId(<MASK><NEW_LINE>inse... | valueObjectId.getOwnerId(), session); |
757,400 | private void handleDeletion(final CascadeAction action, final Completion completion) {<NEW_LINE>final List<ImageDeletionStruct> structs = imageFromAction(action);<NEW_LINE>if (structs == null) {<NEW_LINE>completion.success();<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>List<ImageDeletionMsg> msgs = CollectionUtils.transformTo... | null : deletionPolicy.toString()); |
1,216,968 | private void sendResultNotification(DestroyedActivityInfo activityInfo, ManualDumpData data) {<NEW_LINE>final Context context = getWatcher().getContext();<NEW_LINE>Intent targetIntent = new Intent();<NEW_LINE>targetIntent.setClassName(getWatcher().getContext(), mTargetActivity);<NEW_LINE>targetIntent.putExtra(<MASK><NE... | SharePluginInfo.ISSUE_ACTIVITY_NAME, activityInfo.mActivityName); |
1,438,945 | private void overlayValue(HeaderElement elem) {<NEW_LINE>if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {<NEW_LINE>Tr.debug(tc, "Overlaying existing header: " + elem.getName());<NEW_LINE>}<NEW_LINE>int next_index = this.lastCRLFBufferIndex;<NEW_LINE>int next_pos = this.lastCRLFPosition;<NEW_LINE>if (n... | int start = buffer.position(); |
1,296,496 | public void removeDatabase(String userId, String databaseGUID, String externalSourceName, DeleteSemantic deleteSemantic) throws FunctionNotSupportedException, InvalidParameterException, PropertyServerException, UserNotAuthorizedException {<NEW_LINE>final String methodName = "removeDatabase";<NEW_LINE><MASK><NEW_LINE>in... | dataEngineCommonHandler.validateDeleteSemantic(deleteSemantic, methodName); |
1,174,099 | public ImmutableSortedMap<DocumentKey, Document> applyBundledDocuments(ImmutableSortedMap<DocumentKey, MutableDocument> documents, String bundleId) {<NEW_LINE>// Allocates a target to hold all document keys from the bundle, such that<NEW_LINE>// they will not get garbage collected right away.<NEW_LINE>TargetData umbrel... | = allocateTarget(newUmbrellaTarget(bundleId)); |
1,850,982 | public void start(Member member, XposedBridge.AdditionalHookInfo hookInfo, ClassLoader appClassLoader) throws Exception {<NEW_LINE>Class<?> returnType;<NEW_LINE>boolean isStatic;<NEW_LINE>if (member instanceof Method) {<NEW_LINE>Method method = (Method) member;<NEW_LINE>isStatic = Modifier.isStatic(method.getModifiers(... | method.getParameterTypes(), isStatic); |
189,809 | protected void fillCpuUsage(final ExecutorInfo stats) {<NEW_LINE>if (exists_Bash && exists_Cat && exists_LoadAvg) {<NEW_LINE>try {<NEW_LINE>final ArrayList<String> output = Utils.runProcess("/bin/bash", "-c", "/bin/cat /proc/loadavg");<NEW_LINE>// process the output from bash call.<NEW_LINE>if (output.size() > 0) {<NEW... | .parseDouble(splitedresult[0]); |
1,635,173 | public List<FilesListRecursiveItem> listRecursive(String path) throws IOException, InvalidTokenException {<NEW_LINE>String url;<NEW_LINE>try {<NEW_LINE>URIBuilder builder = getUriBuilder().setPath(CONTENT_API_PATH_PREFIX + "/mounts/primary/files/listrecursive").setParameter("path", path);<NEW_LINE>url = builder.build()... | int code = response.code(); |
579,116 | public void prepare(OutlierResult or) {<NEW_LINE>meta = or.getOutlierMeta();<NEW_LINE>// Determine Minimum and Maximum.<NEW_LINE>DoubleMinMax mm = new DoubleMinMax();<NEW_LINE>DoubleRelation scores = or.getScores();<NEW_LINE>for (DBIDIter id = scores.iterDBIDs(); id.valid(); id.advance()) {<NEW_LINE>double score = scor... | , var = mv.getSampleVariance(); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.