idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
488,928 | private static int callGetRecordCount(final Page page) {<NEW_LINE>final Object result;<NEW_LINE>try {<NEW_LINE>result = Holder.GET_RECORD_COUNT.invoke(null, page);<NEW_LINE>} catch (final IllegalAccessException | IllegalArgumentException ex) {<NEW_LINE>throw new LinkageError("[FATAL] org.embulk.spi.PageReaderImpl is in... | "[FATAL] org.embulk.spi.PageReaderImpl is invalid.", new ClassCastException("PageReaderImpl#getRecordCount returned non-int.")); |
571,377 | public static MySQLDatabaseMetadata parse(String serverVersion) {<NEW_LINE>int majorVersion = 0;<NEW_LINE>int minorVersion = 0;<NEW_LINE>int microVersion = 0;<NEW_LINE>int len = serverVersion.length();<NEW_LINE>boolean isMariaDb = serverVersion.contains("MariaDB");<NEW_LINE>String productName = isMariaDb ? "MariaDB" : ... | int versionTokenStartIdx = isMariaDb ? 6 : 0; |
1,590,661 | public static void main(String[] args) {<NEW_LINE>BufferedImage input = UtilImageIO.loadImageNotNull(UtilIO.pathExample("fiducial/qrcode/image01.jpg"));<NEW_LINE>GrayU8 gray = ConvertBufferedImage.convertFrom(input, (GrayU8) null);<NEW_LINE>var config = new ConfigQrCode();<NEW_LINE>// config.considerTransposed = false;... | input.getWidth() / 200); |
298,877 | public static void updateStoryListStyle(Context context, FeedSet fs, StoryListStyle newListStyle) {<NEW_LINE>if (fs.isAllNormal()) {<NEW_LINE>setStoryListStyleForFolder(context, PrefConstants.ALL_STORIES_FOLDER_NAME, newListStyle);<NEW_LINE>} else if (fs.getSingleFeed() != null) {<NEW_LINE>setStoryListStyleForFeed(cont... | context, PrefConstants.SAVED_STORIES_FOLDER_NAME, newListStyle); |
1,422,382 | public boolean apply(Game game, Ability source) {<NEW_LINE>Player controller = game.getPlayer(source.getControllerId());<NEW_LINE>if (controller == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) {<NEW_LINE>Player player = game.getPlay... | chosenCards, player, game, source); |
1,699,208 | private DBWHandlerConfiguration parseNetworkHandlerConfig(@Nullable DataSourceDescriptor dataSource, @Nullable DBWNetworkProfile profile, @NotNull Map.Entry<String, Map<String, Object>> handlerObject) {<NEW_LINE>String handlerId = handlerObject.getKey();<NEW_LINE>Map<String, Object<MASK><NEW_LINE>NetworkHandlerDescript... | > handlerCfg = handlerObject.getValue(); |
483,317 | private Process execBinary(ProcessBuilder builder, SubProcessCommandLineArgs commands, SubProcessIOFiles outPutFiles) throws Exception {<NEW_LINE>try {<NEW_LINE>builder = prepareBuilder(builder, commands, outPutFiles);<NEW_LINE>Process process = builder.start();<NEW_LINE>boolean timeout = !process.waitFor(configuration... | getWaitTime(), TimeUnit.SECONDS); |
1,753,053 | protected synchronized void addFromCheckpoint(ManagedObject managedObject, Transaction transaction) throws ObjectManagerException {<NEW_LINE>final String methodName = "addFromCheckpoint";<NEW_LINE>if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())<NEW_LINE>trace.entry(this, cclass, methodName, new Object<MASK... | [] { managedObject, transaction }); |
504,711 | public static void createChat(Menu parent_menu, ChatCreationListener listener) {<NEW_LINE>Menu menu = new Menu(parent_menu.getShell(), SWT.DROP_DOWN);<NEW_LINE>org.eclipse.swt.widgets.MenuItem mi = new org.eclipse.swt.widgets.MenuItem(parent_menu, SWT.CASCADE);<NEW_LINE>Messages.setLanguageText(mi, "chat.view.create.ch... | AENetworkClassifier.AT_PUBLIC, key, null); |
1,128,727 | public void execute(EditorAdaptor editorAdaptor) throws CommandExecutionException {<NEW_LINE>final IWorkbenchPartSite editorSite = getEditorSite();<NEW_LINE>final WorkbenchPage page = (WorkbenchPage) editorSite.getPage();<NEW_LINE>final EPartService psvc = (EPartService) editorSite.getService(EPartService.class);<NEW_L... | ] sortedEditors = page.getSortedEditors(); |
1,342,097 | public void initializeThread(RubyContext context, Thread thread) {<NEW_LINE>LOGGER.fine(() -> "initializeThread(#" + thread.getId() + " " + thread + ")");<NEW_LINE>if (thread == context.getThreadManager().getOrInitializeRootJavaThread()) {<NEW_LINE>// Already initialized when creating the context<NEW_LINE>setupCurrentT... | .getThreadManager().createForeignThread(); |
1,692,543 | protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {<NEW_LINE>int availableWidth = MeasureSpec.getSize(widthMeasureSpec);<NEW_LINE>int titleWidth = availableWidth - connectorWidth - moreSize - 4 * rowMargins;<NEW_LINE>int titleWidthSpec = MeasureSpec.makeMeasureSpec(titleWidth, MeasureSpec.AT_MOST);<... | makeMeasureSpec(detailsWidth, MeasureSpec.AT_MOST); |
535,634 | public boolean enterExportNode(ExportNode exportNode) {<NEW_LINE>final ExportClauseNode exportClause = exportNode.getExportClause();<NEW_LINE>final FromNode from = exportNode.getFrom();<NEW_LINE>final Expression expression = exportNode.getExpression();<NEW_LINE>if (exportClause != null) {<NEW_LINE>for (ExportSpecifierN... | type, local.getFinish()); |
212,567 | public static void validateKeyValueFormats(final Map<String, Object> configs) {<NEW_LINE>final Object value = configs.get(FORMAT_PROPERTY);<NEW_LINE>if (value != null) {<NEW_LINE>if (configs.get(KEY_FORMAT_PROPERTY) != null) {<NEW_LINE>throw new KsqlException("Cannot supply both '" + KEY_FORMAT_PROPERTY + "' and '" + F... | KEY_FORMAT_PROPERTY + "' and '" + VALUE_FORMAT_PROPERTY + "'."); |
1,551,016 | public UserKeyPairContainer requestUserKeyPair(String xSdsDateFormat, String version, String xSdsAuthToken) throws ApiException {<NEW_LINE>Object localVarPostBody = null;<NEW_LINE>// create path and map variables<NEW_LINE>String localVarPath = "/v4/user/account/keypair";<NEW_LINE>// query params<NEW_LINE>List<Pair> loc... | String[] localVarAccepts = { "application/json" }; |
676,313 | public static List<ZabbixConfig> loadConfigs(String path, List<String> fileNames) throws ModuleStartException {<NEW_LINE>if (CollectionUtils.isEmpty(fileNames)) {<NEW_LINE>return Collections.emptyList();<NEW_LINE>}<NEW_LINE>File[] configs;<NEW_LINE>try {<NEW_LINE>configs = ResourceUtils.getPathFiles(path);<NEW_LINE>} c... | throw new ModuleStartException("Load zabbix configs failed", e); |
1,376,316 | public void userGet(final Response.Listener<User> responseListener, final Response.ErrorListener errorListener) {<NEW_LINE>Object postBody = null;<NEW_LINE>// create path and map variables<NEW_LINE>String path = "/user".replaceAll("\\{format\\}", "json");<NEW_LINE>// query params<NEW_LINE>List<Pair> queryParams = new A... | MultipartEntityBuilder localVarBuilder = MultipartEntityBuilder.create(); |
218,168 | private UserSessionModel createTransientSessionForClient(AccessToken token, ClientModel client) {<NEW_LINE>// create a transient session<NEW_LINE>UserModel user = TokenManager.lookupUserFromStatelessToken(session, realm, token);<NEW_LINE>if (user == null) {<NEW_LINE>throw newUnauthorizedErrorResponseException(OAuthErro... | authenticationSessions().createRootAuthenticationSession(realm); |
1,230,746 | public void reloadModel(SdkComboBoxItem firstItem, @Nullable Project project) {<NEW_LINE>final DefaultComboBoxModel model = ((DefaultComboBoxModel) getModel());<NEW_LINE>if (project == null) {<NEW_LINE>model.addElement(firstItem);<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>model.removeAllElements();<NEW_LINE>model.addElement... | (ProjectStructureSettingsUtil) ShowSettingsUtil.getInstance(); |
1,394,203 | ConfidenceInterval computeConfidenceInterval(double alpha, double alphaNum) {<NEW_LINE>// Setting alphaDen such that (1 - alpha) = (1 - alphaNum) * (1 - alphaDen).<NEW_LINE>double alphaDen = (alpha - alphaNum) / (1 - alphaNum);<NEW_LINE>ConfidenceInterval confIntNum = normalizedSum.computeConfidenceInterval(alphaNum);<... | , confIntDen.upperBound())); |
749,374 | public boolean onPreDraw() {<NEW_LINE>listView.getViewTreeObserver().removeOnPreDrawListener(this);<NEW_LINE>int n = listView.getChildCount();<NEW_LINE>AnimatorSet animatorSet = new AnimatorSet();<NEW_LINE>for (int i = 0; i < n; i++) {<NEW_LINE>View child = listView.getChildAt(i);<NEW_LINE>int position = listView.getCh... | .getMeasuredHeight()) * 100); |
1,855,222 | void checkUnlabeledData() throws IOException {<NEW_LINE>org.nd4j.linalg.io.ClassPathResource unClassifiedResource = new org.nd4j.linalg.io.ClassPathResource("paravec/unlabeled");<NEW_LINE>FileLabelAwareIterator unClassifiedIterator = new FileLabelAwareIterator.Builder().addSourceFolder(unClassifiedResource.getFile()).b... | document.getLabels() + "' falls into the following categories: "); |
147,537 | private void _loadRealms() {<NEW_LINE>List<AuthRealm> authRealmConfigs = getSecurityService().getAuthRealm();<NEW_LINE>List<String> goodRealms = new ArrayList<String>();<NEW_LINE>for (AuthRealm authRealm : authRealmConfigs) {<NEW_LINE>List<Property> propConfigs = authRealm.getProperty();<NEW_LINE>Properties props = new... | p.getName(), value); |
127,933 | private TarArchiveEntry createSymlinkEntryOrNull(Path projectPath, Path absPath, String resourceName, boolean copyOutgoingSymlinks) throws IOException {<NEW_LINE>Path rawDest = Files.readSymbolicLink(absPath);<NEW_LINE>Path normalizedAbsDest = absPath.getParent().resolve(rawDest).normalize();<NEW_LINE>if (!normalizedAb... | getParent().relativize(normalizedAbsDest); |
1,845,260 | protected void paintComponent(Graphics g) {<NEW_LINE>super.paintComponent(g);<NEW_LINE>// Paint Lines<NEW_LINE>for (int i = 0; i < m_lines.size(); i++) {<NEW_LINE>WFLine line = (WFLine) m_lines.get(i);<NEW_LINE>line.paint(g);<NEW_LINE>}<NEW_LINE>// Paint Position = right next to the box<NEW_LINE>if (m_dragged && m_drag... | .y += layout.getAscent(); |
1,249,022 | public void saveGraph(DirectedGraph graph, String destFile) throws IOException {<NEW_LINE>if (graph == null)<NEW_LINE>throw new NullPointerException("Cannot dump null graph");<NEW_LINE>if (destFile == null)<NEW_LINE>throw new NullPointerException("No destination file");<NEW_LINE>logger.debug("Dumping directed graph in ... | out.writeShort(propData.length); |
204,583 | public static ListVehicleTrackResponse unmarshall(ListVehicleTrackResponse listVehicleTrackResponse, UnmarshallerContext _ctx) {<NEW_LINE>listVehicleTrackResponse.setRequestId(_ctx.stringValue("ListVehicleTrackResponse.RequestId"));<NEW_LINE>listVehicleTrackResponse.setCode(_ctx.stringValue("ListVehicleTrackResponse.Co... | ("ListVehicleTrackResponse.Data[" + i + "].Longitude")); |
388,813 | public void addPlatformProperties(String groupId, String artifactId, String classifier, String type, String version, Path propsPath) throws AppModelResolverException {<NEW_LINE>final ArtifactCoords bomCoords = new GACTV(groupId, artifactId.substring(0, artifactId.length() - BootstrapConstants.PLATFORM_PROPERTIES_ARTIFA... | final Properties props = new Properties(); |
50,322 | final CreateQueueResult executeCreateQueue(CreateQueueRequest createQueueRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createQueueRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTi... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "CreateQueue"); |
1,223,464 | public int findBackgroundColorAndFilter(Drawable drawable) {<NEW_LINE>int width = drawable.getIntrinsicWidth();<NEW_LINE>int height = drawable.getIntrinsicHeight();<NEW_LINE>int area = width * height;<NEW_LINE>double factor = Math.sqrt((float) RESIZE_BITMAP_AREA / area);<NEW_LINE>width = (int) (factor * width);<NEW_LIN... | Palette palette = paletteBuilder.generate(); |
135,369 | private void initFields() {<NEW_LINE>String address = instance.getProperty(PayaraModule.DEBUG_PORT);<NEW_LINE>SpinnerNumberModel addressModel = <MASK><NEW_LINE>javaPlatforms = JavaUtils.findSupportedPlatforms(this.instance);<NEW_LINE>((JavaPlatformsComboBox) javaComboBox).updateModel(javaPlatforms);<NEW_LINE>javaComboB... | (SpinnerNumberModel) addressValue.getModel(); |
115,556 | public static ListIndexesResponse unmarshall(ListIndexesResponse listIndexesResponse, UnmarshallerContext _ctx) {<NEW_LINE>listIndexesResponse.setRequestId(_ctx.stringValue("ListIndexesResponse.RequestId"));<NEW_LINE>listIndexesResponse.setErrorCode(_ctx.stringValue("ListIndexesResponse.ErrorCode"));<NEW_LINE>listIndex... | ("ListIndexesResponse.IndexList[" + i + "].IndexComment")); |
94,305 | private void sendPublishQos2(Topic topic, MqttQoS qos, ByteBuf payload, boolean retained) {<NEW_LINE>final MQTTConnection localMqttConnectionRef = mqttConnection;<NEW_LINE>if (canSkipQueue(localMqttConnectionRef)) {<NEW_LINE>inflightSlots.decrementAndGet();<NEW_LINE>int packetId = localMqttConnectionRef.nextPacketId();... | ), qos, payload, packetId); |
1,044,804 | protected Promise<Tuple6<T1, T2, T3, T4, T5, T6>> run(final Context context) throws Exception {<NEW_LINE>final SettablePromise<Tuple6<T1, T2, T3, T4, T5, T6>> result = Promises.settable();<NEW_LINE>InternalUtil.fastFailAfter(p -> {<NEW_LINE>if (p.isFailed()) {<NEW_LINE>result.fail(p.getError());<NEW_LINE>} else {<NEW_L... | ), _tasks._6()); |
1,404,441 | public static void main(String[] args) {<NEW_LINE>Exercise49_QueueWithStacks<Integer> queueWithStacks = new Exercise49_QueueWithStacks<>();<NEW_LINE>queueWithStacks.enqueue(0);<NEW_LINE>queueWithStacks.dequeue();<NEW_LINE>StdOut.println("Queue size: " + queueWithStacks.size());<NEW_LINE>StdOut.println("Expected: 0");<N... | (String.valueOf(item)); |
566,810 | public void run(RegressionEnvironment env) {<NEW_LINE>RegressionPath path = new RegressionPath();<NEW_LINE>String epl = "@public create window SBR#keepall as SupportBeanRange;\n" + "@Name('I1') insert into SBR select * from SupportBeanRange;\n" + "@public create window SB#keepall as SupportBean;\n" + "@Name('I2') inser... | "delta=" + (endTime - startTime)); |
1,206,325 | protected String applyOperator(OperatorEnum.Operator operator, String colName, String valueBinding) {<NEW_LINE>switch(operator.ordinal()) {<NEW_LINE>case OperatorEnum.Operator.GT_VALUE:<NEW_LINE>return String.format("%s > %s", colName, valueBinding);<NEW_LINE>case OperatorEnum.Operator.GTE_VALUE:<NEW_LINE>return String... | format("%s = %s", colName, valueBinding); |
314,804 | public ConnectionOAuthResponseParameters unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ConnectionOAuthResponseParameters connectionOAuthResponseParameters = new ConnectionOAuthResponseParameters();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LI... | int originalDepth = context.getCurrentDepth(); |
1,241,246 | public void draw(Color color, float width) {<NEW_LINE>Draw.color(color);<NEW_LINE>float[] items = points.items;<NEW_LINE>float lx = lastX, ly = lastY, lastAngle = this.lastAngle;<NEW_LINE>for (int i = 0; i < points.size - 3; i += 3) {<NEW_LINE>float x1 = items[i], y1 = items[i + 1], w1 = items[i + 2], x2 = items[i + 3]... | 3f + 1) * size * w2; |
999,887 | public boolean place(Item item, Block block, Block target, BlockFace face, double fx, double fy, double fz, Player player) {<NEW_LINE>int[] faces = { 2, 5, 3, 4 };<NEW_LINE>this.setDamage(faces[player != null ? player.getDirection().getHorizontalIndex() : 0]);<NEW_LINE>this.getLevel().setBlock(block, this, true, true);... | , (int) this.z); |
811,757 | public Dialog onCreateDialog(Bundle savedInstanceState) {<NEW_LINE>final AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());<NEW_LINE>final LayoutInflater inflater = getActivity().getLayoutInflater();<NEW_LINE>final View root = inflater.inflate(R.layout.fragment_google_play_dialog, null);<NEW_LINE>bui... | Statistics.INSTANCE.trackRatingDialog(rating); |
524,987 | private void processOne(String cmd, String taskName, HttpServletResponse response) {<NEW_LINE>LOG.info("start to processOne admin task:{},sort task:{}", cmd, taskName);<NEW_LINE>StringBuilder result = new StringBuilder();<NEW_LINE>try {<NEW_LINE>String beanName = JMX_DOMAIN + DOMAIN_SEPARATOR + JMX_TYPE + PROPERTY_EQUA... | response, result.toString()); |
1,633,155 | public void marshall(DirectConnectGatewayAssociationProposal directConnectGatewayAssociationProposal, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (directConnectGatewayAssociationProposal == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_... | directConnectGatewayAssociationProposal.getDirectConnectGatewayId(), DIRECTCONNECTGATEWAYID_BINDING); |
1,112,216 | private void allNodesResponded() {<NEW_LINE>if (activeCopies.get() != expectedActiveCopies) {<NEW_LINE>LOGGER.trace("not deleting shard {}, expected {} active copies, but only {} found active copies", shardId, expectedActiveCopies, activeCopies.get());<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>ClusterState latestClusterStat... | currentState.getVersion(), clusterStateVersion); |
1,131,105 | public static InactivatePhotosResponse unmarshall(InactivatePhotosResponse inactivatePhotosResponse, UnmarshallerContext context) {<NEW_LINE>inactivatePhotosResponse.setRequestId(context.stringValue("InactivatePhotosResponse.RequestId"));<NEW_LINE>inactivatePhotosResponse.setCode(context.stringValue("InactivatePhotosRe... | ("InactivatePhotosResponse.Results[" + i + "].Code")); |
446,668 | private Result doTypechecking(List<Concrete.Pattern> patterns, List<? extends Concrete.Parameter> concreteParams, DependentLink parameters, ExprSubstitution paramSubst, ExprSubstitution totalSubst, ConcreteSourceNode sourceNode) {<NEW_LINE>// Put patterns in the correct order<NEW_LINE>// If some parameters are not elim... | .getData(), ref)); |
1,472,705 | public MultiSourceBFS run(Blackhole bh) throws Throwable {<NEW_LINE>LongAdder tpt = new LongAdder();<NEW_LINE>long start = System.nanoTime();<NEW_LINE>AtomicLong lastLog = new AtomicLong(start);<NEW_LINE>long interval = TimeUnit.SECONDS.toNanos(1L);<NEW_LINE>Log log = FormattedLog.withLogLevel(Level.DEBUG).toOutputStre... | (edges / seconds) >> 20; |
291,860 | public static AlertDialog.Builder checkDuplicates(@NonNull FavouritePoint point, @NonNull Activity activity) {<NEW_LINE>OsmandApplication app = (OsmandApplication) activity.getApplication();<NEW_LINE>FavouritesHelper helper = app.getFavoritesHelper();<NEW_LINE>String name = AndroidUtils.checkEmoticons(point.getName());... | = point.getName() + index; |
766,893 | public JavaIndexerPlugin create(final URL root, final FileObject cacheFolder) {<NEW_LINE>try {<NEW_LINE>File whiteListDir = roots2whiteListDirs.get(root);<NEW_LINE>if (whiteListDir == null) {<NEW_LINE>// First time<NEW_LINE>final FileObject whiteListFolder = FileUtil.createFolder(cacheFolder, WHITE_LIST_INDEX);<NEW_LIN... | wl = WhiteListQuery.getWhiteList(rootFo); |
232,210 | public static String[] substringsOf(String source, char delimiter) {<NEW_LINE>if (source == null || source.length() == 0) {<NEW_LINE>return EMPTY_STRINGS;<NEW_LINE>}<NEW_LINE>int delimiterCount = 0;<NEW_LINE><MASK><NEW_LINE>char[] chars = source.toCharArray();<NEW_LINE>for (int i = 0; i < length; i++) {<NEW_LINE>if (ch... | int length = source.length(); |
1,608,739 | public void transfer() throws Exception {<NEW_LINE>cursor = srcDB.openCursor(null, null);<NEW_LINE>DatabaseEntry keyEntry = new DatabaseEntry();<NEW_LINE>DatabaseEntry valueEntry = new DatabaseEntry();<NEW_LINE>VersionedSerializer<byte[]> versionedSerializer = new VersionedSerializer<byte[]>(new IdentitySerializer());<... | Versioned<byte[]>> vals; |
478,939 | public AddressBookData unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>AddressBookData addressBookData = new AddressBookData();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDep... | class).unmarshall(context)); |
975,640 | // DO NOT MODIFY THIS CODE, GENERATED AUTOMATICALLY<NEW_LINE>public static void addClassFilter(com.sun.jdi.request.MonitorContendedEnteredRequest a, java.lang.String b) throws org.netbeans.modules.debugger.jpda.jdi.InternalExceptionWrapper, org.netbeans.modules.debugger.jpda.jdi.VMDisconnectedExceptionWrapper {<NEW_LIN... | Mirror) a).virtualMachine(); |
1,297,571 | public static boolean validateCodeberg(JReleaserContext context, JReleaserContext.Mode mode, Codeberg codeberg, Errors errors) {<NEW_LINE>if (null == codeberg)<NEW_LINE>return false;<NEW_LINE>context.getLogger().debug("release.codeberg");<NEW_LINE>validateGitService(context, mode, codeberg, errors);<NEW_LINE>if (contex... | getPrerelease().setEnabled(true); |
1,317,980 | ClusterMeta outerClusterToInner(OuterClientService.ClusterMeta outer) {<NEW_LINE>try {<NEW_LINE>ClusterMeta clusterMeta = new ClusterMeta(outer.getName());<NEW_LINE>clusterMeta.setType(outer.getClusterType().<MASK><NEW_LINE>if (ClusterType.lookup(clusterMeta.getType()).supportSingleActiveDC()) {<NEW_LINE>clusterMeta.se... | innerType().name()); |
876,905 | public void write(org.apache.thrift.protocol.TProtocol prot, getNamespaceConfiguration_args struct) throws org.apache.thrift.TException {<NEW_LINE>org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;<NEW_LINE>java.util.BitSet optionals = new java.util.BitSet();<NEW_LINE>if... | oprot.writeString(struct.ns); |
1,402,328 | static final // In C: again-two-registers.c hhb_get_composite_estimate L1489<NEW_LINE>double hllCompositeEstimate(final AbstractHllArray absHllArr) {<NEW_LINE>final int lgConfigK = absHllArr.getLgConfigK();<NEW_LINE>final double rawEst = getHllRawEstimate(lgConfigK, absHllArr.getKxQ0() + absHllArr.getKxQ1());<NEW_LINE>... | CompositeInterpolationXTable.xArrs[lgConfigK - MIN_LOG_K]; |
620,344 | private boolean isEnabledAndValidConfig() {<NEW_LINE>if (!isEnabled(false)) {<NEW_LINE>LOGGER.log(Level.FINE, "LOCAL copying not enabled for project {0}", project.getName());<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>if (isInvalid()) {<NEW_LINE>LOGGER.log(Level.FINE, "LOCAL copying invalid for project {0}", project.ge... | "LOCAL copying disabled for project {0}. Reason: source root is null", project.getName()); |
672,398 | private static void tryAssertion12(RegressionEnvironment env, String stmtText, String outputLimit, AtomicInteger milestone) {<NEW_LINE>sendTimer(env, 0);<NEW_LINE>env.compileDeploy(stmtText).addListener("s0");<NEW_LINE>String[] fields = new String[] { "symbol", "volume", "sum(price)" };<NEW_LINE>ResultAssertTestResult ... | "YAH", 10000L, 6d } }); |
1,142,172 | private void enterRoom() {<NEW_LINE>mTRTCCloud = TRTCCloud.sharedInstance(getApplicationContext());<NEW_LINE>mTRTCCloud.setListener(new TRTCCloudImplListener(VideoCallingActivity.this));<NEW_LINE>mTXDeviceManager = mTRTCCloud.getDeviceManager();<NEW_LINE>TRTCCloudDef.TRTCParams trtcParams = new TRTCCloudDef.TRTCParams(... | roomId = Integer.parseInt(mRoomId); |
1,228,185 | public NetworkFirewallBlackHoleRouteDetectedViolation unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>NetworkFirewallBlackHoleRouteDetectedViolation networkFirewallBlackHoleRouteDetectedViolation = new NetworkFirewallBlackHoleRouteDetectedViolation();<NEW_LINE><MASK><NEW_LINE>String currentParen... | int originalDepth = context.getCurrentDepth(); |
1,463,374 | private boolean executeCommand(String itemName, Type command) {<NEW_LINE>final RFXComBindingProvider provider = findFirstMatchingBindingProvider(itemName);<NEW_LINE>if (provider == null) {<NEW_LINE>logger.warn("Cannot execute command because no binding provider was found for itemname '{}'", itemName);<NEW_LINE>return f... | itemName, command, provider, connector); |
1,783,008 | private static Node buildTree(BitVector[] lexSortedCodeWords, final int[] symbol, int prefix, int offset, int length) {<NEW_LINE>if (DEBUG) {<NEW_LINE>System.err.println("****** " + offset + " " + length);<NEW_LINE>System.err.println(Arrays.toString(lexSortedCodeWords));<NEW_LINE>for (int i = 0; i < length; i++) {<NEW_... | 1, length - i - 1); |
488,850 | public void processSystem(ByteProcessor buffer, List<TextLine> sheetLines) {<NEW_LINE>logger.debug("processSystem #{}", system.getId());<NEW_LINE>StopWatch watch = new StopWatch("Texts processSystem #" + system.getId());<NEW_LINE>watch.start("retrieveRawLines");<NEW_LINE>List<TextLine> rawLines = getSystemRawLines(shee... | TextLine> lines = recomposeLines(longLines); |
1,630,018 | private void reorder(String fileName, FileObject categoryFolder, int dropIndex) throws IOException {<NEW_LINE>if (dropIndex < 0)<NEW_LINE>return;<NEW_LINE>// NOI18N<NEW_LINE>FileObject itemFile = categoryFolder.getFileObject(fileName, "xml");<NEW_LINE>if (null == itemFile)<NEW_LINE>return;<NEW_LINE>DataFolder catDob = ... | ] children = catDob.getChildren(); |
916,559 | public Object calculate(Context ctx) {<NEW_LINE>Object fo = null;<NEW_LINE>String distribute = null;<NEW_LINE>if (param == null) {<NEW_LINE>MessageManager mm = EngineMessage.get();<NEW_LINE>throw new RQException("create" + mm.getMessage("function.missingParam"));<NEW_LINE>} else if (param.isLeaf()) {<NEW_LINE>fo = para... | file, "n", ctx, distribute); |
574 | public void startElement(String uri, String localName, String qName, Attributes elementAttributes) throws SAXException {<NEW_LINE>if (ENTRY_ELEMENT_NAME.equals(qName)) {<NEW_LINE>Map<String, String> attributes = new HashMap<String, String>();<NEW_LINE>for (int i = 0; i < elementAttributes.getLength(); i++) {<NEW_LINE>S... | attributes.put(name, value); |
19,391 | private RegistrarContact updateContact(RegistrarContact contact, Registrar registrar) {<NEW_LINE>checkNotNull(registrar);<NEW_LINE>checkArgument(!isNullOrEmpty(email), "--email is required when --mode=UPDATE");<NEW_LINE>RegistrarContact.Builder builder = contact.asBuilder().setEmailAddress(email).setParent(registrar);<... | format("Email address %s is not associated with any GAE ID", email))); |
1,619,746 | private boolean hasValidAnnotations(List<Annotation> parameterAnnotations) {<NEW_LINE>// Because method parameters can contain parameters that are valid, but<NEW_LINE>// not part of the API contract, first check to make sure the parameter<NEW_LINE>// has at lease one annotation before processing it. Also, check a<NEW_... | validParameterAnnotations.add(HeaderParam.class); |
1,641,424 | private void loadDeployedDataSource(String path, List<JDBCDataBean> list, String deplName) {<NEW_LINE>try {<NEW_LINE>SAXParser parser = SAXParserFactory.newInstance().newSAXParser();<NEW_LINE>JdbcConfigHandler handler = new JdbcConfigHandler();<NEW_LINE>FileObject jdbcConfig = FileUtil.toFileObject(FileUtil.normalizeFi... | Level.INFO, null, e); |
768,472 | private void throwInvalidImportedModuleError(Toml toml, Module module) {<NEW_LINE>String moduleKey = getModuleKey(module);<NEW_LINE>TomlNode errorNode = null;<NEW_LINE>Optional<TomlValueNode> valueNode = toml.get(moduleKey);<NEW_LINE>List<Toml> tomlTables = toml.getTables(moduleKey);<NEW_LINE>String moduleName = module... | add(module.toString()); |
1,339,106 | private void detectInvalidCached404Response(GitHubConnectorResponse connectorResponse, GitHubRequest request) throws IOException {<NEW_LINE>// WORKAROUND FOR ISSUE #669:<NEW_LINE>// When the Requester detects a 404 response with an ETag (only happens when the server's 304<NEW_LINE>// is bogus and would cause cache corr... | ).url() + ". Retrying with \"Cache-Control\"=\"no-cache\"..."); |
789,070 | public ShardTbl insertShard(String clusterName, ShardTbl shard, Map<Long, SentinelGroupModel> sentinels) throws DalException {<NEW_LINE>final ClusterTbl cluster = clusterTblDao.findClusterByClusterName(clusterName, ClusterTblEntity.READSET_FULL);<NEW_LINE>shard.setClusterId(cluster.getId());<NEW_LINE>shard.setShardName... | = new LinkedList<DcClusterShardTbl>(); |
509,511 | public <T> T unmarshal(Class<T> clazz, InputStream stream) throws XmlException {<NEW_LINE>try (InputStream autoClosingStream = stream) {<NEW_LINE>return clazz.cast(getUnmarshaller().unmarshal(XML_INPUT_FACTORY.createXMLStreamReader(new StreamSource(autoClosingStream, SYSTEM_ID))));<NEW_LINE>} catch (UnmarshalException ... | replaceAll(""", ""))); |
317,463 | private Mono<Response<FeatureResultInner>> registerWithResponseAsync(String resourceProviderNamespace, String featureName, 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."));... | error(new IllegalArgumentException("Parameter resourceProviderNamespace is required and cannot be null.")); |
1,775,358 | protected Path loadServerConfiguration() {<NEW_LINE>String configPath = DEFAULT_CONFIG_FILE_PATH;<NEW_LINE>String[] args = Platform.getCommandLineArgs();<NEW_LINE>for (int i = 0; i < args.length; i++) {<NEW_LINE>if (args[i].equals(CLI_PARAM_WEB_CONFIG) && args.length > i + 1) {<NEW_LINE>configPath = args[i + 1];<NEW_LI... | resolve("logback.xml").toAbsolutePath(); |
15,453 | public void initGradient() {<NEW_LINE>if (gradientTexture == 0) {<NEW_LINE>Image slider = GameImage.SLIDER_GRADIENT_EXPERIMENTAL.getImage().getScaledCopy(1.0f / GameImage.getUIscale());<NEW_LINE>staticState.gradientTexture = GL11.glGenTextures();<NEW_LINE>ByteBuffer buff = BufferUtils.createByteBuffer(slider.getWidth()... | (255 * col.a)); |
681,462 | private void writeVariable(JRVariable variable, String variableName) {<NEW_LINE>if (variable != null) {<NEW_LINE>String resetGroupName = getGroupName(variable.getResetGroup());<NEW_LINE>String incrementGroupName = getGroupName(variable.getIncrementGroup());<NEW_LINE>write("JRDesignVariable " + variableName + " = new JR... | (variable.getName())); |
51,118 | private static int finishInitialization0(JNIJavaVMPointer vmBuf, JNIEnvironmentPointer penv, JNIJavaVMInitArgs vmArgs, boolean hasSpecialVmOptions) {<NEW_LINE>WordPointer javaVmIdPointer = WordFactory.nullPointer();<NEW_LINE>if (hasSpecialVmOptions) {<NEW_LINE>javaVmIdPointer = parseVMOptions(vmArgs);<NEW_LINE>}<NEW_LI... | .singleton().getGlobalJavaVM(); |
432,489 | final DescribeMaintenanceWindowExecutionTaskInvocationsResult executeDescribeMaintenanceWindowExecutionTaskInvocations(DescribeMaintenanceWindowExecutionTaskInvocationsRequest describeMaintenanceWindowExecutionTaskInvocationsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeMaintena... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
1,748,163 | public void onCreate(Bundle savedInstanceState) {<NEW_LINE>super.onCreate(savedInstanceState);<NEW_LINE>((WordPress) getApplication()).component().inject(this);<NEW_LINE>setContentView(R.layout.plugin_browser_activity);<NEW_LINE>mViewModel = new ViewModelProvider(this, mViewModelFactory).get(PluginBrowserViewModel.clas... | findViewById(R.id.new_plugins_recycler); |
1,485,122 | public List<BalanceAction> rebalanceCluster(ExecutionContext ec, BalanceOptions options) {<NEW_LINE>DdlJobManager jobManager = new DdlJobManager();<NEW_LINE>String name = ActionUtils.genRebalanceClusterName();<NEW_LINE>boolean ok = jobManager.getResourceManager().checkResource(Sets.newHashSet(), Sets.newHashSet(name));... | ::getSchema, x -> x)); |
1,475,077 | public void write(org.apache.thrift.protocol.TProtocol oprot, TCompactionStatusUpdate struct) throws org.apache.thrift.TException {<NEW_LINE>struct.validate();<NEW_LINE>oprot.writeStructBegin(STRUCT_DESC);<NEW_LINE>if (struct.state != null) {<NEW_LINE>oprot.writeFieldBegin(STATE_FIELD_DESC);<NEW_LINE>oprot.writeI32(str... | oprot.writeI64(struct.entriesToBeCompacted); |
471,150 | final DeleteUtterancesResult executeDeleteUtterances(DeleteUtterancesRequest deleteUtterancesRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteUtterancesRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | false), new DeleteUtterancesResultJsonUnmarshaller()); |
1,330,445 | protected void encodeMarkup(FacesContext context, ConfirmDialog dialog) throws IOException {<NEW_LINE>ResponseWriter writer = context.getResponseWriter();<NEW_LINE>String <MASK><NEW_LINE>String style = dialog.getStyle();<NEW_LINE>String styleClass = dialog.getStyleClass();<NEW_LINE>styleClass = styleClass == null ? Con... | clientId = dialog.getClientId(context); |
232,407 | public HistoricTaskInstanceEntity recordTaskInfoChange(TaskEntity taskEntity, Date changeTime, AbstractEngineConfiguration engineConfiguration) {<NEW_LINE>HistoricTaskInstanceEntity historicTaskInstance = getHistoricTaskInstanceEntityManager().<MASK><NEW_LINE>if (historicTaskInstance != null) {<NEW_LINE>historicTaskIns... | findById(taskEntity.getId()); |
830,157 | private void startQueueProcessors() {<NEW_LINE>// task 04585: start queue processors only if we are running on the backend server.<NEW_LINE>// =>why not always run them?<NEW_LINE>// if we start it on clients without having a central monitoring-gathering point we never know what's going on<NEW_LINE>// => it can all be s... | .class).init(initDelayMillis); |
957,372 | public CreateUserResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>CreateUserResult createUserResult = new CreateUserResult();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = c... | int originalDepth = context.getCurrentDepth(); |
872,933 | public String createLines(boolean mustBeStocked) {<NEW_LINE>lineno = 100;<NEW_LINE>String error = "";<NEW_LINE>// product to be produced<NEW_LINE>MProduct finishedProduct = new MProduct(getCtx(), getM_Product_ID(), get_TrxName());<NEW_LINE>MAttributeSet as = finishedProduct.getAttributeSet();<NEW_LINE>if (as != null &&... | line.setPlannedQty(Env.ONE); |
31,963 | private void pushAddServerPopupAndStartLogBackAppender() {<NEW_LINE>AddServerPopup addServerPopup = nuiManager.pushScreen(<MASK><NEW_LINE>addServerPopup.removeTip();<NEW_LINE>ServerInfo serverInfo;<NEW_LINE>TelemetryConfig telemetryConfig = config.getTelemetryConfig();<NEW_LINE>if (telemetryConfig.getErrorReportingDest... | AddServerPopup.ASSET_URI, AddServerPopup.class); |
343,971 | private DatagramPacket encode(byte direction, DatagramPacket packet, byte[] recordBytes) {<NEW_LINE>InetAddress source = packet.getAddress();<NEW_LINE>byte[] address = source.getAddress();<NEW_LINE>int headerLength = CLUSTER_ADDRESS_OFFSET + address.length + getClusterMacLength();<NEW_LINE>byte[] data = packet.getData(... | offset, data, headerLength, length); |
699,788 | public static <E> Class<E> detectSuperTypeForRuleLike(Class<?> c) {<NEW_LINE>Class<?> clazz = c;<NEW_LINE>for (Type type = clazz.getGenericSuperclass(); clazz != Object.class; type = clazz.getGenericSuperclass()) {<NEW_LINE>if (type instanceof ParameterizedType) {<NEW_LINE>Type[] typeArguments = ((ParameterizedType) ty... | throw new QlIllegalArgumentException("Unexpected class structure for class {}", c); |
151,594 | private Mono<Response<Void>> deleteWithResponseAsync(String resourceGroupName, String workspaceName, String metadataName, 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."));<... | error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.")); |
814,101 | public List<? extends Token> tokenize(String pattern) {<NEW_LINE>// split pattern into chunks: sea (raw input) and islands (<ID>, <expr>)<NEW_LINE>List<<MASK><NEW_LINE>// create token stream from text and tags<NEW_LINE>List<Token> tokens = new ArrayList<Token>();<NEW_LINE>for (Chunk chunk : chunks) {<NEW_LINE>if (chunk... | Chunk> chunks = split(pattern); |
1,198,505 | private void checkGoogFunctions(NodeTraversal t, Node call) {<NEW_LINE>Node callee = call.getFirstChild();<NEW_LINE>if (!callee.isGetProp()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Node receiver = callee.getFirstChild();<NEW_LINE>if (!receiver.isName() || !receiver.getString().equals(GOOG)) {<NEW_LINE>return;<NEW_LINE>}... | call, call.getParent()); |
1,024,507 | protected synchronized // the respective internal or external data.<NEW_LINE>void ensureInternalResults() {<NEW_LINE>String methodName = "ensureInternalResults";<NEW_LINE>if (hasInternalTable()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (logger.isLoggable(Level.FINER)) {<NEW_LINE>logger.logp(Level.FINER, CLASS_NAME, <M... | methodName, "ENTER [ {0} ]", getHashName()); |
897,352 | public DmnRuleServiceResponse createDmnRuleServiceResponse(DecisionServiceExecutionAuditContainer decisionServiceExecutionAuditContainer, DmnRestUrlBuilder urlBuilder) {<NEW_LINE>DmnRuleServiceResponse response = new DmnRuleServiceResponse();<NEW_LINE>Map<String, List<Map<String, Object>>> executionResults = decisionSe... | get(variableName), false)); |
116,962 | protected void initListeners() {<NEW_LINE>super.initListeners();<NEW_LINE>binding.detailTitleRootLayout.setOnClickListener(this);<NEW_LINE>binding.detailTitleRootLayout.setOnLongClickListener(this);<NEW_LINE>binding.detailUploaderRootLayout.setOnClickListener(this);<NEW_LINE>binding.detailUploaderRootLayout.setOnLongCl... | binding.overlayMetadataLayout.setOnClickListener(this); |
1,841,085 | final RemoveFlowMediaStreamResult executeRemoveFlowMediaStream(RemoveFlowMediaStreamRequest removeFlowMediaStreamRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(removeFlowMediaStreamRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>... | HandlerContextKey.SIGNING_REGION, getSigningRegion()); |
472,480 | public static byte[] calcBAQFromTag(GATKRead read, boolean overwriteOriginalQuals, boolean useRawQualsIfNoBAQTag) {<NEW_LINE>byte[] baq = getBAQTag(read);<NEW_LINE>Utils.validate(baq != null || useRawQualsIfNoBAQTag, () -> "Required BAQ tag to be present, but none was on read " + read.getName());<NEW_LINE>final byte[<M... | ] rawQuals = read.getBaseQualities(); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.