idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,849,650 | public void run(RegressionEnvironment env) {<NEW_LINE>SubscriberInterface subscriber = new SubscriberInterface();<NEW_LINE>EPCompiled compiled = env.compile("@name('s0') select * from SupportMarkerInterface");<NEW_LINE>EPStatement stmt = env.deploy(compiled).statement("s0");<NEW_LINE>stmt.setSubscriber(subscriber);<NEW... | SupportBean_A a1 = new SupportBean_A("A1"); |
846,804 | public ClasspathEntry combineWith(ClasspathEntry referringEntry) {<NEW_LINE>if (referringEntry == null)<NEW_LINE>return this;<NEW_LINE>IClasspathAttribute[] referringExtraAttributes = referringEntry.getExtraAttributes();<NEW_LINE>if (referringEntry.isExported() || referringEntry.getAccessRuleSet() != null || referringE... | 0, combinedAttributes, 0, lenRefer); |
123,961 | public HBaseScanSpec visitFunctionCall(FunctionCall call, Void value) throws RuntimeException {<NEW_LINE>HBaseScanSpec nodeScanSpec = null;<NEW_LINE>String functionName = call.getName();<NEW_LINE>List<LogicalExpression> args = call.args();<NEW_LINE>if (CompareFunctionsProcessor.isCompareFunction(functionName)) {<NEW_LI... | nodeScanSpec = createHBaseScanSpec(call, processor); |
1,390,327 | public void actionPerform(Component component) {<NEW_LINE><MASK><NEW_LINE>if (selected.size() != 1) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Entity editItem = (Entity) selected.toArray()[0];<NEW_LINE>Map<String, Object> editorParams = new HashMap<>();<NEW_LINE>editorParams.put("metaClass", editItem.getMetaClass());<NEW_L... | Set selected = entitiesTable.getSelected(); |
532,717 | private void superPreDestroy(InvocationContext inv) {<NEW_LINE>try {<NEW_LINE>ResultsLocal results = ResultsLocalBean.getSFBean();<NEW_LINE>results.addPreDestroy(CLASS_NAME, "superPreDestroy");<NEW_LINE>// Validate and update context data.<NEW_LINE>Map<String, Object> map = inv.getContextData();<NEW_LINE>String data;<N... | InvocationContext) map.get("InvocationContext"); |
1,474,198 | ReadResult read(long startOffset, int maxLength, Duration timeout) {<NEW_LINE>Exceptions.checkNotClosed(this.closed, this);<NEW_LINE>Preconditions.checkState<MASK><NEW_LINE>Exceptions.checkArgument(startOffset >= 0, "startOffset", "startOffset must be a non-negative number.");<NEW_LINE>Exceptions.checkArgument(maxLengt... | (!this.recoveryMode, "StreamSegmentReadIndex is in Recovery Mode."); |
1,059,950 | public void marshall(UpdateWebACLRequest updateWebACLRequest, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (updateWebACLRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(updateWebACLRequest.getName... | updateWebACLRequest.getId(), ID_BINDING); |
1,255,774 | public PCollection<KV<BigQueryTablePartition, String>> expand(PBegin begin) {<NEW_LINE>Schema targetFileSchema = table.getSchema();<NEW_LINE>if (table.isPartitioned() && enforceSamePartitionKey) {<NEW_LINE>// Apart from renaming the field in the schema we don't need to anything else (e.g. replace<NEW_LINE>// the field ... | throw new UnsupportedOperationException("Output format is not implemented: " + outputFileFormat); |
1,102,025 | protected AuthChallenge challengeResponse(HttpFacade facade, final OIDCAuthenticationError.Reason reason, final String error, final String description) {<NEW_LINE>StringBuilder header = new StringBuilder("Bearer realm=\"");<NEW_LINE>header.append(deployment.getRealm()).append("\"");<NEW_LINE>if (error != null) {<NEW_LI... | (error).append("\""); |
1,505,415 | public Request<CreateInstanceProfileRequest> marshall(CreateInstanceProfileRequest createInstanceProfileRequest) {<NEW_LINE>if (createInstanceProfileRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>Request<CreateInstanceProfileRequest> request = n... | Tag>) createInstanceProfileRequest.getTags(); |
1,176,540 | public void paint(Graphics gr, JComponent c) {<NEW_LINE>final OnOffButton button = (OnOffButton) c;<NEW_LINE>final Dimension size = button.getSize();<NEW_LINE>int w = size.width - 8;<NEW_LINE>int h = size.height - 6;<NEW_LINE>if (h % 2 == 1) {<NEW_LINE>h--;<NEW_LINE>}<NEW_LINE>int ovalSize = h - JBUI.scale(4);<NEW_LINE... | w, h, h, h); |
565,979 | public Observable<ServiceResponseWithHeaders<Page<CloudJob>, JobListFromJobScheduleHeaders>> listFromJobScheduleWithServiceResponseAsync(final String jobScheduleId, final JobListFromJobScheduleOptions jobListFromJobScheduleOptions) {<NEW_LINE>return listFromJobScheduleSinglePageAsync(jobScheduleId, jobListFromJobSchedu... | withReturnClientRequestId(jobListFromJobScheduleOptions.returnClientRequestId()); |
1,361,819 | private BinaryOperationExpression createPatternMatchingOperationSegment(final AExprContext ctx) {<NEW_LINE>String operator = ctx.patternMatchingOperator().getText();<NEW_LINE>ExpressionSegment left = (ExpressionSegment) visit(ctx.aExpr(0));<NEW_LINE>ListExpression right = new ListExpression(ctx.aExpr(1).start.getStartI... | ).stop.getStopIndex()); |
891,376 | public TargetCapacitySpecification unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>TargetCapacitySpecification targetCapacitySpecification = new TargetCapacitySpecification();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (conte... | XMLEvent xmlEvent = context.nextEvent(); |
1,633,984 | final DescribeDataSourcesResult executeDescribeDataSources(DescribeDataSourcesRequest describeDataSourcesRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeDataSourcesRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE><MASK><NEW... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
641,068 | private void drawTransforms(Canvas canvas) {<NEW_LINE>canvas.save();<NEW_LINE>try (var path = new Path();<NEW_LINE>var paint = new Paint().setColor(0xFF437AA0).setMode(PaintMode.STROKE).setStrokeWidth(1f);<NEW_LINE>var secondaryPaint = new Paint().setColor(0xFFFAA6B2).setMode(PaintMode.STROKE).setStrokeWidth(1f)) {<NEW... | canvas.drawPath(path, paint); |
241,601 | public void onLinkRemoteOpen(Event event) {<NEW_LINE>Link link = event.getLink();<NEW_LINE>if (link instanceof Sender) {<NEW_LINE>if (link.getRemoteTarget() != null) {<NEW_LINE>if (TRACE_LOGGER.isInfoEnabled()) {<NEW_LINE>TRACE_LOGGER.info(String.format(Locale.US, "onLinkRemoteOpen senderName[%s], linkName[%s], remoteT... | , link.getName())); |
1,683,494 | private static Observable<Set<Endpoint>> staticEndpoints(final int[] ports, final int stageNum, final int workerIndex, final int numPartitions) {<NEW_LINE>return Observable.create(new OnSubscribe<Set<Endpoint>>() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void call(Subscriber<? super Set<Endpoint>> subscriber) {<NE... | = new HashSet<Endpoint>(); |
1,658,959 | public void handle(Request request, HttpResponder httpResponder) {<NEW_LINE>Stopwatch stopwatch = Stopwatch.createStarted();<NEW_LINE>ServeEvent serveEvent;<NEW_LINE>Request processedRequest = request;<NEW_LINE>if (!requestFilters.isEmpty()) {<NEW_LINE>RequestFilterAction requestFilterAction = processFilters(request, r... | ) stopwatch.elapsed(MILLISECONDS)); |
1,453,707 | public static String literalToRawString(LiteralArg arg) {<NEW_LINE>ArgType type = arg.getType();<NEW_LINE>if (type == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>long lit = arg.getLiteral();<NEW_LINE>switch(type.getPrimitiveType()) {<NEW_LINE>case BOOLEAN:<NEW_LINE>return lit == 0 ? "false" : "true";<NEW_LINE>cas... | (Double.longBitsToDouble(lit)); |
739,000 | private void indeterminateChanged() {<NEW_LINE>boolean show = indeterminateButton.isSelected();<NEW_LINE>// show/hide indeterminate checkboxes<NEW_LINE>for (Component c : getComponents()) {<NEW_LINE>if ((c instanceof TestStateCheckBox && ((TestStateCheckBox) c).isStateIndeterminate()) || c instanceof FlatTriStateCheckB... | setSizeGroup(show ? "2" : null); |
362,015 | public static void expandNativeLibraryDirectories(ClassLoader classLoader, List<File> libPaths) {<NEW_LINE>if (sPathListField == null)<NEW_LINE>return;<NEW_LINE>Object pathList = getValue(sPathListField, classLoader);<NEW_LINE>if (pathList == null)<NEW_LINE>return;<NEW_LINE>if (sDexPathList_nativeLibraryDirectories_fie... | pathList.getClass(), "nativeLibraryDirectories"); |
174,107 | public static void main(String[] args) {<NEW_LINE>Map<String, Object> kafkaConsumerConfig = new HashMap<>();<NEW_LINE>kafkaConsumerConfig.put(ConsumerConfig.BOOTSTRAP_SERVERS_CONFIG, "localhost:9092");<NEW_LINE>kafkaConsumerConfig.put(ConsumerConfig.GROUP_ID_CONFIG, "sample-kafka-spout");<NEW_LINE>kafkaConsumerConfig.p... | , ByteAmount.fromMegabytes(256)); |
94,948 | public Translation readTranslation(TranslatedEntity entityType, String entityId, String fieldName, String localeCode, String localeCountryCode, ResultType stage) {<NEW_LINE>CriteriaBuilder builder = em.getCriteriaBuilder();<NEW_LINE>CriteriaQuery<Translation> criteria = builder.createQuery(Translation.class);<NEW_LINE>... | getType()).getClass(); |
1,708,346 | public void exitMethod(String methodName, String returnValue) {<NEW_LINE>if (!shouldLog(methodName))<NEW_LINE>return;<NEW_LINE>LogicalSide side = (forcedSideForTesting != null) ? forcedSideForTesting : EffectiveSide.get();<NEW_LINE>HashMap<String, Boolean> reentryFlagsSide = (side == <MASK><NEW_LINE>final int indentLev... | LogicalSide.CLIENT) ? reentryFlagsClient : reentryFlagsServer; |
19,956 | private CaseAnalysis analyzeCaseOne() throws ExprValidationException {<NEW_LINE>// Case 1 expression example:<NEW_LINE>// case when a=b then x [when c=d then y...] [else y]<NEW_LINE>//<NEW_LINE>ExprNode[] children = this.getChildNodes();<NEW_LINE>if (children.length < 2) {<NEW_LINE>throw new ExprValidationException("Ca... | CaseAnalysis(whenThenNodeList, null, optionalElseExprNode); |
1,792,819 | private int updateSelectedKeys() {<NEW_LINE>int entries = pollWrapper.updated;<NEW_LINE>int numKeysUpdated = 0;<NEW_LINE>for (int i = 0; i < entries; i++) {<NEW_LINE>int nextFD = pollWrapper.getDescriptor(i);<NEW_LINE>SelectionKeyImpl ski = fdToKey.get(Integer.valueOf(nextFD));<NEW_LINE>// ski is null in the case of an... | rOps = pollWrapper.getEventOps(i); |
1,404,120 | public GlmEvaluationBatchOp linkFrom(BatchOperator<?>... inputs) {<NEW_LINE>checkOpSize(2, inputs);<NEW_LINE>BatchOperator<?> model = inputs[0];<NEW_LINE>BatchOperator<?> in = inputs[1];<NEW_LINE>String[] featureColNames = getFeatureCols();<NEW_LINE>String labelColName = getLabelCol();<NEW_LINE>String weightColName = g... | familyName, variancePower, linkName, linkPower); |
1,030,560 | private Set<MyFormat> findProperAudio(TrackGroupArray groupArray) {<NEW_LINE>String trackCodecs = mPrefs.getSelectedAudioTrackCodecs();<NEW_LINE>int bitrate = mPrefs.getSelectedAudioTrackBitrate();<NEW_LINE>Set<MyFormat> result = new HashSet<>();<NEW_LINE>// search the same tracks<NEW_LINE>for (int j = 0; j < groupArra... | format = trackGroup.getFormat(i); |
1,015,080 | private void initComponents() {<NEW_LINE>Font labelEstimatedFont = new Font(Font.SANS_SERIF, Font.PLAIN, 12);<NEW_LINE>navigationButtons = new NavigationButtons(getBackend(), 1.0, (int) getBackend().getSettings().getJogFeedRate());<NEW_LINE>buttonUpdateSettingsX = new JButton(Localization.getString("platform.plugin.set... | (Localization.getString("platform.plugin.setupwizard.calibration.setting")); |
89,669 | static IsNewStrategy basedOn(Neo4jPersistentEntity<?> entityMetaData) {<NEW_LINE>Assert.notNull(entityMetaData, "Entity meta data must not be null.");<NEW_LINE>IdDescription idDescription = entityMetaData.getIdDescription();<NEW_LINE>Class<?> valueType = entityMetaData.getRequiredIdProperty().getType();<NEW_LINE>if (id... | .class.getName())); |
1,374,180 | public ManagedList parseInterceptors(Element element, ParserContext parserContext) {<NEW_LINE>ManagedList interceptors = new ManagedList();<NEW_LINE>NodeList childNodes = element.getChildNodes();<NEW_LINE>for (int i = 0; i < childNodes.getLength(); i++) {<NEW_LINE>Node child = childNodes.item(i);<NEW_LINE>if (child.get... | (holder.getBeanName())); |
928,717 | private static ImmutableList<IFlowgraphView> loadModuleFlowgraphs(final AbstractSQLProvider provider, final CModule module, final CTagManager viewTagManager, final CTagManager nodeTagManager, final ViewType viewType) throws CouldntLoadDataException {<NEW_LINE>checkArguments(provider, module, viewTagManager);<NEW_LINE>f... | "native" : "non-native", Types.OTHER); |
947,829 | protected String doIt() throws Exception {<NEW_LINE>List<Object> parameters = new ArrayList<>();<NEW_LINE>StringBuffer whereClause = new StringBuffer(I_HR_LeaveType.COLUMNNAME_IsLeaveRepeated).append<MASK><NEW_LINE>parameters.add(true);<NEW_LINE>if (getLeaveTypeId() > 0) {<NEW_LINE>parameters.add(getLeaveTypeId());<NEW... | (" = ").append(" ?"); |
510,642 | private boolean handleRequestor(final Expression node, final ClassNode primaryType, final TypeLookupResult result) {<NEW_LINE>// TODO: Why does result.scope.getEnclosingAssignment() exist?<NEW_LINE>result.enclosingAssignment = enclosingAssignment;<NEW_LINE>result.receiverType = primaryType != null ? primaryType : resul... | type, rememberedDeclaringType, result.declaration); |
443,541 | public void generate(GeneratorContext context, MethodReference method) {<NEW_LINE>String array = context.parameterName(1);<NEW_LINE>String index = context.parameterName(2);<NEW_LINE>String componentTypeField = context.names().forMemberField(new FieldReference(RuntimeClass.class<MASK><NEW_LINE>String flagsField = contex... | .getName(), "itemType")); |
1,677,547 | public static AnnotationMirror fromName(Elements elements, @FullyQualifiedName CharSequence name, Map<String, AnnotationValue> elementNamesValues) {<NEW_LINE>final TypeElement annoElt = elements.getTypeElement(name);<NEW_LINE>if (annoElt == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>if (annoElt.getKind() != Elem... | (DeclaredType) annoElt.asType(); |
347,457 | public static Story from(Cursor cursor) {<NEW_LINE>Long internalId = cursor.getLong(HNewsContract.StoryEntry.COLUMN_ID);<NEW_LINE>Long id = cursor.getLong(HNewsContract.StoryEntry.COLUMN_ITEM_ID);<NEW_LINE>String type = cursor.getString(HNewsContract.StoryEntry.COLUMN_TYPE);<NEW_LINE>String by = cursor.getString(HNewsC... | getString(HNewsContract.StoryEntry.COLUMN_FILTER); |
262,296 | private void loadNode362() throws IOException, SAXException {<NEW_LINE>PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.CertificateGroupType_TrustList_Close_InputArguments, new QualifiedName(0, "InputArguments"), new LocalizedText("en", "InputArguments"), LocalizedText.NULL_VALUE, UInteger.valueOf... | (1), 0.0, false); |
743,400 | public HttpMethodBase createMethod(final URL neutronUrl, final String uri) throws NeutronRestApiException {<NEW_LINE>String url;<NEW_LINE>try {<NEW_LINE>String formattedUrl = neutronUrl.toString() + uri;<NEW_LINE>url = new URL(formattedUrl).toString();<NEW_LINE>Constructor<? extends HttpMethodBase> httpMethodConstructo... | throw new NeutronRestApiException(error, e); |
1,118,052 | private void addContent() {<NEW_LINE>gridPane.getColumnConstraints().get(0).setHalignment(HPos.LEFT);<NEW_LINE>gridPane.getColumnConstraints().get(0<MASK><NEW_LINE>gridPane.getColumnConstraints().get(1).setHgrow(Priority.SOMETIMES);<NEW_LINE>Tuple2<Label, TextArea> labelTextAreaTuple2 = addTopLabelTextArea(gridPane, ++... | ).setHgrow(Priority.ALWAYS); |
81,910 | Statement generateJumpStatement(Decompiler.Block sourceBlock, BasicBlock target) {<NEW_LINE>Decompiler.Block targetBlock = getTargetBlock(sourceBlock, target);<NEW_LINE>if (targetBlock == null) {<NEW_LINE>int targetIndex = indexer.<MASK><NEW_LINE>if (targetIndex >= sourceBlock.end) {<NEW_LINE>throw new IllegalStateExce... | indexOf(target.getIndex()); |
1,478,845 | private CompletableFuture<TableWriterFlushResult> flushOnce(DirectSegmentAccess segment, TimeoutTimer timer) {<NEW_LINE>// Index all the keys in the segment range pointed to by the aggregator.<NEW_LINE>long lastOffset = this.aggregator.getLastIndexToProcessAtOnce(this.connector.getMaxFlushSize());<NEW_LINE>assert lastO... | getFirstOffset(), lastOffset, timer); |
1,500,668 | protected InitialLdapContext openContext(String userDn, String password) {<NEW_LINE>Hashtable<String, String> env = new Hashtable<>();<NEW_LINE>env.put(Context.INITIAL_CONTEXT_FACTORY, ldapConfiguration.getInitialContextFactory());<NEW_LINE>env.put(Context.<MASK><NEW_LINE>env.put(Context.PROVIDER_URL, ldapConfiguration... | SECURITY_AUTHENTICATION, ldapConfiguration.getSecurityAuthentication()); |
590,108 | private List<String> generateDropStatementsForRoutines() throws SQLException {<NEW_LINE>// #2193: PostgreSQL 11 removed the 'proisagg' column and replaced it with 'prokind'.<NEW_LINE>String isAggregate = database.getVersion().isAtLeast("11") ? "pg_proc.prokind = 'a'" : "pg_proc.proisagg";<NEW_LINE>// PROCEDURE is only ... | isAtLeast("11") ? "pg_proc.prokind = 'p'" : "FALSE"; |
423,363 | public void processMessage(String[] tokens, Map<String, Pattern> unstartedApps, Map<String, List<String>> failedApps) {<NEW_LINE>String appName;<NEW_LINE>switch(action) {<NEW_LINE>case REMOVE_APP_NAME_FROM_UNSTARTED_APPS:<NEW_LINE>appName = findAppNameInTokens(unstartedApps, tokens);<NEW_LINE>if (appName != null) {<NEW... | = new ArrayList<String>(); |
290,079 | protected void parseCreateField(ParseContext context) throws IOException {<NEW_LINE>if (stored == false && hasDocValues == false) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>byte[] value = context.parseExternalValue(byte[].class);<NEW_LINE>if (value == null) {<NEW_LINE>if (context.parser().currentToken() == XContentParser.T... | .parser().binaryValue(); |
827,677 | public static void runMap(String mapURL, int iterations) {<NEW_LINE>getExecutor().startAsync(() -> {<NEW_LINE>long totalTime = 0L;<NEW_LINE>for (int i = 0; i < iterations; i++) {<NEW_LINE>var time = TimingKt.measureNanoTime(() -> {<NEW_LINE>var level = getAssetLoader().loadLevel(mapURL, new TMXLevelLoader());<NEW_LINE>... | + (totalTime / iterations) / 1_000_000_000.0; |
1,557,412 | static <T> T referenceForTempleSet(final List<TemplateSetReference<T>> templateSetReferences, final PwmSettingTemplateSet pwmSettingTemplateSet) {<NEW_LINE>final PwmSettingTemplateSet effectiveTemplateSet = pwmSettingTemplateSet == null ? PwmSettingTemplateSet.getDefault() : pwmSettingTemplateSet;<NEW_LINE>if (template... | retainAll(effectiveTemplateSet.getTemplates()); |
1,064,118 | public static void write(ModuleDetails moduleDetails) throws TransformerException, ParserConfigurationException {<NEW_LINE>final DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance();<NEW_LINE>dbFactory.setAttribute(XMLConstants.ACCESS_EXTERNAL_DTD, "");<NEW_LINE>dbFactory.setAttribute(XMLConstants.AC... | rootElement = doc.createElement("checkstyle-metadata"); |
854,996 | /*<NEW_LINE>* Validate the classpaths of the projects affected by the given delta.<NEW_LINE>* Create markers if necessary.<NEW_LINE>* Returns whether cycle markers should be recomputed.<NEW_LINE>*/<NEW_LINE>private boolean validateClasspaths(IResourceDelta delta) {<NEW_LINE>Set<IPath> affectedProjects = new HashSet<>(5... | .getWorkspace().getRoot(); |
1,088,319 | public void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception {<NEW_LINE>if (args.length == 0) {<NEW_LINE>throw new NotEnoughArgumentsException(tl("mobsAvailable", StringUtil.joinList(Mob.getMobList())));<NEW_LINE>}<NEW_LINE>final List<String> mobParts = SpawnMob... | .mobParts(args[0]); |
1,826,954 | public void layout(Layer layer) {<NEW_LINE>Style style = layer.container.getStyle();<NEW_LINE>if (layer.visible) {<NEW_LINE>style.clearDisplay();<NEW_LINE>} else {<NEW_LINE>style.setDisplay(Display.NONE);<NEW_LINE>}<NEW_LINE>style.setProperty("left", layer.setLeft ? (layer.left + layer.leftUnit.getType()) : "");<NEW_LI... | setLeft(0, Unit.PX); |
1,548,285 | protected RubyArray regexpNames(RubyRegexp regexp) {<NEW_LINE>final int size = regexp.regex.numberOfNames();<NEW_LINE>if (size == 0) {<NEW_LINE>return createEmptyArray();<NEW_LINE>}<NEW_LINE>final Object[] names = new Object[size];<NEW_LINE>int i = 0;<NEW_LINE>for (Iterator<NameEntry> iter = regexp.regex.namedBackrefIt... | [] { name, backrefsRubyArray }); |
1,463,824 | public List<LayoutToken> fromText(final String text) {<NEW_LINE>List<String> toks = null;<NEW_LINE>try {<NEW_LINE>toks = GrobidAnalyzer.getInstance().tokenize(text);<NEW_LINE>} catch (Exception e) {<NEW_LINE>LOGGER.error("Fail tokenization for " + text, e);<NEW_LINE>}<NEW_LINE>tokenizations = toks.stream().map(LayoutTo... | images = new ArrayList<>(); |
1,825,413 | private static Map<String, Object> list2map_string(List<Object> valueList, String key, Udf convert, Hints hints) throws Throwable {<NEW_LINE>return list2map_udf(valueList, (readOnly, params) -> {<NEW_LINE>int rowNumber <MASK><NEW_LINE>if (params[1] == null) {<NEW_LINE>throw new NullPointerException("element " + rowNumb... | = (int) params[0]; |
328,877 | public Builder mergeFrom(io.kubernetes.client.proto.V1.TopologySelectorTerm other) {<NEW_LINE>if (other == io.kubernetes.client.proto.V1.TopologySelectorTerm.getDefaultInstance())<NEW_LINE>return this;<NEW_LINE>if (matchLabelExpressionsBuilder_ == null) {<NEW_LINE>if (!other.matchLabelExpressions_.isEmpty()) {<NEW_LINE... | .alwaysUseFieldBuilders ? getMatchLabelExpressionsFieldBuilder() : null; |
596,921 | public float[] filter(float[] data) {<NEW_LINE>if (mNewCoefficientsAvailable) {<NEW_LINE>mCoefficients = mNewCoefficients;<NEW_LINE>mNewCoefficientsAvailable = false;<NEW_LINE>}<NEW_LINE>int middle = mCoefficients.length / 2;<NEW_LINE>float[] filtered = new float[data.length];<NEW_LINE>int toCopy = middle;<NEW_LINE>Sys... | filtered.length - toCopy, toCopy); |
1,075,521 | public Builder mergeFrom(org.mlflow.api.proto.ModelRegistry.SearchRegisteredModels.Response other) {<NEW_LINE>if (other == org.mlflow.api.proto.ModelRegistry.SearchRegisteredModels.Response.getDefaultInstance())<NEW_LINE>return this;<NEW_LINE>if (registeredModelsBuilder_ == null) {<NEW_LINE>if (!other.registeredModels_... | bitField0_ = (bitField0_ & ~0x00000001); |
617,048 | private // loaded container (don't call repeatedly)<NEW_LINE>void loadLayout(String containerId, NodeList layoutNodeList) throws java.io.IOException {<NEW_LINE>layoutContainer = layoutModel.getLayoutComponent(containerId);<NEW_LINE>if (layoutContainer == null) {<NEW_LINE>layoutContainer = new LayoutComponent(containerI... | NodeList subNodes = dimLayoutNode.getChildNodes(); |
1,209,347 | public Result doMerge() {<NEW_LINE>com.feth.play.module.pa.controllers.Authenticate.noCache(response());<NEW_LINE>// this is the currently logged in user<NEW_LINE>final AuthUser aUser = this.auth.getUser(session());<NEW_LINE>// this is the user that was selected for a login<NEW_LINE>final AuthUser bUser = this.auth.get... | = filledForm.get().accept; |
1,584,801 | public static DescribePropertyCronDetailResponse unmarshall(DescribePropertyCronDetailResponse describePropertyCronDetailResponse, UnmarshallerContext _ctx) {<NEW_LINE>describePropertyCronDetailResponse.setRequestId(_ctx.stringValue("DescribePropertyCronDetailResponse.RequestId"));<NEW_LINE>PageInfo pageInfo = new Page... | ("DescribePropertyCronDetailResponse.Propertys[" + i + "].InstanceName")); |
1,430,910 | private void handleSnappy(BuildProducer<ReflectiveClassBuildItem> reflectiveClass, BuildProducer<NativeImageResourceBuildItem> nativeLibs, NativeConfig nativeConfig) {<NEW_LINE>reflectiveClass.produce(new ReflectiveClassBuildItem(true, true, true, "org.xerial.snappy.SnappyInputStream", "org.xerial.snappy.SnappyOutputSt... | = root + dir + "/" + snappyNativeLibraryName; |
1,221,278 | public void onConnectionError(MySQLResponseService service, int errNo) {<NEW_LINE>if (errNo == ErrorCode.ER_XAER_NOTA) {<NEW_LINE>RouteResultsetNode rrn = (RouteResultsetNode) service.getAttachment();<NEW_LINE>String xid = service.getConnXID(session.getSessionXaID(), rrn);<NEW_LINE>XAAnalysisHandler xaAnalysisHandler =... | getConnection().businessClose("rollback error"); |
126,603 | /*<NEW_LINE>* (non-Javadoc)<NEW_LINE>* @see com.aptana.filesystem.ftp.BaseFTPConnectionFileManager#deleteDirectory(org.eclipse.core.runtime.IPath,<NEW_LINE>* org.eclipse.core.runtime.IProgressMonitor)<NEW_LINE>*/<NEW_LINE>@Override<NEW_LINE>protected void deleteDirectory(IPath path, IProgressMonitor monitor) throws Cor... | dirPath = path.removeLastSegments(1); |
1,196,947 | 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 = new DefaultHttpClient();<NEW_LINE>HttpParams params = httpClient.getParams();<NEW_L... | setParameter(ConnRoutePNames.DEFAULT_PROXY, proxy); |
1,476,629 | public static ListTagResourcesResponse unmarshall(ListTagResourcesResponse listTagResourcesResponse, UnmarshallerContext _ctx) {<NEW_LINE>listTagResourcesResponse.setRequestId(_ctx.stringValue("ListTagResourcesResponse.RequestId"));<NEW_LINE>listTagResourcesResponse.setSuccess(_ctx.booleanValue("ListTagResourcesRespons... | (_ctx.stringValue("ListTagResourcesResponse.NextToken")); |
909,827 | protected Pair<RegisterSetLatticeElement, RegisterSetLatticeElement> transformMul(final ReilInstruction ins, final RegisterSetLatticeElement state) {<NEW_LINE>if ((ins.getFirstOperand().getType() == OperandType.INTEGER_LITERAL) && ins.getFirstOperand().getValue().equalsIgnoreCase("0")) {<NEW_LINE>final RegisterSetLatti... | , RegisterSetLatticeElement>(newState, null); |
370,463 | protected void updateCheckboxesEnabledByWildcards() {<NEW_LINE>if (rolesPolicyVersion == 1)<NEW_LINE>return;<NEW_LINE>Permission globalWildcardPermission = getWildcardPermission();<NEW_LINE>boolean globalWildcardModify = globalWildcardPermission != null && EntityAttrAccess.MODIFY.getId().equals(globalWildcardPermission... | getWildcardPermission(item.getEntityMetaClassName()); |
955,445 | static final PyObject array_new(PyNewWrapper new_, boolean init, PyType subtype, PyObject[] args, String[] keywords) {<NEW_LINE>if (new_.for_type != subtype && keywords.length > 0) {<NEW_LINE>int argc = args.length - keywords.length;<NEW_LINE>PyObject[] justArgs = new PyObject[argc];<NEW_LINE>System.arraycopy(args, 0, ... | .getPyObject(1, null)); |
400,565 | ActionResult<List<Wo>> execute(EffectivePerson effectivePerson, String workId) throws Exception {<NEW_LINE>try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {<NEW_LINE>ActionResult<List<Wo>> <MASK><NEW_LINE>Business business = new Business(emc);<NEW_LINE>Work work = emc.fetch(workId, ... | result = new ActionResult<>(); |
1,738,109 | public void noticePlayerUnlink(Player player) {<NEW_LINE>if (!isEnabled())<NEW_LINE>return;<NEW_LINE>if (getBypassNames().contains(player.getName()))<NEW_LINE>return;<NEW_LINE>if (checkWhitelist()) {<NEW_LINE>boolean whitelisted = Bukkit.getServer().getWhitelistedPlayers().stream().map(OfflinePlayer::getUniqueId).anyMa... | player.getName() + " for unlinking their accounts"); |
227,710 | public CompletableFuture<Void> startTruncation(final Map<Long, Long> streamCut, OperationContext context) {<NEW_LINE>Preconditions.checkNotNull(context, "operation context cannot be null");<NEW_LINE>return getTruncationRecord(context).thenCompose(existing -> {<NEW_LINE>Preconditions.checkNotNull(existing);<NEW_LINE>Pre... | epochHigh = NameUtils.getEpoch(mostRecent); |
1,671,009 | public AssemblyInstruction parseInstruction(String input, long address, String comment, String annotation, AssemblyLabels labels) {<NEW_LINE>input = input.replaceAll("\\s+", S_SPACE).trim();<NEW_LINE>int length = input.length();<NEW_LINE>boolean inBrackets = false;<NEW_LINE>String mnemonic = null;<NEW_LINE>List<String>... | String operand = partBuilder.toString(); |
1,606,167 | protected void onCreate(Bundle savedInstanceState) {<NEW_LINE>super.onCreate(savedInstanceState);<NEW_LINE>setContentView(R.layout.activity_file_list);<NEW_LINE>getSupportActionBar().setDisplayHomeAsUpEnabled(true);<NEW_LINE>mRootFolder = getRootFolder();<NEW_LINE>mCurrentDir = mRootFolder;<NEW_LINE>mFileList = (ListVi... | setText(mCurrentDir.getPath()); |
83,908 | private void tradeAtFortHochelagaMontreal() {<NEW_LINE>savings -= 160.0;<NEW_LINE>System.out.println();<NEW_LINE>System.out.println("SUPPLIES AT FORT HOCHELAGA COST $150.00.");<NEW_LINE>System.out.println("YOUR TRAVEL EXPENSES TO HOCHELAGA WERE $10.00.");<NEW_LINE>minkPrice = ((.2 * Math.random() + .7) * (Math.pow(10, ... | Math.pow(10, 2); |
1,170,915 | public static PCode createCode(PythonContext context, int flags, byte[] codedata, String filename, int firstlineno, byte[] lnotab) {<NEW_LINE>boolean isNotAModule = (flags & PCode.FLAG_MODULE) == 0;<NEW_LINE>PythonLanguage language = context.getLanguage();<NEW_LINE>Supplier<CallTarget> createCode = () -> {<NEW_LINE>Byt... | flags, firstlineno, lnotab, filename); |
1,395,992 | protected void renderShapes(Graphics2D g2, double scale) {<NEW_LINE>List<Polygon2D_F64> squares = getFoundPolygons();<NEW_LINE>for (int i = 0; i < squares.size(); i++) {<NEW_LINE>Polygon2D_F64 p = squares.get(i);<NEW_LINE>// if (isInGrids(p)) TODO fix broken method isInGrids<NEW_LINE>// continue;<NEW_LINE>g2.setColor(C... | setStroke(new BasicStroke(4)); |
1,210,008 | private JPanel buildPluginPathsPanel() {<NEW_LINE>// create the UP and DOWN arrows panel<NEW_LINE>upButton = ButtonPanelFactory.createButton(ButtonPanelFactory.ARROW_UP_TYPE);<NEW_LINE>upButton.setName("UpArrow");<NEW_LINE>upButton.addActionListener(e -> handleSelection(UP));<NEW_LINE>downButton = ButtonPanelFactory.cr... | addDirButton = ButtonPanelFactory.createButton(ADD_DIR_BUTTON_TEXT); |
1,126,747 | public void openTag(String elementName, List<String> attrs) {<NEW_LINE>if (DEBUG) {<NEW_LINE>dumpState("open " + elementName);<NEW_LINE>}<NEW_LINE>String <MASK><NEW_LINE>int elIndex = METADATA.indexForName(canonElementName);<NEW_LINE>// Treat unrecognized tags as void, but emit closing tags in closeTag().<NEW_LINE>if (... | canonElementName = HtmlLexer.canonicalElementName(elementName); |
1,336,637 | final AddTagsToVaultResult executeAddTagsToVault(AddTagsToVaultRequest addTagsToVaultRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(addTagsToVaultRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.... | false), new AddTagsToVaultResultJsonUnmarshaller()); |
504,052 | protected JettyForker newJettyForker() throws Exception {<NEW_LINE>JettyForker jetty = new JettyForker();<NEW_LINE>jetty.setServer(server);<NEW_LINE>jetty.<MASK><NEW_LINE>jetty.setStopKey(stopKey);<NEW_LINE>jetty.setStopPort(stopPort);<NEW_LINE>jetty.setEnv(env);<NEW_LINE>jetty.setJvmArgs(jvmArgs);<NEW_LINE>jetty.setSy... | setWorkDir(project.getBasedir()); |
1,444,557 | public void deleteUserAdditionalSpecializationByUserSpecialization(@NonNull final Integer userSpecializationId, @NonNull final Integer userId) {<NEW_LINE>final IQuery<I_CRM_Occupation> occupationList = queryBL.createQueryBuilder(I_CRM_Occupation.class).addEqualsFilter(I_CRM_Occupation.<MASK><NEW_LINE>queryBL.createQuer... | COLUMN_CRM_Occupation_Parent_ID, userSpecializationId).create(); |
1,741,664 | private void updateInstanceConfigAndBrokerResourceIfNeeded() {<NEW_LINE>InstanceConfig instanceConfig = HelixHelper.getInstanceConfig(_participantHelixManager, _instanceId);<NEW_LINE>boolean instanceConfigUpdated = HelixHelper.updateHostnamePort(instanceConfig, _hostname, _port);<NEW_LINE>if (_tlsPort > 0) {<NEW_LINE><... | HelixHelper.updateTlsPort(instanceConfig, _tlsPort); |
337,539 | final UpdateVocabularyFilterResult executeUpdateVocabularyFilter(UpdateVocabularyFilterRequest updateVocabularyFilterRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(updateVocabularyFilterRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
1,464,187 | public ConfidencePredictingClassifier train(InstanceList trainList) {<NEW_LINE>FeatureSelection selectedFeatures = trainList.getFeatureSelection();<NEW_LINE>logger.fine("Training underlying classifier");<NEW_LINE>Classifier c = underlyingClassifierTrainer.train(trainList);<NEW_LINE>confusionMatrix = new ConfusionMatrix... | double accuracy = t.getAccuracy(); |
307,246 | private void updateSearch() {<NEW_LINE><MASK><NEW_LINE>if (search.trim().isEmpty()) {<NEW_LINE>suggestionList.visible = false;<NEW_LINE>this.fullInit();<NEW_LINE>} else {<NEW_LINE>search = search.toLowerCase(Locale.ENGLISH);<NEW_LINE>ArrayList<AbstractNode<ResourceLocation, ManualEntry>> lHeaders = new ArrayList<>();<N... | String search = searchField.getValue(); |
1,761,611 | protected void saveContentletVersionInfo(ContentletVersionInfo cvInfo, boolean updateVersionTS) throws DotDataException, DotStateException {<NEW_LINE>boolean isNew = true;<NEW_LINE>if (UtilMethods.isSet(cvInfo.getIdentifier())) {<NEW_LINE>try {<NEW_LINE>final Optional<ContentletVersionInfo> fromDB = findContentletVersi... | addParam(cvInfo.isDeleted()); |
1,300,232 | public static void main(String[] args) throws IOException {<NEW_LINE>if (args.length < 4 || args.length > 5) {<NEW_LINE>System.err.println("Usage: " + ProhibitedCompoundRuleEvaluator.class.getSimpleName() + " <tokens> <langCode> <languageModelTopDir> <wikipediaXml|tatoebaFile|plainTextFile|dir>...");<NEW_LINE>System.er... | .add(args[3]); |
242,519 | final GetEventStreamResult executeGetEventStream(GetEventStreamRequest getEventStreamRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getEventStreamRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.... | addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint); |
223,106 | public List<TableId> tables() {<NEW_LINE>awaitTablesReady(startupMs);<NEW_LINE>List<TableId> tablesSnapshot = tables.get();<NEW_LINE>if (tablesSnapshot == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>Map<String, List<TableId>> duplicates = tablesSnapshot.stream().collect(Collectors.groupingBy(TableId::tableName)).... | = "'" + JdbcSourceConnectorConfig.TABLE_WHITELIST_CONFIG + "'"; |
1,729,262 | final ListJobExecutionsForThingResult executeListJobExecutionsForThing(ListJobExecutionsForThingRequest listJobExecutionsForThingRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listJobExecutionsForThingRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequest... | false), new ListJobExecutionsForThingResultJsonUnmarshaller()); |
666,968 | final ListShardsResult executeListShards(ListShardsRequest listShardsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listShardsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<... | (super.beforeMarshalling(listShardsRequest)); |
864,229 | private void overrideHotkeySettings() {<NEW_LINE>for (DefaultHotkey hotkey : defaultHotkeys) {<NEW_LINE>// Check version of when the default hotkey was added<NEW_LINE>if (switchedFromVersionBefore(hotkey.version)) {<NEW_LINE>// Setting<NEW_LINE>@SuppressWarnings("unchecked")<NEW_LINE>List<List> setting = settings.getLi... | setting.add(hotkey.data); |
1,548,053 | public List<Contentlet> dbRelatedContentByParent(final String parentIdentifier, final String relationType, final boolean live, final String orderBy, final int limit, final int offset) throws DotDataException {<NEW_LINE>final StringBuilder query = new StringBuilder("select cont1.inode from contentlet cont1, inode ci1, t... | setSQL(query.toString()); |
719,186 | static void saveSonicData(String sessionId, String eTag, String templateTag, String htmlSha1, long htmlSize, Map<String, List<String>> headers) {<NEW_LINE>if (SonicUtils.shouldLog(Log.INFO)) {<NEW_LINE>SonicUtils.log(TAG, Log.INFO, "saveSonicData sessionId = " + sessionId + ", eTag = " + eTag + ", templateTag = " + tem... | SonicDataHelper.saveSessionData(sessionId, sessionData); |
1,265,795 | public void render(PoseStack poseStack, int index, int y, int x, int entryWidth, int entryHeight, int mouseX, int mouseY, boolean hovered, float tickDelta) {<NEW_LINE>// Draw dividing line<NEW_LINE>fill(poseStack, x - 3, (y + entryHeight) - 2, x + entryWidth, (y + entryHeight) - 1, 0x66BEBEBE);<NEW_LINE>Font font = Min... | this.resetButton.disabled = !shiftDown; |
1,682,295 | public void onWorkerEvent(LifecycleEventsProto.WorkerStatusEvent workerEvent) {<NEW_LINE>if (logger.isTraceEnabled()) {<NEW_LINE>logger.trace("onWorkerEvent " + workerEvent + " is error state " + WorkerState.isErrorState(workerEvent.getWorkerState()));<NEW_LINE>}<NEW_LINE>if (workerEvent.getHostName().isPresent() && Wo... | this.slaveDisabler.call(hostName); |
878,896 | private JPanel initAsCross() {<NEW_LINE>setSize(side, side);<NEW_LINE>frameX = locx - (int) halfSide;<NEW_LINE>frameY = locy - (int) halfSide;<NEW_LINE>JPanel panel = new JPanel() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>protected void paintComponent(Graphics g) {<NEW_LINE>if (g instanceof Graphics2D) {<NEW_LINE>int sid... | , radius, dist, colorsRed)); |
1,704,804 | public void marshall(PhoneNumberInformation phoneNumberInformation, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (phoneNumberInformation == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(phoneNumberInforma... | phoneNumberInformation.getTwoWayChannelArn(), TWOWAYCHANNELARN_BINDING); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.